MCP.so
ログイン
G

Graph Context MCP Server

@yuqiaohan95

基本情報

カテゴリ

その他

トランスポート

stdio

作者

yuqiaohan95

投稿者

yuqiao han

Graph Context MCP Server について

MCP server for intelligent code context — 87%+ token savings, zero resource overhead.

Graph Context MCP Server の設定

以下の設定を使って、このサーバーを MCP 対応クライアントに追加してください。

{
  "mcpServers": {
    "graph-context": {
      "command": "python",
      "args": [
        "-m",
        "tests.experiment"
      ]
    }
  }
}

Graph Context MCP Server のツール

ツール一覧はまだありません

この掲載には表示できるツール一覧がまだありません。サーバーにツールがないという意味ではありません。対応機能はプロジェクトのドキュメントをご確認ください。

ツールは README から自動的に抽出されます。メンテナーは ## Tools という見出しの下に記載することで、このタブに反映できます。

概要

What is Graph Context?

Graph Context is an MCP server that retrieves precise code context using AST call graphs and BM25 ranking, designed for AI coding assistants. It runs pure Python with no GPU or external services, delivering token savings of 87%+ for single-agent and multi-agent workflows.

How to use Graph Context?

Install with pip install graph-context (or graph-context[full] for Chinese tokenization and file watching). Run as an MCP server with the command graph-context, optionally setting environment variables like PROJECT_ROOT, MCP_MAX_TOKENS, and MCP_TOP_K. Integrate with Claude Desktop, Cursor, or Cline via a JSON configuration pointing to the command. Programmatic usage is also available via the VibeCodingEngine class.

Key features of Graph Context

  • AST call graph for precise cross‑file dependency resolution
  • BM25 ranking with self‑evolving rules engine
  • Dynamic tool loading — only 2 tools at startup (~270 tokens)
  • MVCC snapshots for read‑write isolation in multi‑agent setups
  • Zero external dependencies: pure CPU, no GPU, no network calls
  • Built‑in Chinese‑English synonym mapping for cross‑language queries

Use cases of Graph Context

  • Single‑agent coding sessions: stable ~2,000 tokens per turn, no forgetting
  • Multi‑agent collaboration: shared index with independent snapshot reads
  • Reducing LLM API costs by cutting token consumption 76–90%
  • On‑demand code retrieval for large projects without dumping the whole codebase

よくある質問

1

How does Graph Context compare to vector‑database approaches?

Graph Context requires no vector DB deployment, no GPU for embeddings, no external API calls, and no large memory footprint. It uses lightweight BM25 inverted indices and AST‑level exact matching instead of semantic similarity.

2

What are the runtime requirements?

Pure Python — no GPU, no external services. The `full` install adds Chinese tokenization and file‑watching dependencies. Index persistence and rules are stored as local JSON files (configurable paths).

3

Where does my code and data live?

All data stays local on your machine. Index persistence is optional; by default the index is built in memory. Rules and scopes are saved to JSON files on disk (paths controlled by `MCP_RULES_PATH` and `MCP_SCOPES_PATH`).

4

What transport or authentication does Graph Context use?

It runs as a local MCP server over stdio transport, started via the `graph-context` command. No authentication is required because it operates entirely on the local machine.

5

Are there any known limits or accuracy trade‑offs?

Benchmarks show 100% recall on small projects and up to 97% recall on large projects when using the self‑evolving rules engine. Token savings range from 76% to 91% depending on project size and whether rules are applied.

コメント

「その他」の他のコンテンツ