Japan Real Estate Intel
<p align="center">
<a href="https://realestate-mcp.jp/dashboard.html?prefecture=aichi">
<img src="docs/screenshots/dashboard-overview.png" width="900" alt="Japan Real Estate Intel dashboard — land price map and investment score for Aichi">
</a>
</p>
<p align="center">
<img src="assets/logo.svg" width="120" alt="RE Intel JP Logo">
</p>
# Japan Real Estate Intel MCP
[](https://www.npmjs.com/package/@sugukuru/japan-real-estate-intel-mcp) [](https://www.npmjs.com/package/@sugukuru/japan-real-estate-intel-mcp) [](https://github.com/SUGUKURU-CO-LTD/japan-real-estate-intel-mcp/actions/workflows/ci.yml) [](LICENSE) [](https://nodejs.org) [](https://github.com/SUGUKURU-CO-LTD/japan-real-estate-intel-mcp/pkgs/container/japan-real-estate-intel-mcp) [](https://registry.modelcontextprotocol.io/v0.1/servers?search=japan-real-estate-intel)
**Real estate intelligence across 10 Japanese prefectures via MCP (`@modelcontextprotocol/server` v2 + `@modelcontextprotocol/ext-apps`).** Analyze area scores, land prices, disaster hazard risk, zoning compliance, arbitrage spreads, store siting, 10-year leveraged cashflow, and portfolio allocation through Claude, ChatGPT, Cursor, or any MCP client.
**Registry:** `io.github.sugukurukabe/japan-real-estate-intel-mcp` (`server.json` follows the `2025-12-11` registry schema; tool list lives in `_meta["io.modelcontextprotocol.registry/publisher-provided"].tools`).
## Try in 60 seconds (Free tier — no login required)
Copy into Claude, Cursor, or ChatGPT after installing:
```
analyze_area で「東京都 新宿区」を投資視点(focus: "investment")で分析して
```
```
discover_opportunities で愛知県の investment 向けエリアを探して。limit=5
```
Interactive 2D Map: [Dashboard (Aichi)](https://realestate-mcp.jp/dashboard.html?prefecture=aichi)
> Free plan includes 10 core tools (up to 50 tool calls / month UTC) and 1 prompt (`quick_start_examples`). Pro unlocks all **16 tools** and **6 prompts** (PDF/Excel/CSV artifact exports, multi-prefecture comparison, purchase review, portfolio optimization, store site scoring) via signed `X-License-Key` / `_licenseKey`.
## Data Freshness & Trust
| Item | Detail |
|------|--------|
| **Coverage** | 10 prefectures: Aichi, Tokyo, Osaka, Fukuoka, Hokkaido, Kanagawa, Kyoto, Hyogo, Saitama, Chiba |
| **Bundled Data** | Curated representative snapshots (`data/<prefecture>/` CSV / JSON / GeoJSON / TopoJSON) for fast, offline-capable analysis and demonstrations |
| **Live Refresh** | Run `npm run data:fetch` with `MLIT_API_KEY` / `ESTAT_APP_ID` to refresh official government data locally |
| **Optional Live Enrichment** | `detect_arbitrage_signals` (`includeExternalFreshness: true` with `MLIT_API_KEY`) and `get_real_estate_macro_snapshot` (`includeExternalSeries: true` with `ESTAT_APP_ID` / `FRED_API_KEY`) enrich bundled snapshots with live public statistics |
| **SQLite Runtime** | Uses `better-sqlite3` when available, with automatic fallback to Node built-in `node:sqlite` (`DatabaseSync`) |
## Quick Install
**Claude Desktop / stdio (`npx`):**
```bash
npx @sugukuru/japan-real-estate-intel-mcp
```
**Remote Connector (Streamable HTTP — authless):**
```json
{
"mcpServers": {
"japan-real-estate-intel": {
"url": "https://realestate-mcp.jp/mcp"
}
}
}
```
> `https://realestate-mcp.jp/mcp` requires no OAuth or login. Optional `X-Api-Key` only applies to self-hosted deployments that set `API_KEY`. `X-License-Key` / `_licenseKey` activates Pro/Enterprise tiers.
**Cursor (`.cursor/mcp.json`):**
```json
{
"mcpServers": {
"japan-real-estate-intel": {
"command": "npx",
"args": ["@sugukuru/japan-real-estate-intel-mcp"]
}
}
}
```
## Key Features
- **16 Consolidated Tools** (10 Free, 6 Pro) with strict Zod `inputSchema` / `outputSchema`, `output_mode` (`compact` default for token efficiency, or `detailed`), bilingual descriptions (`EN | JA`), and official MCP tool annotations (`readOnlyHint`, `destructiveHint`, `idempotentHint`, `openWorldHint`).
- **6 Guided Prompts** with `completable()` prefecture and city auto-completion.
- **5 Resources** (`realestate://land-price/{prefecture}/{area}`, `hazard://flood/{prefecture}/{area}`, `stats://population-trend/{prefecture}/{area}`, `artifact://{id}`, and `ui://japan-real-estate-intel/dashboard`).
- **Inline-First MCP Apps UI (`@modelcontextprotocol/ext-apps`)**:
- Single-tool calls render lightweight inline summary cards (`WidgetOverlay` / `AutoWidget` across all 12 analytical UI tools) with host CSS theme integration, client-side **CSV / PNG export**, and an on-demand **「地図で開く」** switch.
- Interactive **2D Leaflet Dashboard** (`open_map_dashboard`) with **6 verified map layers** (`land_price`, `flood_risk`, `population`, `transport`, `commercial_facilities`, `medical_facilities`) and **side-by-side prefecture comparison**.
---
## ツール一覧(全 16 統合ツール)
正確なツール一覧は [`server.json`](server.json) の `_meta["io.modelcontextprotocol.registry/publisher-provided"].tools` および [`src/tiers.ts`](src/tiers.ts) で定義されています。
### Free プラン(10 ツール)
| ツール名 | 役割 |
|---|---|
| `search` | 10都府県・市区町村・町丁目・データソース・ツールカタログを横断検索 |
| `fetch` | `search` で取得した ID(`area:...`, `pref:...`, `tool:...` 等)の詳細を取得 |
| `analyze_area` | 地価・総合5軸スコア・災害リスク・空き家率・人流・教育・企業・通勤アクセスを一括統合分析(ウィジェット対応) |
| `assess_property_risk` | 浸水・土砂災害・想定地震震度による物件リスク評価と価格調整率を算出(ウィジェット対応) |
| `discover_opportunities` | 投資・店舗出店・ファミリー・オフィスの目的に応じて有望エリアを発掘(ウィジェット対応) |
| `detect_arbitrage_signals` | 路線価(推計/NTA)× 公示地価 × 実勢取引価格の乖離から割安・過熱シグナルを検知(ウィジェット対応) |
| `forecast_market_trend` | 地価CAGR予測とNIPSSR将来人口推計・高齢化率推移を統合予測(ウィジェット対応) |
| `check_zoning` | 用途地域・建蔽率・容積率・高さ制限の照会と建築計画適合チェックを一括実行(ウィジェット対応) |
| `simulate_leveraged_cashflow` | 借入条件を含む10年レバレッジキャッシュフロー(NOI・DSCR・IRR・税引後CF・感応度)を試算(ウィジェット対応) |
| `open_map_dashboard` | 10都府県・6レイヤー対応のインタラクティブ2D Leaflet地図ダッシュボードを開く |
### Pro プラン(+6 ツール、計 16 ツール)
| ツール名 | 役割 |
|---|---|
| `evaluate_store_location` | コンビニ・カフェ・ファミレス・ドラッグストア・スーパーの出店適地を8軸で評価(ウィジェット対応) |
| `get_real_estate_macro_snapshot` | 都道府県単位のマクロ不動産指標(地価YoY・取引・人口動態・任意でe-Stat/FRED)を取得(ウィジェット対応) |
| `review_purchase_recommendation` | 売出価格・利回り・災害リスク・契約条項(違約金・現況引渡し等)を5軸で審査(ウィジェット対応) |
| `compare_prefectures` | 2〜5都道府県を横並び比較し、レーダーチャート・ランキング・Excel(`xlsx`)アーティファクトを出力(ウィジェット対応) |
| `optimize_portfolio` | 複数保有・検討物件のポートフォリオ配分・リスク調整後リターンを最適化し、CSV出力に対応(ウィジェット対応) |
| `generate_area_report` | 投資・開発・賃貸・管理向けのMarkdown / PDFエリアレポートを生成し `resource_link` で提供 |
## プロンプト一覧(6 種)
- `quick_start_examples` (Free): ユースケース別の実践プロンプト例を案内
- `investment_report` (Pro): 都道府県・市区町村の投資判断レポート作成フロー
- `store_location_evaluation` (Pro): 店舗出店適地評価テンプレート
- `prefecture_comparison` (Pro): 都道府県比較テンプレート
- `market_trend_forecast` (Pro): 地価・人口動態の将来予測テンプレート
- `portfolio_optimization` (Pro): ポートフォリオ最適化テンプレート
## リソース URI(5 種)
| URI | 説明 |
|---|---|
| `realestate://land-price/{prefecture}/{area}` | 地価公示データ (JSON) |
| `hazard://flood/{prefecture}/{area}` | 浸水想定区域データ (JSON) |
| `stats://population-trend/{prefecture}/{area}` | 人口推移データ (JSON) |
| `artifact://{id}` | `generate_area_report` / `compare_prefectures` / `optimize_portfolio` が生成した PDF / XLSX / CSV ダウンロード |
| `ui://japan-real-estate-intel/dashboard` | MCP Apps 統合 UI リソース(単一 HTML バンドル) |
---
## 開発・検証
```bash
pnpm install
pnpm run lint # tsc --noEmit
pnpm run lint:ui # tsc -p ui-src/tsconfig.json
pnpm run lint:eslint # eslint src/ ui-src/src/ tests/
pnpm run build # TypeScript + Vite単一バンドル (ui/dashboard.html)
pnpm run test # Vitest スイート
pnpm run test:coverage # Vitest カバレッジ検証
pnpm run verify:ui # Playwright ヘッドレス Chromium スモークテスト
```
## 都道府県の追加手順
1. `data/<key>/` に基本データセット(`land_price.csv`, `population.csv`, `flood.geojson`, `earthquake.json`, `municipalities.topojson` 等)を配置
2. `src/data-loaders/<key>-loader.ts` を作成(`BaseLoader` 継承・`capabilities` 宣言)
3. `src/data-loaders/index.ts` に登録し、`src/prefecture/resolver.ts` にエイリアスを追加
## ライセンス
AGPL-3.0-only([LICENSE](LICENSE) 参照)
TDQS
Scored across 16 tools
Most tools have distinct outputs (risk assessment, zoning lookup, purchase review, portfolio optimization), but several analysis tools overlap heavily in inputs and returned metrics: analyze_area, forecast_market_trend, get_real_estate_macro_snapshot, and compare_prefectures all surface land-price trends and prefecture-level scoring, and generate_area_report vs analyze_area differ mainly in output format. An agent could plausibly pick the wrong one for 'analyze this area and export a report' style requests.
All names are snake_case with a verb_noun pattern (analyze_area, assess_property_risk, compare_prefectures, optimize_portfolio), which is predictable. The only deviations are the bare generic verbs 'search' and 'fetch', which lack a noun and don't follow the domain-specific style of the rest.
16 tools is on the high side but each maps to a recognizable workflow stage (search, analyze, forecast, risk, compare, report, map), so most earn their place. A few analysis tools could be consolidated without loss.
Coverage spans discovery, area/property analysis, risk, macro, forecasting, zoning, financing simulation, portfolio optimization, and export/dashboard outputs — a full lifecycle for property investment research. Gaps are minor: no explicit property-listing lookup or rental-income modeling beyond the leveraged cashflow simulation, and search/fetch is the only catalog access path.