MCP is an in-image Model Context Protocol server for Pharo. It lets MCP clients inspect and change the running image through Pharo-aware tools for packages, classes, methods, tests, repositories, change history, debugging, and UI inspection.
MCP works through the Pharo ecosystem—compilation, refactorings, Renraku, SUnit, Iceberg, Metacello, Epicea, and Spec—rather than patching exported Tonel files as plain text.
Pharo 12, 13, and 14 are supported. Development targets Pharo 13 while CI checks the full matrix.
Load MCP in a supported image:
Metacello new
baseline: 'MCP';
repository: 'github://Evref-BL/MCP:main/src';
load.Start the Streamable HTTP server:
mcp := MCP new.
mcp port: 4000.
mcp start.Connect a local MCP client to http://127.0.0.1:4000. Client configuration
formats differ; see Getting started for setup,
first calls, and the copyable Codex template.
- Documentation index
- Getting started
- Using MCP from an agent
- Tool reference
- Safety and ecosystem integration
- Troubleshooting
- Developing MCP
Copy the supplied MCP configuration, agent guide, and workflow skills into a Pharo project:
cp -R templates/. /path/to/your/project/Update .codex/config.toml when the image uses a port other than 4000.
Use Pharo 13 for normal development and preserve Pharo 12/14 compatibility. Live behavior must be verified in an image; source inspection alone is not enough. Start with AGENTS.md and MCP verification.