# texspace — Local Sub-2ms Spatial Geocoding & Search Engine > Pure-Rust S2 + SQLite spatial location engine implementing TEXSPACE (ACMGIS '07). > Active mode: partitioned | Shards: ["ae_gulf", "af_east", "af_north", "af_west", "ar_uy_cl", "asia_central", "asia_pk_ir", "at_at", "au_nsw", "au_qld", "au_vic", "au_west", "be_lu", "br_other", "br_se", "ca_bc", "ca_east", "ca_on", "ca_qc", "ca_west", "ch_li", "cn_east", "cn_north", "cn_south", "cn_west", "co_pe_ec", "cz_sk_hu", "de_be", "de_bw", "de_by", "de_central", "de_north", "de_nw", "dk_fi_is", "es_pt", "eu_balkans", "eu_baltics", "eu_east", "fr_east", "fr_idf", "fr_north", "fr_south", "fr_west", "gb_eng_n", "gb_eng_w", "gb_lon", "gb_nir", "gb_sct", "ie_ie", "il_levant", "in_east", "in_north", "in_south", "it_it", "jp_chubu", "jp_kansai", "jp_kanto", "jp_north", "jp_west", "kr_kr", "latam_central", "mx_mx", "nl_nl", "nz_nz", "oceania_other", "pl_pl", "ru_east", "ru_west", "se_no", "sea_id_ph", "sea_th_vn", "sg_my", "tr_gr_cy", "tw_hk_mo", "us_ak", "us_al", "us_ar", "us_az", "us_ca", "us_co", "us_ct", "us_dc", "us_de", "us_fl", "us_ga", "us_hi", "us_ia", "us_id", "us_il", "us_in", "us_ks", "us_ky", "us_la", "us_ma", "us_md", "us_me", "us_mi", "us_mn", "us_mo", "us_ms", "us_mt", "us_nc", "us_nd", "us_ne", "us_nh", "us_nj", "us_nm", "us_nv", "us_ny", "us_oh", "us_ok", "us_or", "us_pa", "us_pr", "us_ri", "us_sc", "us_sd", "us_tn", "us_tx", "us_ut", "us_va", "us_vt", "us_wa", "us_wi", "us_wv", "us_wy", "za_south_af"] | Entities: 73294294 | Parcels: 156026 | Overlays: 0 ## Agent Quick Start - Prefer `?format=compact` on all endpoints to cut JSON token overhead by ~70%. - Inspect `match_level`, `confidence`, `unmatched_tokens`, and `conflicting_tokens` before trusting a coordinate. - Machine-readable OpenAPI 3.1 schema: `GET /openapi.json` - Live index inventory & bounding boxes: `GET /v1/meta` - Native stdio MCP server for Claude / Cursor / Antigravity: `texspace mcp --db ` ## Endpoints - `GET /v1/search?text=&size=5&profile=balanced&format=compact` — Freeform geocoding (addresses, APNs/TMKs, intersections, POIs, typos, conflicting cities) - `GET|POST /v1/search/structured` — Field-level geocoding (`housenumber`, `street`, `unit`, `locality`, `region`, `postalcode`, `apn`, `address`) with `field_conflicts` - `GET /v1/reverse?point.lat=&point.lon=&format=compact` — 4-tier reverse geocoding (Parcel PIP -> Address -> POI/Street -> WOF hierarchy) - `GET /v1/autocomplete?text=&focus.point.lat=&focus.point.lon=&format=compact` — Sub-2ms incremental typeahead - `GET|POST /v1/nearby?q=hospitals+within+2km+of+SFO&format=compact` — Relational proximity & directional search (`within 2km of`, `near`, `200m north of`) - `POST /v1/batch` — Multi-threaded parallel bulk geocoding (up to 10,000 queries/request) ## Ranking Profiles (`profile=`) - `balanced` (default): calibrated GBDT ranker - `delivery`: strongly favors rooftop/parcel/building pins; penalizes broad city/ZIP fallbacks - `real_estate`: prioritizes parcel polygons and APNs/TMKs - `consumer`: boosts popular landmarks, campuses, venues, and localities - `emergency`: prioritizes exact intersections, addresses, and directional concordance ## Explicit `match_level` Semantics - Exact precision: `parcel_apn`, `parcel`, `rooftop`, `interpolated_building`, `interpolated`, `intersection`, `poi`, `street`, `neighbourhood`, `postalcode`, `locality`, `region` - Degraded fallback (check `unmatched_tokens` / `conflicting_tokens`): `fallback_postalcode`, `fallback_locality`, `fallback_region`