Integrations
Provides the ability to execute Python code in a sandboxed environment using pyodide, allowing safe Python code execution isolated from the operating system.
MCP Run Python
Model Context Protocol -Server zum Ausführen von Python-Code in einer Sandbox.
Der Code wird mit Pyodide in Deno ausgeführt und ist daher vom Rest des Betriebssystems isoliert.
Die vollständige Dokumentation finden Sie unter https://ai.pydantic.dev/mcp/run-python/ .
Der Server kann mit installiertem deno
ausgeführt werden, indem Folgendes verwendet wird:
Wo:
-N -R=node_modules -W=node_modules
(Alias von--allow-net --allow-read=node_modules --allow-write=node_modules
) ermöglicht Netzwerkzugriff sowie Lese- und Schreibzugriff auf./node_modules
. Diese sind erforderlich, damit pyodide die Python-Standardbibliothek und -Pakete herunterladen und zwischenspeichern kann.--node-modules-dir=auto
weist deno an, ein lokalesnode_modules
-Verzeichnis zu verwendenstdio
führt den Server mit dem Stdio MCP-Transport aus – geeignet, um den Prozess lokal als Unterprozess auszuführensse
betreibt den Server mit dem SSE MCP-Transport – er betreibt den Server als HTTP-Server für lokale oder Remote-Verbindungenwarmup
führt ein minimales Python-Skript aus, um die Python-Standardbibliothek herunterzuladen und zwischenzuspeichern. Dies ist auch nützlich, um zu überprüfen, ob der Server korrekt läuft.
Hier ist ein Beispiel für die Verwendung von @pydantic/mcp-run-python
mit PydanticAI:
This server cannot be installed
hybrid server
The server is able to function both locally and remotely, depending on the configuration or use case.
Model Context Protocol-Server zum Ausführen von Python-Code in einer Sandbox.
Related MCP Servers
- -securityAlicense-qualityA Model Context Protocol server that allows execution of Python code within Daytona workspaces, providing a secure and isolated environment for executing and managing Python scripts.Last updated -18PythonApache 2.0
- -securityFlicense-qualityA Model Context Protocol server that allows management and execution of Blender Python scripts, enabling users to create, edit and run scripts in a headless Blender environment through natural language interfaces.Last updated -4Python
- -securityAlicense-qualityA Model Context Protocol server that enables seamless execution of commands, Python code, web content fetching, and reusable task management with secure credentials handling.Last updated -2PythonMIT License
- -securityAlicense-qualityA streamlined foundation for building Model Context Protocol servers in Python, designed to make AI-assisted development of MCP tools easier and more efficient.Last updated -12PythonMIT License