Skip to content
news / verify-places · raw .md
AgentsUpdated 6 min readMapMap engineering
Abstract diagram of an itinerary as linked place nodes passing through a screening lattice: several stamped solid, one diverted out of line by a contradiction strike, the rest left as hollow outlines.

A geo-hallucination firewall for AI itineraries

When a language model invents a restaurant, or plans breakfast in Bath and a 10am meeting in Edinburgh, the failure does not stay in the chat window. It ships to a real user standing on a real pavement. Our verify service checks whether the places and itineraries an AI mentioned are real, findable and physically possible, using MapMap's own geocoder and routing engine as evidence. Every claim gets exactly one of three verdicts, verified, contradicted or unverified, and never a boolean. It is live today at POST /api/verify on the website, and it is deliberately conservative about what it will assert.

Why a boolean is the wrong shape for a truth check

A true or false answer to "does this place exist" claims more certainty than any geocoder can honestly deliver, so each claim comes back with one of three verdicts instead.

VerdictMeaning
verifiedMatched a real place in MapMap's index, returned with the matched place, a stable id, and the source and date of the evidence.
contradictedA specific, dated, sourced fact rules the claim out. In this release the only such fact is an itinerary leg the routing engine proves cannot be driven in the claimed time.
unverifiedNo evidence either way: no confident name match, or the check could not run.

The asymmetry is the point. A missing geocoder match is not proof of anything, so it stays unverified. Promotion to contradicted needs positive evidence with a source and a timestamp attached, and the response carries that evidence so a calling agent can show its working rather than repeat ours on faith.

How does an itinerary get contradicted?

Consecutive claims that carry a sequence and a claimed_time form legs, and each leg is priced through POST /matrix in the request's costing (default auto). If the itinerary says you leave the Roman Baths at 9am and reach Edinburgh Castle at 10am, the routing engine computes whether that leg is drivable in 60 minutes.

sh
curl -fsS -X POST https://mapmap.ai/api/verify \
  -H "Content-Type: application/json" \
  -d '{
  "claims": [
    { "id": "breakfast", "name": "The Roman Baths", "locality": "Bath",
      "sequence": 1, "claimed_time": "2026-08-01T09:00:00+01:00" },
    { "id": "meeting", "name": "Edinburgh Castle", "locality": "Edinburgh",
      "sequence": 2, "claimed_time": "2026-08-01T10:00:00+01:00" }
  ],
  "costing": "auto"
}'

The response, captured on 25 November 2026 and trimmed here:

json
{
  "results": [
    {
      "id": "breakfast",
      "verdict": "verified",
      "match": { "id": "osm:w500279537", "name": "The Roman Baths",
                 "lat": 51.3810283, "lon": -2.359675, "category": "attraction" },
      "evidence": [
        { "source": "mapmap-geocode", "checked_at": "2026-11-25T16:39:37.027Z",
          "detail": "matched \"The Roman Baths\" (attraction) in the MapMap geocode index." }
      ]
    },
    {
      "id": "meeting",
      "verdict": "contradicted",
      "match": { "id": "osm:w4301292", "name": "Edinburgh Castle",
                 "lat": 55.9486884, "lon": -3.2004184, "category": "attraction" },
      "evidence": [
        { "source": "mapmap-geocode", "checked_at": "2026-11-25T16:39:37.532Z",
          "detail": "matched \"Edinburgh Castle\" (attraction) in the MapMap geocode index." },
        { "source": "mapmap-matrix", "checked_at": "2026-11-25T16:39:37.716Z",
          "detail": "the routing engine computed 401.7 minutes for this leg, more than the claimed 60 minutes available." }
      ],
      "feasibility": {
        "from_id": "breakfast", "from_name": "The Roman Baths",
        "to_id": "meeting", "to_name": "Edinburgh Castle",
        "available_minutes": 60, "travel_time_minutes": 401.7,
        "status": "impossible"
      }
    }
  ],
  "summary": "2 claims checked: 1 verified, 1 contradicted, 0 unverified. breakfast (\"The Roman Baths\"): verified. meeting (\"Edinburgh Castle\"): contradicted, see evidence. Leg breakfast -> meeting is impossible: 401.7 minutes needed, 60 minutes claimed."
}

Edinburgh Castle is real, so its existence check passes, and the stop is still contradicted: the claim being ruled out is "you can be here at 10am", and the engine's 401.7 minutes is the dated, sourced fact that rules it out. The evidence array carries both checks, so a calling agent can tell the user which part of the plan failed.

feasibility.status is feasible, implausible or impossible, and only impossible flips the arriving stop's verdict to contradicted. The middle state is for legs we cannot rule out. Swap Edinburgh for Bristol Temple Meads at 9:45 and the engine computes 36.2 minutes against 45 claimed: possible, but more than 80% of the window with no allowance for stops, traffic or delay, so the leg is flagged implausible and the stop stays verified. A leg the engine declines to compute at all, for example one longer than its maximum routable distance, is also implausible, never impossible, because a refusal to route says nothing about the claimed time window. Only a real computed travel time may contradict a claim.

You can also send free text ({"text": "Breakfast at the Roman Baths in Bath, then Edinburgh Castle at 10am."}, up to 8,000 characters) and the service extracts place claims best-effort, but free text gets existence checks only: with no explicit times to anchor legs to, there is no feasibility pass. Structured claims are capped at 20 per request. The summary string is always present alongside the structured results, because several MCP clients drop non-text content blocks and the text has to stand on its own.

Why we never say a business has closed

The service never asserts that a named real business does not exist or has closed, and that rule is enforced in code rather than by policy. "Closed" and "never existed" are exactly the claims that damage a real business if we are wrong, and MapMap's index is a live OpenStreetMap-derived snapshot with no lifecycle flag, so a missing match is evidence of nothing. The only negative outputs the API can produce are "contradicted, with a dated source" and "unverified".

The enforcement is structural. Every sentence the implementation generates comes from a fixed template switched over the three-member verdict type, so a fourth "does not exist" state cannot be added without a compile error. The test suite then statically scans the implementation source for banned phrases ("does not exist", "has closed", "no longer trading" and friends), and separately fuzzes the render path with adversarial claim names to prove the guard survives real, unsanitised input.

Matching is deliberately strict for the same reason, in the other direction: a false unverified is safe, a false verified defeats the product. Live testing found "The Sherlock Holmes Museum Annexe", a plausible-sounding embellishment of the real, annexe-free museum, scoring 0.75 token-overlap against the real name. That is why the match threshold sits at 0.85. Similarly, country-level words in locality are stripped before querying, because appending "UK" to a name search adds noise rather than signal.

What it does not do yet

The honest list, current as of this post.

  • The gateway path is not built. POST /api/verify is the website's demo proxy: a server-held demo key, rate-limited per IP (429 with Retry-After). The first-class POST /verify on the gateway itself, authenticated with your own key and metered at Standard rate per existence check and per feasibility leg, is tracked but not yet implemented.
  • The MCP tool returns coarser ids. verify_places is live on the hosted MCP endpoint at https://mcp.mapmap.ai/mcp and gives the same verdicts (the Bath to Edinburgh request above comes back with the same 401.7 minutes), but the geocode client behind the tool carries no OpenStreetMap id, so a verified match comes back with a coordinate fallback id (latlon:51.38103,-2.35968) instead of the osm: id the website route returns.
  • Feasibility is the only contradiction source. No opening-hours checks, no closure signals. A future iteration could read a matched business's own website for its own opening-hours markup, and only the business's own site, never aggregators, but that is not implemented.
  • Your own /places datasets are not wired in. "Is this claimed branch one of ours" is a different question from "does this place exist", and today it needs a separate call with your own key.
  • checked_at is our check's timestamp, not the underlying map data's edit date.

Try it

The curl above runs against the live site with no key. To go deeper, the full request and response contract, error table and evidence-source notes are in the verify section of the API reference, and the MCP server documentation covers connecting an agent to verify_places and the rest of the toolset. The evidence layer underneath is the same geocoder we wrote about in how our geocoding works, and the reason a verification API exists at all is the argument of maps built for AI agents: agents are becoming the first callers of mapping infrastructure, and an agent that can check its own claims before a human sees them is worth more than one that sounds confident.