feat(mcp): add experimental MCP server support#68
Closed
mikeyobrien wants to merge 6 commits intomainfrom
Closed
Conversation
Add Model Context Protocol SDK dependencies in preparation for ralph-mcp crate: - rmcp 0.8 with server, transport-io, macros features - schemars 1.0 for JSON Schema generation
Create new ralph-mcp crate that implements an MCP server using the rmcp SDK. This provides the foundation for `ralph mcp serve` command. Implements 5 tools (currently stubs): - ralph_run: Start orchestration sessions - ralph_status: Check session status - ralph_stop: Stop running sessions - ralph_list_sessions: List all sessions - ralph_list_hats: List configured hats Uses rmcp 0.8 with #[tool_router] and #[tool] macros for clean tool definitions. Serves over stdio transport as per MCP spec.
Adds `ralph mcp serve` command that launches the MCP server over stdio, allowing Ralph to be used as an MCP tool provider for Claude Desktop and other MCP clients.
Add comprehensive e2e tests that spawn `ralph mcp serve` as a subprocess and communicate with it using the MCP JSON-RPC protocol over stdio. Tests cover: - Server initialization and capability negotiation - tools/list endpoint returning all 5 Ralph tools - tools/call for ralph_list_hats with config parsing - tools/call for ralph_run with prompt handling
Tool and parameter descriptions now include: - What each tool returns and its side effects - Workflow hints (e.g., "poll ralph_status periodically") - Cross-references between related tools - Examples for prompt parameters - Idempotency guarantees where applicable Server instructions updated to explain the recommended workflow: list_hats → run → status → stop
- Add MCP Server to Features list - Add MCP Support section with usage instructions - Document Claude Desktop configuration - Update Architecture table with ralph-mcp crate - Add ralph mcp serve to CLI Reference
Owner
Author
|
Closing this for now per maintainer decision; can reopen or replace with a fresh branch later. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
ralph mcp servesubcommand with stdio transportralph_run,ralph_status,ralph_stop,ralph_list_sessions,ralph_list_hatsChanges
ralph-mcp- MCP server implementation usingrmcpralph mcp servesubcommandTest plan
cargo test -p ralph-mcp)ralph mcp servestarts successfullyNotes
This feature is marked as experimental. The MCP server uses stdio transport, making it compatible with Claude Desktop's MCP configuration format.