The Adaptive Graph of Thoughts MCP server is a sophisticated framework that performs scientific reasoning using graph structures. This implementation leverages the Model Context Protocol (MCP) to integrate with AI applications like Claude Desktop, providing advanced reasoning capabilities for complex research tasks.
git clone https://github.com/SaptaDey/Adaptive-Graph-of-Thoughts-MCP-server.git
cd Adaptive-Graph-of-Thoughts-MCP-server
poetry install
# Copy example configuration
cp config/settings.example.yaml config/settings.yaml
# Edit configuration as needed
vim config/settings.yaml
poetry run uvicorn src.adaptive_graph_of_thoughts.main:app --reload
Open your browser and navigate to http://localhost:8000/setup
For a containerized deployment:
# Build and run all services
docker-compose up --build
# For detached mode (background)
docker-compose up --build -d
# View logs
docker-compose logs -f adaptive-graph-of-thoughts
For production environments:
# Use production compose file
docker-compose -f docker-compose.prod.yml up --build -d
A Helm chart is provided for Kubernetes deployment:
helm install agot helm/agot-server
To connect the MCP server with Claude Desktop:
{
"mcpServers": {
"adaptive-graph-of-thoughts": {
"command": "python",
"args": ["-m", "adaptive_graph_of_thoughts.main"],
"cwd": "/path/to/Adaptive-Graph-of-Thoughts-MCP-server",
"env": {
"NEO4J_URI": "bolt://localhost:7687",
"NEO4J_USER": "neo4j",
"NEO4J_PASSWORD": "your_password",
"MCP_TRANSPORT_TYPE": "stdio"
}
}
}
}
The server provides several specialized tools for scientific reasoning:
The primary API endpoint is:
POST /mcp
Example request for the asr_got.query
method:
{
"jsonrpc": "2.0",
"method": "asr_got.query",
"params": {
"query": "Analyze the relationship between microbiome diversity and cancer progression.",
"parameters": {
"include_reasoning_trace": true,
"include_graph_state": false
}
},
"id": "123"
}
Check the server status by accessing:
GET /health
Expected response:
{
"status": "healthy",
"version": "0.1.0"
}
If you encounter issues:
For VS Code users, the vscode-agot
extension allows querying the server directly. Install the extension and execute AGoT: Ask Graph… from the Command Palette.
To add this MCP server to Claude Code, run this command in your terminal:
claude mcp add-json "adaptive-graph-of-thoughts" '{"command":"python","args":["-m","adaptive_graph_of_thoughts.main"],"cwd":"/path/to/Adaptive-Graph-of-Thoughts-MCP-server","env":{"NEO4J_URI":"bolt://localhost:7687","NEO4J_USER":"neo4j","NEO4J_PASSWORD":"your_password","MCP_TRANSPORT_TYPE":"stdio"}}'
See the official Claude Code MCP documentation for more details.
There are two ways to add an MCP server to Cursor. The most common way is to add the server globally in the ~/.cursor/mcp.json
file so that it is available in all of your projects.
If you only need the server in a single project, you can add it to the project instead by creating or adding it to the .cursor/mcp.json
file.
To add a global MCP server go to Cursor Settings > Tools & Integrations and click "New MCP Server".
When you click that button the ~/.cursor/mcp.json
file will be opened and you can add your server like this:
{
"mcpServers": {
"adaptive-graph-of-thoughts": {
"command": "python",
"args": [
"-m",
"adaptive_graph_of_thoughts.main"
],
"cwd": "/path/to/Adaptive-Graph-of-Thoughts-MCP-server",
"env": {
"NEO4J_URI": "bolt://localhost:7687",
"NEO4J_USER": "neo4j",
"NEO4J_PASSWORD": "your_password",
"MCP_TRANSPORT_TYPE": "stdio"
}
}
}
}
To add an MCP server to a project you can create a new .cursor/mcp.json
file or add it to the existing one. This will look exactly the same as the global MCP server example above.
Once the server is installed, you might need to head back to Settings > MCP and click the refresh button.
The Cursor agent will then be able to see the available tools the added MCP server has available and will call them when it needs to.
You can also explicitly ask the agent to use the tool by mentioning the tool name and describing what the function does.
To add this MCP server to Claude Desktop:
1. Find your configuration file:
~/Library/Application Support/Claude/claude_desktop_config.json
%APPDATA%\Claude\claude_desktop_config.json
~/.config/Claude/claude_desktop_config.json
2. Add this to your configuration file:
{
"mcpServers": {
"adaptive-graph-of-thoughts": {
"command": "python",
"args": [
"-m",
"adaptive_graph_of_thoughts.main"
],
"cwd": "/path/to/Adaptive-Graph-of-Thoughts-MCP-server",
"env": {
"NEO4J_URI": "bolt://localhost:7687",
"NEO4J_USER": "neo4j",
"NEO4J_PASSWORD": "your_password",
"MCP_TRANSPORT_TYPE": "stdio"
}
}
}
}
3. Restart Claude Desktop for the changes to take effect