MCP server connecting AI coding agents to graph-native code context and multi-agent pipelines.
Project description
ohwise-mcp
MCP server connecting AI coding agents to graph-native code context and multi-agent pipelines.
ohwise-mcp implements the Model Context Protocol so that any MCP-compatible AI agent (Claude Code, Claude Desktop, and others) can:
- Build and query knowledge graphs from code repositories via codebase2graph
- Build and query knowledge graphs from documents via docs2graph
- Rank the most relevant nodes for any query using Personalized PageRank
- Trigger and poll OhWise Studio pipelines for multi-agent task execution
Pure Python. No LLM dependency for graph tools. Bring your own model.
Quick start
pip install ohwise-mcp[all]
Add to Claude Code
claude mcp add ohwise -- ohwise-mcp
Or manually in your Claude Code config (~/.claude.json or .mcp.json):
{
"mcpServers": {
"ohwise": {
"command": "ohwise-mcp",
"env": {
"OHWISE_URL": "https://your-ohwise-instance.com",
"OHWISE_TOKEN": "your-token-here"
}
}
}
}
OHWISE_URLandOHWISE_TOKENare only required for Studio pipeline tools. Graph tools work offline without them.
Tools
Code graph tools
| Tool | Description |
|---|---|
build_code_graph(repo_path, graph_type) |
Extract a knowledge graph from a code repository |
rank_code_nodes(query, graph_id, k) |
Rank nodes by relevance to a query — get focused code context |
search_code_graph(keyword, graph_id, kind_filter) |
Find nodes by keyword or kind (function, class, file, …) |
Graph types: all, call, entity, schema, workflow, infra, security, web, android, decision, folder
Document graph tools
| Tool | Description |
|---|---|
build_doc_graph(paths, graph_type) |
Extract a knowledge graph from documents (PDF, DOCX, MD, HTML, …) |
rank_doc_nodes(query, graph_id, k) |
Rank document nodes by relevance — get focused document context |
OhWise Studio tools (requires OHWISE_URL + OHWISE_TOKEN)
| Tool | Description |
|---|---|
start_pipeline(user_input, agent_ids) |
Trigger an OhWise coordinator pipeline |
get_pipeline_result(thread_id, poll_seconds) |
Poll a pipeline for results |
Example usage in Claude Code
Once configured, Claude Code can use graph context automatically:
> What does the authentication flow look like in this repo?
Claude Code calls build_code_graph → rank_code_nodes("authentication flow") → receives ranked nodes with call relationships and content snippets → answers with precise, relationship-aware context.
> Delegate this refactoring task to the OhWise pipeline and get back the plan
Claude Code calls start_pipeline → OhWise native agents run in parallel → Claude Code receives the synthesized result.
Installation variants
# Graph tools only (no OhWise backend needed)
pip install ohwise-mcp[code] # code graphs
pip install ohwise-mcp[docs] # document graphs
pip install ohwise-mcp[all] # both
# Core only (Studio pipeline tools work without graph extras)
pip install ohwise-mcp
Python API
The tools are also importable directly:
from ohwise_mcp.server import mcp
# Run as MCP server
mcp.run()
Design principles
- No LLM dependency — graph construction is pure static analysis
- Offline-first — code and document graph tools work without any server
- Composable — works standalone or alongside OhWise Studio
- Model-agnostic — any MCP-compatible agent can use these tools
Related projects
| Package | What it does |
|---|---|
| codebase2graph | Code repository → knowledge graph |
| docs2graph | Documents → knowledge graph |
| graph2sql | Schema graph → SQL context |
Contributing
git clone https://github.com/jw-open/ohwise-mcp
cd ohwise-mcp
pip install -e ".[dev]"
pytest tests/ -v
License
Apache-2.0 — see LICENSE
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file ohwise_mcp-0.1.1.tar.gz.
File metadata
- Download URL: ohwise_mcp-0.1.1.tar.gz
- Upload date:
- Size: 10.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.14.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
46d8c7c72ca20bdca9ddf27dc246a4662de33161786f2f1f6d97832bec99f980
|
|
| MD5 |
fd7f8a2b5a7e804d51fd2be6fad62178
|
|
| BLAKE2b-256 |
bfaafbeebf4c5254e47f97a0506e66a11c6c9eff46f64f7273f43ca1935d89be
|
File details
Details for the file ohwise_mcp-0.1.1-py3-none-any.whl.
File metadata
- Download URL: ohwise_mcp-0.1.1-py3-none-any.whl
- Upload date:
- Size: 9.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.14.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
333c9b3f3916cfbae16c6a015e8a7f94390b8ca89346bf7126e1a4047d6b31ab
|
|
| MD5 |
a9215a17fdde8e7d6934e9ed9e47e021
|
|
| BLAKE2b-256 |
d289a4711ef42fa08555707f79af34d7b3746d6fa08fba3b4c4b762d60aa21fb
|