mcp-mnemose-services — Architecture
The @mnemose/mcp-mnemose-services package is a stdio-launched Model Context Protocol server acting as a proxy to the platform’s sandbox service registry. It lets the agent loop list and invoke named platform services bound to a sandbox.
Responsibilities
- Expose
services.listandservices.invokeMCP tools to the agent loop services.list— list the named services bound to the current sandbox (name + kind)services.invoke— invoke a named service with a JSON payload
Key Components
| File | Role |
|---|---|
src/index.ts | Process entrypoint — boots the MCP server over stdio |
src/server.ts | MCP server definition + ListTools / CallTool request handlers |
src/tools.ts | Zod schemas for services.list / services.invoke tool inputs |
src/worker.ts | Background dispatch worker |
src/tools.test.ts | Tool schema round-trip assertions |
Dependencies
@modelcontextprotocol/sdkzod+zod-to-json-schema@mnemose/sandbox-runtime—ServiceRegistryport
Data Flow
agent loop (loop-host) ↓ MCP stdio → mcp-mnemose-services server ↓ services.list → ServiceRegistry.list() ↓ services.invoke → ServiceRegistry.resolve(name).invoke(payload)