Skip to main content

MAGATAMA MCP Server - AI Coding Support via Model Context Protocol

Project description

magatama - AI Coding Support MCP Server

PyPI version Python 3.11+ License: MIT

MAGATAMAYATA のフォーク)の MCP サーバーパッケージです(PyPI 配布名 magatama / import 名 magatama_mcp / CLI コマンド magatama)。

Model Context Protocol (MCP) サーバーとして、AI コーディングツールに知識グラフコンテキストを提供します。

特徴

  • 🤖 MCP 完全対応: 36 Tools, 3 Prompts, 1 Resource
  • 🔌 comP Bridge: comP の .comp/index.db を再パースなしで知識グラフに取り込み
  • 🔌 AI ツール連携: Claude Desktop, GitHub Copilot, Cursor
  • 📡 複数トランスポート: stdio / SSE
  • 🔒 プライバシー: 完全ローカル実行

インストール

pip install magatama

使用方法

CLI コマンド

# ファイルを解析
magatama parse path/to/file.py

# ディレクトリを解析
magatama parse path/to/project --pattern "**/*.py"

# MCP サーバーを起動(stdio)
magatama serve

# MCP サーバーを起動(SSE)
magatama serve --transport sse --port 8080

# エンティティを検索
magatama query "function_name" --type function

# 統計情報を表示
magatama stats

# グラフの整合性を検証
magatama validate --graph graph.json --repair

AI ツール設定

Claude Desktop

{
  "mcpServers": {
    "magatama": {
      "command": "magatama",
      "args": ["serve"]
    }
  }
}

GitHub Copilot (VS Code)

.vscode/mcp.json:

{
  "mcpServers": {
    "magatama": {
      "command": "magatama",
      "args": ["serve"]
    }
  }
}

MCP Tools

36 ツールを提供します(基本・フレームワーク知識・検索・品質分析・ AI 支援・comP Bridge)。下表は基本ツールの抜粋で、全 36 ツールの一覧は ルート README を参照してください。

Tool 説明
parse_file ソースファイルを解析してエンティティを抽出
parse_directory ディレクトリ内のファイルを一括解析
search_entities 名前や型でエンティティを検索
get_entity / get_related_entities 詳細取得 / 関連エンティティ取得
get_graph_stats 知識グラフの統計情報を取得
save_graph / load_graph JSON への保存 / 読み込み
read_external_graph comP Bridge: comP インデックスを取り込み
get_external_graph_info comP Bridge: comP インデックスの統計を確認

MCP Prompts

Prompt 説明
analyze_codebase コードベース構造を分析
explain_entity コードエンティティを説明
find_dependencies 依存関係を分析

ライセンス

MIT License - 詳細は LICENSE を参照してください。

関連プロジェクト

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

magatama-0.6.0.tar.gz (46.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

magatama-0.6.0-py3-none-any.whl (31.3 kB view details)

Uploaded Python 3

File details

Details for the file magatama-0.6.0.tar.gz.

File metadata

  • Download URL: magatama-0.6.0.tar.gz
  • Upload date:
  • Size: 46.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for magatama-0.6.0.tar.gz
Algorithm Hash digest
SHA256 e820012a0ba07f5c945cfa3cf0776c5b59b8f07b0b52939bcbed634b71e61c66
MD5 16881c20cce8a6262f861c4bc109fa6b
BLAKE2b-256 85db12fc7694dd0247088c935b0891b7cdcb520123cdc4b61373a2a0407cecf9

See more details on using hashes here.

File details

Details for the file magatama-0.6.0-py3-none-any.whl.

File metadata

  • Download URL: magatama-0.6.0-py3-none-any.whl
  • Upload date:
  • Size: 31.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for magatama-0.6.0-py3-none-any.whl
Algorithm Hash digest
SHA256 082f023e48819f5d343ab34b9efd7046b73bf9da1236182af688e721202995dc
MD5 6ca9a0cd10ab2f7b28f31eb4f1d66fdd
BLAKE2b-256 a04d4060ff3416b076b7ba22e39e3f9fb2bf2373a7fad2720f40911c150ba7b1

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page