abr-mcp

abr-mcp

Enables querying and searching the Japanese Address Base Registry (ABR) data definitions and official documentation, including field definitions, datasets, and policy documents through tools like list_datasets, get_dataset, search_field, and search_docs.

Category
Visit Server

README

abr-mcp

アドレス・ベース・レジストリ(ABR / デジタル庁)のデータ定義(仕様)と公式ドキュメントを Claude から参照する MCP サーバ。

データ源は2系統(いずれも公式資料を Markdown 化して同梱、ビルド不要):

  1. データ項目定義(カラム単位)… 公式「データフォーマット(仕様確定版)」(Excel・2024-01-15)を 変換した specs/20240115_policies_base_registry_format_01.md (ファイル名は元の公式 Excel に合わせている)。各データセット(mt_pref, mt_city, mt_town_fullset, mt_rsdtdsp_*, mt_*_pos …)の項目定義表を収録。
  2. ドキュメント(解説・方針・規約)… docs/ 配下の md。デジタル庁公式の データ解説書(試験公開版)・整備改善計画・住所所在地システム共通化・利用規約を、見出し(節)単位で 索引化。「項目の意味」だけでなく「背景・経緯・手続・規約」への問いに答える。

提供ツール

データ項目(カラム):

  • list_datasets() … ABR の全データセット(物理名・日本語名・項目数)を一覧
  • get_dataset(dataset) … 指定データセットの全項目定義(物理名/日本語名/型/桁/Key/説明)
  • search_field(query, limit) … 項目名・日本語名・説明を横断検索(BM25・日本語bigram、関連度順)

ドキュメント:

  • list_documents() … ドキュメント(解説書・整備方針・利用規約 …)を一覧
  • get_document(document, section) … 指定ドキュメントの全文、または見出しで指定した節を返す
  • search_docs(query, limit) … ドキュメントを節(見出し)単位で横断検索(BM25、関連度順)

例:

  • search_field("machiaza_type") → 町字区分コードの定義とコード値(1:大字・町 2:丁目 …)
  • search_field("住居表示フラグ")rsdt_addr_flg を持つ全データセット
  • get_dataset("町字フルセット")mt_town_fullset の全52項目
  • search_docs("地番 レコード件数") → 公開CSVのレコード件数レポート(全国合計+都道府県別。例: 地番 約2.1億件)
  • get_document("abr_record_counts") / get_document("abr_csv_sizes") → 公開CSVの件数・サイズ(圧縮=DL量/展開)の全文
  • search_docs("街区符号 住居番号 道路方式") → 解説書の街区ID/住居マスター収録基準
  • search_docs("アドレス・ベース・レジストリ 政策効果") → 整備改善計画の該当節
  • get_document("利用規約") → 利用規約(PDL1.0・地番マスターの個別制約 等)の全文

使い方

依存は mcp のみ(Python 3.11+)。仕様ファイルは同梱済みでビルド不要。

同梱の .devcontainer/(VS Code / Claude Code)で開くと依存込みの環境が用意され、 .mcp.json により Claude Code が abr MCP を自動認識する。

DevContainer を使わない場合は Python 3.11+ で:

pip install -r requirements.txt
python3 scripts/mcp_server.py     # stdio。起動して即終了しなければOK

Claude Code への登録例:

claude mcp add abr -- python3 /絶対パス/abr-mcp/scripts/mcp_server.py

仕様 md は specs/ 配下を全て読む(ABR_SPECS_DIR で変更、ABR_SPEC_PATH で単一ファイルに固定も可)。 ドキュメントの置き場は ABR_DOCS_DIR で変更できる。 ABR_EXTRA_DOCS_DIRSos.pathsep 区切り)で外部の md フォルダを追加で索引できる(ローカルの md・ 個人メモ等をリポジトリ外に置く用途。docs/ と同形式・同ツールで扱う)。

生成物の更新

specs/docs/ の md はすべて公式資料からの自動生成物(手動編集しない)。再生成は Claude Code スキルが担う:

ABR が新フォーマット等を公開したら該当スキルで再生成する。生成物と元データの対応は SOURCES.md を参照。

ライセンス

  • コードscripts/.claude/skills/・設定ファイル)… MIT License
  • 同梱データspecs/docs/)… 本プロジェクトの著作物ではなく、各出典(下記)の公式資料を Markdown 化した二次生成物。利用は MIT ではなく各出典の規約(主に 公共データ利用規約 第1.0版(PDL1.0)) に従う。詳細は LICENSE 末尾の注記と各ファイルの出典(SOURCES.md)を参照。

出典

同梱の specs/docs/ は、以下の公的機関が公開する資料を加工して作成(編集・加工はzero3kw):

デジタル庁ABRデータの利用にあたっては 利用規約 を確認すること (地番マスター/地番マスター位置参照は登記所備付地図データ利用規約も別途適用。ただし本リポジトリは 住所レコード実体を含まず仕様・文章のみを収録)。

Recommended Servers

playwright-mcp

playwright-mcp

A Model Context Protocol server that enables LLMs to interact with web pages through structured accessibility snapshots without requiring vision models or screenshots.

Official
Featured
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

An AI-powered tool that generates modern UI components from natural language descriptions, integrating with popular IDEs to streamline UI development workflow.

Official
Featured
Local
TypeScript
Audiense Insights MCP Server

Audiense Insights MCP Server

Enables interaction with Audiense Insights accounts via the Model Context Protocol, facilitating the extraction and analysis of marketing insights and audience data including demographics, behavior, and influencer engagement.

Official
Featured
Local
TypeScript
VeyraX MCP

VeyraX MCP

Single MCP tool to connect all your favorite tools: Gmail, Calendar and 40 more.

Official
Featured
Local
graphlit-mcp-server

graphlit-mcp-server

The Model Context Protocol (MCP) Server enables integration between MCP clients and the Graphlit service. Ingest anything from Slack to Gmail to podcast feeds, in addition to web crawling, into a Graphlit project - and then retrieve relevant contents from the MCP client.

Official
Featured
TypeScript
Kagi MCP Server

Kagi MCP Server

An MCP server that integrates Kagi search capabilities with Claude AI, enabling Claude to perform real-time web searches when answering questions that require up-to-date information.

Official
Featured
Python
E2B

E2B

Using MCP to run code via e2b.

Official
Featured
Neon Database

Neon Database

MCP server for interacting with Neon Management API and databases

Official
Featured
Exa Search

Exa Search

A Model Context Protocol (MCP) server lets AI assistants like Claude use the Exa AI Search API for web searches. This setup allows AI models to get real-time web information in a safe and controlled way.

Official
Featured
Qdrant Server

Qdrant Server

This repository is an example of how to create a MCP server for Qdrant, a vector search engine.

Official
Featured