Skip to main content
Glama

Resolve a Nigerian address to a postcode

resolve_address
Read-onlyIdempotent

Convert a described Nigerian address into a NIPOST postcode, returning only the precision supported by the address text, pin, or landmarks.

Instructions

Turn a described Nigerian address into a postcode, only as precisely as the evidence allows.

A full building code comes only from a postcode written in the address, a location pin, or a landmark that is the address itself. Otherwise the result is an area or district prefix with a question for the user. Read the address yourself and fill landmarks and geocode_queries; the address text is sent to the configured geocoder.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
addressYesThe address exactly as the user gave it.
latitudeNoLatitude of a location pin the user shared.
landmarksNoLandmarks named in the address, each with how the address relates to it. Use 'at' only when the address is the landmark itself.
longitudeNoLongitude of that pin. Give it with latitude.
geocode_queriesNoUp to three map search strings you derive from the address: named places and streets with the town and state, most specific first, without directional words like 'back of'.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
codeYesA full postcode at building level, else a prefix.
levelYes
methodYes
statusYes
evidenceYes
questionYesWhat to ask the user to get a better answer.
confidenceYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed2 schema fields changedv0.4.1
    • changedInput schema / properties / latitude / description
      Previous value: -"A location pin the user shared."New value: +"Latitude of a location pin the user shared."
    • addedInput schema / properties / longitude / description
      Added value: +"Longitude of that pin. Give it with latitude."
  2. First observedv0.2.4

TDQS

A3.8/5.0
Behavior4/5

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

Annotations already cover readOnly/openWorld/idempotent, and the description adds real behavioral value beyond them: the tiered precision model, the fact that the address text is forwarded to an external geocoder, and the fallback that returns a `question` to the user rather than a false-precise code. It does not add rate limits or auth context, but for a read-only resolver this is solid disclosure.

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

Conciseness4/5

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

Purpose is front-loaded, followed by the precision rule and the parameter-filling instruction. The opening clause ('only as precisely as the evidence allows') is slightly awkward but the whole thing is four tight sentences with little waste.

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

Completeness4/5

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

An output schema exists, so return-shape explanation is unnecessary; the description still flags the `question` fallback, which is the key non-obvious output behavior. Combined with the precision tiers and param guidance, an agent has what it needs, with the main omission being sibling routing.

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

Parameters4/5

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

Schema coverage is 100%, so the baseline is 3, but the description meaningfully clarifies that `landmarks` and `geocode_queries` are agent-derived from reading the address rather than passed verbatim, and echoes the 'at' = address-is-the-landmark rule. That goes beyond the structured field text.

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

Purpose4/5

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

States a specific verb + resource ('Turn a described Nigerian address into a postcode') with the unique twist that output precision varies with evidence. The distinction from siblings like lookup_postcode and validate_postcode is implied by 'described address' vs a written code, though no sibling is named explicitly.

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

Usage Guidelines3/5

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

It explains the outcome tiers (full building code vs area prefix with a `question`) and instructs the agent to derive `landmarks` and `geocode_queries`, but it never states when to choose this over the four siblings (lookup_postcode, autocomplete_postcode, validate_postcode, find_postcode_at_location). Usage is implied rather than routed.

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