MCP server for the SynergyAge database of synergistic and antagonistic genetic interactions in longevity.
MCP (Model Context Protocol) server for SynergyAge database
This server implements the Model Context Protocol (MCP) for SynergyAge, providing a standardized interface for accessing synergistic genetic intervention and aging research data. MCP enables AI assistants and agents to query comprehensive longevity datasets through structured interfaces.
The server automatically downloads the latest SynergyAge database and documentation from Hugging Face Hub (specifically from the synergy-age
folder), ensuring you always have access to the most up-to-date data without manual file management.
The SynergyAge database contains:
Here's how the SynergyAge MCP server works in practice with AI assistants:
Example showing how to query the SynergyAge database through an AI assistant using natural language, which gets translated to SQL queries via the MCP server. You can use this database both in chat interfaces for research questions and in AI-based development tools (like Cursor, Windsurf, VS Code with Copilot) to significantly improve your aging and longevity research productivity by having direct access to synergistic intervention data while coding.
The SynergyAge database focuses on different types of genetic interactions that affect lifespan:
Figure: Types of genetic interactions in longevity research - synergistic, antagonistic, and additive effects between genetic interventions (Source: SynergyAge.info)
If you want to understand more about what the Model Context Protocol is and how to use it more efficiently, you can take the DeepLearning AI Course or search for MCP videos on YouTube.
MCP is a protocol that bridges the gap between AI systems and specialized domain knowledge. It enables:
SynergyAge is a curated database containing experimentally validated data on genetic interventions affecting lifespan across multiple model organisms. The database focuses on both single-gene mutants and multi-gene combinations to understand genetic interactions in aging.
The SynergyAge data undergoes rigorous validation at three levels:
All survival curves from included papers are manually verified to ensure data accuracy.
The SynergyAge MCP server automatically downloads data from the longevity-genie/bio-mcp-data repository on Hugging Face Hub. This ensures:
The data files are stored in the synergy-age
subfolder of the Hugging Face repository and include:
synergy-age.sqlite
- The complete SynergyAge databasesynergyage_prompt.txt
- Database schema documentation and usage guidelinesThis server provides three main tools for interacting with the SynergyAge database:
synergyage_db_query(sql: str)
- Execute read-only SQL queries against the SynergyAge databasesynergyage_get_schema_info()
- Get detailed schema information including tables, columns, and data descriptionssynergyage_example_queries()
- Get a list of example SQL queries with descriptionsresource://db-prompt
- Complete database schema documentation and usage guidelinesresource://schema-summary
- Formatted summary of tables and their purposes# Download and install uv
curl -LsSf https://astral.sh/uv/install.sh | sh
# Verify installation
uv --version
uvx --version
uvx is a very nice tool that can run a python package installing it if needed.
You can run the synergy-age-mcp server directly using uvx without cloning the repository:
# Run the server in streamed http mode (default)
uvx synergy-age-mcp
# Or explicitly specify stdio mode
uvx synergy-age-mcp stdio
# Run the server in streamable HTTP mode on default (3002) port
uvx synergy-age-mcp server
# Run on a specific port
uvx synergy-age-mcp server --port 8000
# Run the server in SSE mode
uvx synergy-age-mcp sse
In cases when there are problems with uvx often they can be caused by cleaning uv cache:
uv cache clean
The HTTP mode will start a web server that you can access at http://localhost:3002/mcp
(with documentation at http://localhost:3002/docs
). The STDIO mode is designed for MCP clients that communicate via standard input/output, while SSE mode uses Server-Sent Events for real-time communication.
Note: Currently, we do not have a Swagger/OpenAPI interface, so accessing the server directly in your browser will not show much useful information. To explore the available tools and capabilities, you should either use the MCP Inspector (see below) or connect through an MCP client to see the available tools.
We provide preconfigured JSON files for different use cases:
mcp-config-stdio.json
mcp-config.json
mcp-config-stdio-debug.json
For a visual guide on how to configure MCP servers with AI clients, check out our configuration tutorial video for our sister MCP server (biothings-mcp). The configuration principles are exactly the same for the SynergyAge MCP server - just use the appropriate JSON configuration files provided above.
If you want to inspect the methods provided by the MCP server, use npx (you may need to install nodejs and npm):
For STDIO mode with uvx:
npx @modelcontextprotocol/inspector --config mcp-config-stdio.json --server synergy-age-mcp
For HTTP mode (ensure server is running first):
npx @modelcontextprotocol/inspector --config mcp-config.json --server synergy-age-mcp
For local development:
npx @modelcontextprotocol/inspector --config mcp-config-stdio-debug.json --server synergy-age-mcp
You can also run the inspector manually and configure it through the interface:
npx @modelcontextprotocol/inspector
After that you can explore the tools and resources with MCP Inspector at http://127.0.0.1:6274 (note, if you run inspector several times it can change port)
Simply point your AI client (like Cursor, Windsurf, ClaudeDesktop, VS Code with Copilot, or others) to use the appropriate configuration file from the repository.
# Clone the repository
git clone https://github.com/longevity-genie/synergy-age-mcp.git
cd synergy-age-mcp
uv sync
If you already cloned the repo you can run the server with uv:
# Start the MCP server locally (HTTP mode)
uv run server
# Or start in STDIO mode
uv run stdio
# Or start in SSE mode
uv run sse
-- Get top genetic interventions with highest lifespan effects
SELECT genes, effect, details, model_organism
FROM models
WHERE effect > 0
ORDER BY effect DESC
LIMIT 10;
-- Find synergistic interactions in C. elegans
SELECT m1.genes as gene1, m2.genes as gene2, mi.phenotype_comparison
FROM model_interactions mi
JOIN models m1 ON mi.id1 = m1.id
JOIN models m2 ON mi.id2 = m2.id
WHERE m1.tax_id = 6239 AND m2.tax_id = 6239
AND mi.phenotype_comparison LIKE '%synergistic%';
-- Compare insulin signaling pathway effects across organisms
SELECT tax_id, genes, effect, details
FROM models
WHERE genes LIKE '%daf-2%' OR genes LIKE '%InR%' OR genes LIKE '%IGF1R%'
ORDER BY tax_id, effect DESC;
-- Find interventions with antagonistic interactions
SELECT m1.genes, m2.genes, mi.phenotype_comparison
FROM model_interactions mi
JOIN models m1 ON mi.id1 = m1.id
JOIN models m2 ON mi.id2 = m2.id
WHERE mi.phenotype_comparison LIKE '%antagonistic%'
OR mi.phenotype_comparison LIKE '%suppress%';
-- Get average lifespan effects by organism
SELECT tax_id, COUNT(*) as intervention_count,
AVG(effect) as avg_effect,
MAX(effect) as max_effect
FROM models
WHERE effect IS NOT NULL
GROUP BY tax_id
ORDER BY avg_effect DESC;
The MCP server is provided with comprehensive tests including LLM-as-a-judge tests that evaluate the quality of responses to complex queries. However, LLM-based tests are disabled by default in CI to save costs.
If you want to run LLM agent tests that use MCP functions with Gemini models, you need to set up a .env
file with your Gemini API key:
# Create a .env file in the project root
echo "GEMINI_API_KEY=your-gemini-api-key-here" > .env
Note: The .env
file and Gemini API key are only required for running LLM agent tests. All other tests and basic MCP server functionality work without any API keys.
Run tests for the MCP server:
uv run pytest -vvv -s
You can also run manual tests:
uv run python tests/manual_test_questions.py
You can use MCP inspector with locally built MCP server same way as with uvx.
Note: Using the MCP Inspector is optional. Most MCP clients (like Cursor, Windsurf, etc.) will automatically display the available tools from this server once configured. However, the Inspector can be useful for detailed testing and exploration.
If you choose to use the Inspector via npx
, ensure you have Node.js and npm installed. Using nvm (Node Version Manager) is recommended for managing Node.js versions.
We welcome contributions from the community! ๐ Whether you're a researcher, developer, or enthusiast interested in aging and longevity research, there are many ways to get involved:
We especially encourage you to try our MCP server and share your feedback with us! Your experience using the server, any issues you encounter, and suggestions for improvement are incredibly valuable for making this tool better for the entire research community.
Tutorials, videos, and user stories are especially valuable to us! We're working to push the aging research community toward AI adoption, and real-world examples of how researchers use our MCP servers help demonstrate the practical benefits and encourage wider adoption.
git checkout -b feature/amazing-feature
)uv run pytest
)git commit -m 'Add amazing feature'
)git push origin feature/amazing-feature
)black
for formatting)Don't hesitate to open an issue for discussion! We're friendly and always happy to help newcomers get started. Your contributions help advance open science and longevity research for everyone. ๐งฌโจ
The SynergyAge MCP server currently provides access to the core experimental data tables. Future versions may include additional metadata tables and extended functionality based on community feedback and research needs.
While we provide comprehensive tests including LLM-as-a-judge evaluations, not all test cases have been manually verified against the actual SynergyAge web interface. Some automated test results may need manual validation to ensure accuracy. Contributions to improve test coverage and validation are welcome.
This project is licensed under the MIT License.
If you use SynergyAge data in your research, please cite:
Bunu, G., Toren, D., Ion, C. et al. SynergyAge, a curated database for synergistic and antagonistic interactions of longevity-associated genes. Sci Data 7, 366 (2020). https://doi.org/10.1038/s41597-020-00710-z
This project is part of the Longevity Genie organization, which develops open-source AI assistants and libraries for health, genetics, and longevity research.
We also develop other specialized MCP servers for biomedical research:
We are supported by:
HEALES - Healthy Life Extension Society
and
IBIMA - Institute for Biostatistics and Informatics in Medicine and Ageing Research