MCP Python Interpreter
@yzfly
关于 MCP Python Interpreter
MCP Python Interpreter: run python code. Python-mcp-server, mcp-python-server, Code Executor
基本信息
配置
工具
未检测到工具
工具是从 README 中自动提取的。维护者可以在 ## Tools 标题下列出工具,即可填充这部分内容。
概览
What is MCP Python Interpreter?
MCP Python Interpreter is a Model Context Protocol (MCP) server that enables LLMs to interact with Python environments, read and write files, execute Python code, and manage development workflows.
How to use MCP Python Interpreter?
Install the server with pip install mcp-python-interpreter or uv install mcp-python-interpreter. Configure it in Claude Desktop by adding a server entry in claude_desktop_config.json with the command uvx mcp-python-interpreter, the required --dir argument (working directory), and optional --python-path and MCP_ALLOW_SYSTEM_ACCESS environment variable. The uv package manager must be installed first.
Key features of MCP Python Interpreter
- List and use system and conda Python environments
- Run Python code or scripts in any environment
- Install and list installed Python packages
- Read text, source code, and binary files
- Write text and binary files securely
- Provides prompts for function templates, refactoring, and debugging
Use cases of MCP Python Interpreter
- Ask an LLM to list available Python environments on your system
- Execute Python code in a specific conda or system environment
- Create, read, or edit Python files and other text files
- Install new Python packages or list installed packages
- Run a Python script from a file with custom arguments
FAQ from MCP Python Interpreter
What prerequisites are needed?
The uv package manager must be installed. Installation commands for macOS/Linux and Windows are provided in the README.
How does the server ensure file and environment security?
The server operates within an isolated working directory set by --dir. It prevents writes outside that directory, limits file reads to 1MB, requires explicit overwrite confirmation, and includes an MCP_ALLOW_SYSTEM_ACCESS environment variable to control system access.
What Python environments can I manage?
The server can list and use both system Python environments and conda environments.
Can I install packages with this server?
Yes, the install_package tool allows installing Python packages in any available environment.
What file types and sizes are supported?
The server can read and write text files, source code, and binary files. File reads are limited to 1MB; binary files are shown in hex representation.
其他 分类下的更多 MCP 服务器
Awesome-MCP-ZH
yzflyMCP 资源精选, MCP指南,Claude MCP,MCP Servers, MCP Clients
MCP Go 🚀
mark3labsA Go implementation of the Model Context Protocol (MCP), enabling seamless integration between LLM applications and external data sources and tools.
Reactive Resume
amruthpillaiA one-of-a-kind resume builder that keeps your privacy in mind. Completely secure, customizable, portable, open-source and free forever. Try it out today!

Sequential Thinking
modelcontextprotocolModel Context Protocol Servers
Servers
modelcontextprotocolModel Context Protocol Servers
评论