Skip to content

160-tool MCP server for real-time global intelligence from free public APIs: markets, liquidity, prediction markets, SEC filings, conflict, military, aircraft-cohort early warning, migration and border flows, cyber, climate, news and more. Dated observation history, 29 research prompts, cited briefs, geofences, SSE dashboard. MIT, no paid API keys.

Docs: document all 139 tools and pin the README reference to the registry

Phoenix Agent (mac-studio)3e970bb07d83
diff --git a/CHANGELOG.md b/CHANGELOG.md
index 597e007..4d2aebf 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -32,6 +32,16 @@ Cross-border migration and a fix to the displacement summary.
`intel_country_signals` can join displacement with the conflict sources;
that join had no displacement input before.
+### Docs
+- README's per-tool reference listed 126 of the 135 tools while every
+ headline count said 135: the 5 newer AOI tools, `intel_bgp_status`,
+ `intel_daily_digest`, and the severe-weather, cyclone, launch and
+ volcano tools were missing. All 139 are listed now, and
+ `test_readme_documents_every_registered_tool` pins the reference and
+ each section's count to the live registry. Collector count 51 -> 53 in
+ README; pyproject description; ROADMAP phases 27-28; CLAUDE.md
+ dispatch note (no `match/case` since Phase 26) and the UNHCR code trap.
+
### Data honesty: migration
- UNHCR figures are year-end stocks, not border crossings; every response
carries a `measure` string saying so. World Bank net migration is
diff --git a/CLAUDE.md b/CLAUDE.md
index 9fbbe3a..39900b2 100644
--- a/CLAUDE.md
+++ b/CLAUDE.md
@@ -77,7 +77,8 @@ collector.py (daemon) ──┘
- **GDELT needs its own timeout**: `api.gdeltproject.org` TCP-connects instantly but its TLS handshake runs 17-20 s and sometimes longer (measured 2026-09-02), and the Fetcher's 15 s default counts TLS inside connect. Every GDELT `get_json` call must pass `timeout=GDELT_TIMEOUT` (from `sources/news.py`, 45 s) or it silently fails and serves stale cache.
- **AOI news is geographic** (`sources/geocode.py`): AOI briefs reverse-geocode the area centre with OSM Nominatim and search GDELT for the settlement/county, never the AOI's name. Nominatim policy: 1 req/s (`_SOURCE_RATE_LIMITS`), identifying User-Agent with contact URL, results cached 30 days. Tests must stub `geocode.fetch_place_context` (the shared `_patch_all_domains` helper in `test_aoi.py` does) — a suite that hits Nominatim live gets rate-limited within seconds.
- **Heatmap tools** (`sources/jet_cohort.py`, `analysis/jet_activity.py`): adsb.lol heatmaps are binary (~14 MB); fetch them with `fetcher.get_bytes` (source `adsblol-history`, 2 s floor) and the on-disk `HeatmapDiskCache`, never the SQLite TTL cache. Tests build synthetic heatmaps with the encoder in `tests/test_jet_activity.py` and zero the rate floor via monkeypatch.
-- **Tool dispatch**: `server.py` uses Python `match/case` to route tool names to source functions. Tool names follow `intel_*` convention.
+- **Tool dispatch**: `server.py` looks the name up in `tools.ALL_HANDLERS` (built by `tools.aggregate()` from each module's `HANDLERS`); there is no `match/case`. Tool names follow the `intel_*` convention, and `test_server_registry.py` fails if README.md's per-tool reference or its counts drift from the registry.
+- **UNHCR codes are not ISO** (`sources/migration.py`, `sources/displacement.py`): UNHCR's own `coo`/`coa` codes differ from ISO-3 (its "AUS" is Austria). Send `cf_type=ISO` and read `coo_iso`/`coa_iso`. Without `coo_all=true` the population endpoint returns one global row (`coo_name` "-"). Its country list also carries two non-countries, UNK "Unknown" and XXA "Stateless", which surge rankings must exclude.
- **All source functions take `fetcher` as first arg** — never construct your own httpx client.
- **Tests strip proxy env vars** automatically via `conftest.py` fixture (prevents SOCKS proxy interference). The conftest also resets global fetcher rate-limit locks between tests to avoid cross-event-loop binding.
diff --git a/README.md b/README.md
index 882fd6b..c2ecd41 100644
--- a/README.md
+++ b/README.md
@@ -8,7 +8,7 @@
Real-time global intelligence across **30+ domains** with **139 MCP tools**, a live ops-center dashboard, a CLI, and a **Qdrant vector store** for enterprise-grade semantic search across accumulated intelligence. All data comes from free, public APIs: no paid subscriptions required.
-Built for AI agents that need world awareness: market conditions, geopolitical risk, military posture, supply chain disruptions, cyber threats, and more — all queryable via the Model Context Protocol. The vector store enables natural language queries like *"military activity near Taiwan"* or *"cyber threats targeting healthcare"* across all historical data.
+Built for AI agents that need world awareness: market conditions, geopolitical risk, military posture, aircraft-cohort early warning, refugee and migration flows, supply chain disruptions, cyber threats, and more — all queryable via the Model Context Protocol. The vector store enables natural language queries like *"military activity near Taiwan"* or *"cyber threats targeting healthcare"* across all historical data.
---
@@ -145,7 +145,7 @@ collector.py (daemon) ─┘
- **CircuitBreaker**: Per-source tracking. 3 consecutive failures trips for 5 minutes. Each RSS feed gets its own breaker.
- **Cache**: SQLite WAL-mode TTL cache. `get()` returns live data, `get_stale()` returns expired data for fallback.
- **VectorStore**: Qdrant + FastEmbed (BAAI/bge-small-en-v1.5, 384-dim). Async background worker queue for non-blocking storage. Enables semantic search across all accumulated intelligence.
-- **Collector**: Standalone daemon that fetches all 51 sources in parallel and populates the vector store. Run once or as a daemon (default: 5-minute interval). Includes the AOI change sweep, so a running daemon continuously watches every defined geofence.
+- **Collector**: Standalone daemon that fetches all 53 sources in parallel and populates the vector store. Run once or as a daemon (default: 5-minute interval). Includes the AOI change sweep, so a running daemon continuously watches every defined geofence.
- **Sources** (`sources/*.py`): 30+ modules, each exports `async def fetch_*(fetcher, **kwargs) -> dict`.
- **Analysis** (`analysis/*.py`): Cross-domain synthesis — signal aggregation, instability indexing, NLP, company enrichment, macro composite.
- **Config** (`config/*.py`): Curated datasets — 22 hotspots, 70+ bases, 40 ports, 24 pipelines, 24 nuclear facilities, 34 cables, 48 datacenters, 27 spaceports, 82 exchanges.
@@ -251,13 +251,14 @@ collector.py (daemon) ─┘
| `intel_military_surge` | Foreign aircraft concentration anomaly detection |
| `intel_usni_fleet` | USNI News naval fleet tracker |
-### Infrastructure (4)
+### Infrastructure (5)
| Tool | Description |
|------|-------------|
| `intel_internet_outages` | Cloudflare Radar internet disruptions |
| `intel_cable_health` | Submarine cable corridor health |
| `intel_cascade_analysis` | Infrastructure cascade simulation |
| `intel_service_status` | Cloud platform health (AWS, Azure, GCP, Cloudflare, GitHub) |
+| `intel_bgp_status` | RIPEstat BGP status for one prefix or ASN: RIS peer visibility, origin ASNs, RPKI validity (a per-resource health check, not global hijack detection) |
### Maritime (2)
| Tool | Description |
@@ -461,14 +462,46 @@ different, openly licensed data source; no ews code is used.
|------|-------------|
| `intel_generate_report` | Generate a PDF or HTML intelligence report covering 18 domains in parallel |
-### AOI Geofences (5)
+### AOI Geofences (10)
| Tool | Description |
|------|-------------|
| `intel_aoi_define` | Define a named area of interest: point + radius in km (1-2000) |
+| `intel_aoi_define_polygon` | Define a polygon AOI from 3-64 [lat, lon] vertices (a border region, a strait, an EEZ) |
+| `intel_aoi_define_corridor` | Define a corridor AOI: 2-64 waypoints plus a width in km (a shipping lane, supply road, cable run) |
+| `intel_aoi_update` | Rename an AOI or change its center/radius in place (a rename keeps its change history) |
| `intel_aoi_list` | List all user-defined AOIs |
| `intel_aoi_delete` | Delete a user-defined AOI by name |
| `intel_aoi_brief` | Cited brief for an AOI: earthquakes, military flights, wildfires, conflict events, aviation, nearby infrastructure, and news mentions, all filtered to the AOI's radius |
| `intel_aoi_escalation` | Hotspot escalation scoring (same engine as the 22 built-in hotspots) applied to a user AOI |
+| `intel_aoi_changes` | What entered or left an AOI since the last sweep (earthquakes, military flights, ACLED events, wildfire clusters, news); the first call sets a baseline |
+| `intel_aoi_digest` | One change sweep across every AOI (or a named subset) with a combined markdown digest; a scheduler can call it on an interval |
+
+### Daily Digest (1)
+| Tool | Description |
+|------|-------------|
+| `intel_daily_digest` | Cited markdown morning brief: top events by domain, recent headlines, and (with the vector store) trends and a 24h timeline; every item carries a [n] citation |
+
+### Severe Weather (2)
+| Tool | Description |
+|------|-------------|
+| `intel_weather_alerts` | US National Weather Service active CAP alerts (US only) |
+| `intel_meteoalarm_alerts` | Meteoalarm severe-weather warnings for 39 European countries (per-country feeds) |
+
+### Tropical Cyclones (2)
+| Tool | Description |
+|------|-------------|
+| `intel_cyclones` | NHC active storms: Atlantic, Eastern and Central Pacific |
+| `intel_jtwc_cyclones` | JTWC warnings: Northwest Pacific, North Indian Ocean, Southern Hemisphere |
+
+### Space Launches (1)
+| Tool | Description |
+|------|-------------|
+| `intel_launch_schedule` | Upcoming rocket launches from Launch Library 2 (cached 1 h for the free tier) |
+
+### Volcanoes (1)
+| Tool | Description |
+|------|-------------|
+| `intel_volcano_activity` | Smithsonian GVP / USGS Weekly Volcanic Activity Report (weekly, curated) |
### Situation Brief (1)
| Tool | Description |
diff --git a/ROADMAP.md b/ROADMAP.md
index d4fac0f..7c5cb56 100644
--- a/ROADMAP.md
+++ b/ROADMAP.md
@@ -1,7 +1,7 @@
# World Intel MCP — Feature Parity Roadmap
**Benchmark**: [koala73/worldmonitor](https://github.com/koala73/worldmonitor)
-**Updated**: 2026-09-02 (v0.10.0)
+**Updated**: 2026-10-11 (unreleased since v0.10.0: aircraft-cohort early warning, cross-border migration)
**Current tools**: 139 (138 intel + 1 status)
---
@@ -132,11 +132,15 @@
| `intel_strategic_ports` | Static dataset (40 ports) | :white_check_mark: |
| `intel_pipelines` | Static dataset (24 pipelines) | :white_check_mark: |
-### Humanitarian & Social (4 tools)
+### Humanitarian & Social (8 tools)
| Tool | WM Equivalent | Status |
|------|---------------|--------|
| `intel_humanitarian_summary` | `get-humanitarian-summary` | :white_check_mark: |
-| `intel_displacement_summary` | `get-displacement-summary` | :white_check_mark: |
+| `intel_displacement_summary` | `get-displacement-summary` | :white_check_mark: (per-origin rows since 2026-10-11; before that one global row) |
+| `intel_migration_flows` | none (beyond parity) | :white_check_mark: UNHCR origin -> destination corridors |
+| `intel_migration_surges` | none (beyond parity) | :white_check_mark: year-over-year mass-movement ranking |
+| `intel_migration_history` | none (beyond parity) | :white_check_mark: per-country series since 1951 |
+| `intel_net_migration` | none (beyond parity) | :white_check_mark: World Bank net migration + migrant stock |
| `intel_social_signals` | Reddit public intelligence | :white_check_mark: |
| `intel_disease_outbreaks` | WHO/ProMED/CIDRAP RSS | :white_check_mark: |
@@ -517,6 +521,35 @@ Also in this phase: `SECURITY.md` with an explicit threat model
gather refactored into a single shared scoping path
(`_gather_scoped_domains`).
+### Phase 27: Aircraft-Cohort Early Warning (+3 = 135 tools)
+`intel_jet_cohort_snapshot`, `intel_jet_activity_anomaly`, `intel_jet_excess_origins`
+
+Approach inspired by kylemcdonald/ews (independent implementation, no
+ews code). Business-jet (69 ICAO types) and military cohorts from
+adsb.lol, learned 24/7 by the collector (`bizjet_cohort`,
+`military_cohort`, collector sources 51 -> 53). The anomaly tool compares
+a UTC half-hour's peak airborne cohort count against the same slot on
+prior same-weekday dates (US holidays swapped out) from `globe_history`
+heatmaps; the excess-origins tool infers takeoffs/landings and clusters
+them. Only aircraft first seen 24 h before the window count, so a fresh
+install answers `warming_up` for a day.
+
+### Phase 28: Cross-Border Migration (+4 = 139 tools)
+`intel_migration_flows`, `intel_migration_surges`, `intel_migration_history`, `intel_net_migration`
+
+UNHCR origin -> destination corridors (about 6,000 for 2025) with
+prior-year change and country/region filters; a surge ranking by
+origin, corridor and internal displacement sized against population
+(World Bank SP.POP.TOTL); per-country series since 1951 as origin or
+host; World Bank net migration and migrant stock for migration of
+every kind. Fixed in the same change: `intel_displacement_summary` had
+never sent `coo_all=true` and returned one global row. All figures are
+year-end stocks (stated in each response), not crossings.
+
+Open: near-real-time displacement (IOM DTM, HDX HAPI: both need keys),
+regional border-crossing series (Frontex, CBP, UK small boats), a
+dashboard flow map, CLI commands and collector sources for migration.
+
---
## Planned Phases
@@ -601,12 +634,12 @@ suite, and a live MCP stdio session.
| Category | Current | Notes |
|----------|---------|-------|
-| Total MCP tools | 128 | 127 intelligence tools + `intel_status` |
-| Tool parity | 128 / 128 | `TOOLS` and `_dispatch()` are aligned (now machine-checked by import-based tests, not text scans) |
+| Total MCP tools | 139 | 138 intelligence tools + `intel_status` |
+| Tool parity | 139 / 139 | `TOOLS` and handlers are aligned at import time; README's per-tool reference is pinned to the registry by `test_readme_documents_every_registered_tool` |
| Static datasets | 18 | Bases, ports, pipelines, nuclear, cables, datacenters, spaceports, minerals, exchanges, trade routes, cloud regions, financial centers |
| RSS feeds | 119 | 24 categories |
-| Tests in repo | 918 | 900 non-smoke tests + 18 live smoke tests (measured 2026-09-02: `pytest -q` -> 900 passed, 18 deselected); full suite requires `.[dev]` |
-| Statement coverage | 91% | Measured 2026-09-01 night full-suite `--cov` (91.18%); was 59% that morning. CI ratchet at 89 |
+| Tests in repo | 965 | 947 non-smoke tests + 18 live smoke tests (measured 2026-10-11: `pytest -m 'not smoke'` -> 947 passed, 18 deselected); full suite requires `.[dev]` |
+| Statement coverage | 92% | Measured 2026-10-11 full-suite `--cov` (91.65%); 91.18% on 2026-09-01, 59% the morning before. CI ratchet at 89 |
| Primary remaining gaps | `cli.py` tests, coverage gate, `server.py` refactor | See Planned Phases 23-26 |
-**Bottom line**: 122 tools across 30+ domains, with the roadmap aligned to the live MCP registry and, for the first time, a forward-looking plan (Phases 23-26): geofence depth, the coverage gate, missing domains, and `server.py` modularization.
+**Bottom line (2026-10-11)**: 139 tools across 30+ domains; Phases 27-28 added aircraft-cohort early warning and cross-border migration. **Earlier (2026-09-02)**: 122 tools across 30+ domains, with the roadmap aligned to the live MCP registry and, for the first time, a forward-looking plan (Phases 23-26): geofence depth, the coverage gate, missing domains, and `server.py` modularization.
diff --git a/pyproject.toml b/pyproject.toml
index 9be744a..ba01d8b 100644
--- a/pyproject.toml
+++ b/pyproject.toml
@@ -1,7 +1,7 @@
[project]
name = "world-intel-mcp"
version = "0.10.0"
-description = "World Intelligence MCP Server — real-time global intelligence across 30+ domains with 100+ MCP tools"
+description = "World Intelligence MCP Server: real-time global intelligence across 30+ domains with 139 MCP tools"
readme = "README.md"
requires-python = ">=3.11"
license = {text = "MIT"}
diff --git a/src/world_intel_mcp/tests/test_server_registry.py b/src/world_intel_mcp/tests/test_server_registry.py
index 31a7062..434764e 100644
--- a/src/world_intel_mcp/tests/test_server_registry.py
+++ b/src/world_intel_mcp/tests/test_server_registry.py
@@ -200,3 +200,32 @@ async def test_dispatch_polygon_and_corridor_round_trip(server) -> None:
for name in ("Registry Poly", "Registry Corridor"):
deleted = await server._dispatch("intel_aoi_delete", {"name": name})
assert deleted.get("deleted") == name
+
+
+_REPO = Path(__file__).resolve().parents[3]
+
+
+def test_readme_documents_every_registered_tool(server) -> None:
+ """The README's per-tool reference had drifted to 126 of 135 tools by
+ 2026-10-11 while every headline count said 135. Pin the reference to
+ the registry itself: same names, and each section's "(n)" matches its
+ rows."""
+ readme = (_REPO / "README.md").read_text()
+ ref = readme.split("## MCP Tools Reference", 1)[1].split("\n## ", 1)[0]
+ registered = {t.name for t in server.TOOLS}
+ listed: list[str] = []
+ for section in re.split(r"^### ", ref, flags=re.M)[1:]:
+ header, _, body = section.partition("\n")
+ rows = re.findall(r"^\| `(intel_[a-z0-9_]+)`", body, re.M)
+ count = re.search(r"\((\d+)\)\s*$", header)
+ assert count, f"README section without a (n) count: {header}"
+ assert int(count.group(1)) == len(rows), f"README '{header}' says {count.group(1)}, lists {len(rows)}"
+ listed.extend(rows)
+ assert len(listed) == len(set(listed)), "a tool is listed twice in the README reference"
+ assert set(listed) == registered, {
+ "undocumented": sorted(registered - set(listed)),
+ "documented_but_not_registered": sorted(set(listed) - registered),
+ }
+ n = len(server.TOOLS)
+ assert f"**{n} MCP tools**" in readme
+ assert f"**Total: {n} tools**" in readme