How reeeeemo/ancestry-mcp works
Project type and purpose
• This is a lightweight Python-based MCP (Model Context Protocol) server that exposes filesystem operations on GEDCOM (.ged) files to an external MCP client (e.g., Claude Desktop).
• It is not a full-stack web app but an open-source CLI-driven microservice/plugin aligning with the MCP SDK.
File structure
• Top-level: metadata files (pyproject.toml, README.md, LICENSE), a single package under src/mcp_server_ancestry/.
• server.py contains the MCP server entrypoint: parses CLI args (e.g. --gedcom-path), registers “tools” (list_files, rename_file, view_file) via the MCP Python SDK, and routes incoming MCP requests.
• No database or front end; all state is in the host filesystem under the supplied directory.
Extract insights from the README
• The server speaks MCP over STDIN/STDOUT or subprocess pipes (as per Claude Desktop plugin conventions).
• Implements three core operations against .ged files.
• Depends on the Model Context Protocol Python SDK and a GEDCOM‐parsing library (implied).
• External MCP Client (e.g. Claude Desktop)
• MCP Transport Layer (stdin/stdout or process‐pipe)
• Python MCP Server Process
– MCP SDK Adapter
– Command/Tool Dispatcher
– GEDCOM File Service (parsing & I/O)
• Host Filesystem (GEDCOM files directory)
• (Optional) Logging/Config
1. Client → MCP Transport Layer: sends JSON-RPC MCP requests.
2. Transport Layer → Python Server: delivers requests to server.py.
3. Server Dispatcher → MCP SDK Adapter: unmarshals requests into tool calls.
4. For each tool:
• → GEDCOM File Service: performs FS operations (list, rename, parse).
• → Host Filesystem: reads/writes .ged files.
5. Responses flow back through the same path in reverse, ending at the Client.
c. Architectural patterns & principles
• Single‐responsibility modules: Transport, Protocol Adapter, Command Handlers, File Service
• Plugin/Tool registration (extensibility) via the MCP SDK
• Minimal external dependencies, no embedded DB
d. Key technologies/frameworks
• Python 3.x
• Model Context Protocol Python SDK
• GEDCOM parsing library (inside File Service)
• Standard filesystem APIs
• CLI entrypoint via pyproject.toml/console_scripts