How steosumit/multi-caller-mcp works
multi-caller-mcp is a local conversational agent with two MCP interaction modes: direct tool calling and TypeScript Code Mode. A user prompt is handled by the agent and local LLM; in Code Mode, the model submits one script, whose MCP calls are bridged through Python to configured stdio servers and whose logs become the tool result. Direct mode exposes MCP tools individually, while local calculator and Python tools are also available. The graph reflects the README workflow and sampled source; some internal wiring is documented rather than visible in the excerpts.
Main entry points: agent.py Agent CLI · codemode.py Code executor · mcp_converter.py Stdio MCP clients · llm.py Chat model
Components 12
Agent orchestration
- Agent CLI
agent.py - Chat model
llm.py
MCP integration
- Stdio MCP clients
mcp_converter.py - Direct tool adapter
mcp_converter.py
Code Mode
- TS API generation
codemode.py - Code executor
codemode.py - Bun harness
codemode_runner.ts - Bun sandbox
codemode.py
Local tools
- Calculator and Python
sandbox.py
Other components
- User
- OpenAI-compatible model
- MCP stdio server
Connections 18
- User → Agent CLI: submits prompt
README.md - Agent CLI → Chat model: builds agent
agent.py - Chat model → OpenAI-compatible model: sends requests
llm.py - Agent CLI → Stdio MCP clients: starts servers
agent.py - Stdio MCP clients → MCP stdio server: lists tools
mcp_converter.py - Stdio MCP clients → MCP stdio server: calls tools
mcp_converter.py - Agent CLI → Direct tool adapter: loads direct tools
agent.py - Direct tool adapter → Stdio MCP clients: invokes client
mcp_converter.py - Agent CLI → TS API generation: generates API
README.md - TS API generation → Code executor: provides declarations
README.md - Agent CLI → Code executor: registers execution tool
agent.py - Code executor → Bun harness: launches harness
README.md - Code executor → Bun sandbox: runs script in
README.md - Bun harness → Code executor: emits call events
codemode_runner.ts - Code executor → Stdio MCP clients: routes tool calls
README.md - Agent CLI → Calculator and Python: offers local tools
agent.py - Code executor → Agent CLI: returns logs
README.md - Chat model → Agent CLI: returns response
agent.py