Skip to content

Packs / geospatial-public

point-in-polygon

assign each point to the GeoJSON zone polygon that contains it (delivery zones, districts)

L2 Checks passed 3 of 3 runsv1.0.0Tech-Realm/space-geospatial-public

Install

logicpacks pack use geospatial-public/point-in-polygon
get_pack geospatial-public/point-in-polygon

The second line is the MCP tool call for the LogicPacks connector (Claude Code, Codex, Claude.ai and others). The first run of a pack someone else wrote asks for your yes.

Keys it needs (names only)

None.

Playbooks included

  • Spec: spec/SPEC.md (goal, steps, edge cases, don’ts)
  • Routes: python-stdlibgdal-ogr
  • Checks: 1 in outcome/checks.yaml
  • Code: pip.py
  • Tools: python3

Usage, last 8 weeks

New: no recorded use yet.

Purpose (from spec/SPEC.md)

Goal

Assign each point to the GeoJSON zone polygon that contains it (delivery zones, districts).

Steps

  1. Draw or export zones as GeoJSON (geojson.io, QGIS).
  2. Run pip.py with your points.
  3. Review OUTSIDE points: gaps between zones or bad coordinates.

Edge cases

  • Holes (inner rings) are excluded, as the fixture shows.
  • Points exactly on a shared edge may land in either zone.

Don'ts

  • Don't swap GeoJSON [lon, lat] order.

Routes (free first)

  1. python-stdlib: code/pip.py (no install).
  2. gdal-ogr (free): GDAL/OGR for format conversion and reprojection at scale (brew install gdal)