Skip to main content
Glama

expand_kg_pois

Read-only

Attraktionen / Tourismus-POIs FÜR einen Place aus dem OSM-Knowledge-Graph (Ausdehnung einer Stadt-/Region-OSM-ID auf die POIs darin). Für „was kann ich in X unternehmen" ist dieses Werkzeug die Auskunft — erst verorten, dann abfragen: die osm_id der Region stammt aus search_place. Tool-Semantik-Abgrenzung: dieses Tool = „WELCHE Attraktionen gibt es IN diesem Place" (KG-basiert). NICHT nearby (das ist Vicinity — „Dinge im Radius um EINEN Punkt"). NICHT search_place (das ist Place- Disambiguierung — „WELCHER Ort ist gemeint"). NICHT resolve_location (Transit-Halte). When to use: Region-Tourismus — DE: „was kann ich in unternehmen", „was gibt es in zu sehen", „Sehenswürdigkeiten in ". EN: „what can I do in ", „attractions in ". Nach search_place(<REGION>) mit der zurückgegebenen osmRel-ID aufrufen. When NOT to use: Vicinity-zu-Punkt (Radius um Koordinaten) → nearby; Detail-Info zu EINEM bereits gefundenen POI → get_poi_details; Place- Auflösung Name→ID → search_place. Required args: osm_id (i64 — die osmRel-ID der Stadt/Region aus einem search_place/places-Treffer, z.B. 1187768 für Wangerland; als Relation gelesen — ein Ort ohne osmRel hat keine Fläche: search_tourism oder nearby). Optional: limit (Default 8, clamped 1..=20), types (Stichwörter gegen die Werte der OSM-Tags tourism, historic, leisure, natural, sport und amenity, Teilstring, case-insensitive, z.B. ["museum"], ["castle"]; leer = alle Aktivitäts-/Tourismus-Klassen), include_address (bool, Default true — die Postadresse aus den addr:*-Tags), family_only (bool, Default false — nur family-taugliche POIs, je mit den tag-belegten Feldern family/indoor/family_categories) und, nur zusammen damit, indoor_only (bool — davon nur die Indoor-/Schlechtwetter-tauglichen). Unterkünfte ausgeschlossen: dieses Tool ist der Aktivitäts-/„unternehmen"- Pfad — Unterkünfte (tourism=hotel/hostel/guest_house/motel/apartment/… ) werden backend-seitig AUSGESCHLOSSEN; auch ein Hotel-types-Filter liefert hier nichts. Für Hotels/Pensionen → search_tourism(type=accommodation) (kuratierte Unterkünfte). Typical chain: search_place(<REGION>) → THIS_TOOL(osm_id=) → (optional get_poi_details(osm_id) pro Treffer für tiefere Details). Multi-call: ein Call pro Region/Typ-Filter; Bursting nicht nötig (das Tool fan-out't intern über alle containedInPlace-Entities). Anti-Fab note: POI-Name, type, Beschreibung, Adresse kommen AUSSCHLIESSLICH aus pois[] dieses Aufrufs. returned: 0 / pois: [] heißt: für dieses Gebiet ist nichts abrufbar — so wiedergeben („Ich konnte für aktuell keine Attraktionen abrufen"). OSM-KG-Coverage: deutschlandweit; Tag-Dichte variiert je Region wie in OSM üblich. Returns {place_osm_id, total_contained, tourism_candidates, returned, pois:[{name, type, types, description?, address?, uri, coord?, opening_hours?, fee?, source:'osm'}], attribution?}. Die optionalen Felder je POI sind tag-belegt oder abwesend, nie geraten. attribution (additiv, top-level): die ODbL-Namensnennung der gelieferten OSM-Daten (ODbL) — {id:'ODbL-1.0', notice:'© OpenStreetMap contributors', url:'https://www.openstreetmap.org/copyright'}. EINMAL pro Antwort (nicht pro POI) und nur wenn pois nicht leer ist. Nennst du diese POIs, nenne „OpenStreetMap" als Quelle. „Kinderfreundlich" ist ein Daten-Fakt (Kategorie/Tag-belegt), kein Modell-Raten.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "osm_id": "<osm_id>"
    },
    "name": "expand_kg_pois"
  }
}

Input Schema

NameRequiredDescriptionDefault
limitNoMaximum number of enriched tourism entities to return (default 8, clamped to 1..=20).
typesNoOptional type keywords to narrow the result, e.g. ["museum"], ["castle"] or ["viewpoint"]. A POI's types are the values of its OpenStreetMap category tags (`tourism`, `historic`, `leisure`, `natural`, `sport`, `amenity`); a POI is kept when one of them contains a keyword, case-insensitively. When omitted, no POI is left out by its type. Accommodation (`tourism`=hotel/hostel/guest_house/…) is never returned, whatever the filter.
osm_idYesOpenStreetMap relation ID of the city/region (e.g. 1187768 for Wangerland): the osmRel id of a `places` result. A place without one has no area to expand here.
family_onlyNoFamily mode: query the OSM family allowlist (playground/zoo/aquarium/beach/water_park/…) and keep/rank only family-suitable POIs, each carrying the derived `family`/`indoor`/ `family_categories` fields. Defaults to false (the full region expansion).
indoor_onlyNoRestrict the family result to indoor (rain-safe) POIs (aquarium/indoor_play). Only meaningful with `family_only=true`.
include_addressNoWhether to add each entity's postal address, formatted from its own `addr:*` tags (absent where it has none). Defaults to true.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • changedInput schema / properties / osm_id / description
      Previous value: -"OpenStreetMap relation/node ID of the city/region (e.g. 1187768 for Wangerland).\nUse the osmRel id from a `places` result (preferred) or osmNode as fallback."New value: +"OpenStreetMap relation ID of the city/region (e.g. 1187768 for Wangerland):\nthe osmRel id of a `places` result. A place without one has no area to\nexpand here."
  2. Changed2 schema fields changed
    • changedInput schema / properties / include_address / description
      Previous value: -"Whether to also resolve each entity's structured postal address\n(locality, region, postal code) with an extra lookup. Defaults to true."New value: +"Whether to add each entity's postal address, formatted from its own\n`addr:*` tags (absent where it has none). Defaults to true."
    • changedInput schema / properties / types / description
      Previous value: -"Optional schema.org type keywords to narrow the result, e.g.\n[\"TouristAttraction\"], [\"Hotel\"], or [\"Event\"]. Matched case-insensitively\nas substrings against each entity's schema.org rdf:type. When omitted, all\ntourism-relevant entities (attractions, hotels, events, gastronomy) are returned."New value: +"Optional type keywords to narrow the result, e.g. [\"museum\"], [\"castle\"] or\n[\"viewpoint\"]. A POI's types are the values of its OpenStreetMap category\ntags (`tourism`, `historic`, `leisure`, `natural`, `sport`, `amenity`); a POI\nis kept when one of them contains a keyword, case-insensitively. When omitted,\nno POI is left out by its type.\nAccommodation (`tourism`=hotel/hostel/guest_house/…) is never returned,\nwhatever the filter."
  3. First observed

TDQS

A4.5/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Beyond the readOnly/openWorld annotations it discloses non-obvious behavior: accommodation POIs are excluded backend-side regardless of filter, `limit` is clamped to 1..=20, a place without an osmRel has no area, empty results carry a prescribed message, and ODbL attribution must be surfaced once per response. It also states optional fields are tag-derived or absent, never guessed.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness3/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Purpose and exclusions are front-loaded, but the text is heavily bloated: bolded pseudo-headers, duplicate bilingual example utterances, and the accommodation exclusion repeated in both the prose and the `types` parameter section. The return-shape and attribution paragraphs are justified by the absence of an output schema, but the routing and example material could be half the length.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given six parameters, no output schema, and a multi-step chain, the definition covers everything an agent needs: the required argument's provenance, the full return envelope, the empty-result case, multi-call guidance, and the attribution obligation. Nothing material is left to inference.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100% and the schema already documents the substring matching, the category tags consulted, and the family_only/indoor_only dependency, so the description mostly restates structured data. It does add the useful caveat that a hotel keyword in `types` yields nothing, but otherwise adds little meaning beyond the schema.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The opening sentence names a specific verb and resource (expanding a city/region OSM ID to the tourism POIs contained in it) and then explicitly separates it from `nearby` (radius around a point), `search_place` (place disambiguation) and `resolve_location` (transit stops). An agent can distinguish it from every relevant sibling without opening a schema.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Provides concrete when-to-use triggers in both German and English ("was kann ich in <REGION> unternehmen", "attractions in <REGION>") and an explicit When-NOT section routing vicinity queries to `nearby`, single-POI details to `get_poi_details`, and name-to-ID resolution to `search_place`. It also states the prerequisite that `osm_id` must come from a prior `search_place` result.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources