)]}'
{
  "commit": "a165bea4ce830e28b64643ed037e20f61e639cfe",
  "tree": "41c426520365175857b9fd56ceb164eb8ff65a18",
  "parents": [
    "68fbe5d648f58b7f1ef3895cbb7a15e87d3097e4"
  ],
  "author": {
    "name": "Jia Yu",
    "email": "jiayu@apache.org",
    "time": "Sun Jul 26 22:19:06 2026 -0700"
  },
  "committer": {
    "name": "GitHub",
    "email": "noreply@github.com",
    "time": "Sun Jul 26 22:19:06 2026 -0700"
  },
  "message": "Add geography variants of the SpatialBench queries (#131)\n\nAll 12 SpatialBench queries are geometry: WKB columns are decoded with\nST_GeomFromWKB, predicates use planar edges, and thresholds are angles in\ndegrees converted by hand (0.45 \"\u003d 50 km\", / 0.000009 \"\u003d 1 m\"). Those factors\nonly hold near the equator along longitude, so a degree-based radius is a\ndifferent real-world shape in every part of a dataset that spans latitudes\n-56 to 78 degrees. Areas come out in square degrees.\n\nGeography types interpret edges as geodesics and return metric units, so add the\ngeography counterpart of the suite:\n\n- notebooks/geography-queries.ipynb defines all 12 queries, each with its\n  real-life scenario, the spatial characteristics it exercises, and its SQL.\n  Structured to mirror notebooks/queries.ipynb.\n- docs/geography-queries.md is generated from that notebook with nbconvert, the\n  same way docs/queries.md is; docs/geography-queries.zh.md mirrors it.\n- spatialbench-queries/print_geography_queries.py carries 11 of the queries for\n  use outside the notebook. Q12 is defined but neither carried in the module nor\n  executed in the notebook: it is a K-nearest-neighbour join and ST_KNN has no\n  geography form yet.\n\nThresholds are metres, areas are square metres, and Q7 drops the degree\nconversion factor entirely. Output column names, ORDER BY clauses, LIMITs and\ntiebreakers are unchanged from the geometry suite.\n\nThe geography base class deliberately does not subclass SpatialBenchBenchmark,\nwhich would silently reintroduce the geometry q12; it borrows only the\nquery-collection reflection. As in the geometry suite, Q5 is the one query with a\nSedonaDB-specific spelling (ST_Collect_Agg vs ST_Collect(ARRAY_AGG(...))).\n\nVerified by executing the suite at SF0.1 and SF1: Q2 matches the committed\ngeometry answer exactly (541), Q3 matches its row count (22), Q4 reproduces the\ngeometry answer row for row (258 zones, same counts, same order), and Q9\u0027s\nself-join finds the same 37 building pairs. Q1, Q5, Q7 and Q8 return full result\nsets with ST_Length and ST_Area in metres and square metres.\n\nThe benchmark harness, CI matrix and ground-truth answers are untouched: the two\nsuites need separate answer sets, since a 0.45 degree planar radius and a 50 000 m\ngeodesic radius select different rows by construction.\n\nThe mkdocs nav labels the two pages \"SpatialBench Queries (Geometry)\" and\n\"SpatialBench Queries (Geography)\" so the pair reads as one set. This renames\nthe existing geometry entry, which was \"Queries\" in the main nav and\n\"SpatialBench Queries\" in the framework block, and updates the zh translations\nto match.\n\nNotebook cells carry ids, as nbformat 4.5 requires and as notebooks/queries.ipynb\nalready does; without them nbconvert emits MissingIDFieldWarning and warns that\nit will become an error. The link to the geometry suite uses the published URL\nrather than a relative queries.md, which resolves to a nonexistent\nnotebooks/queries.md when read from the notebook; the zh page points at the zh\nbuild of that page.",
  "tree_diff": [
    {
      "type": "add",
      "old_id": "0000000000000000000000000000000000000000",
      "old_mode": 0,
      "old_path": "/dev/null",
      "new_id": "d4f9e288c370633e27d9b2e85d392b750110878b",
      "new_mode": 33188,
      "new_path": "docs/geography-queries.md"
    },
    {
      "type": "add",
      "old_id": "0000000000000000000000000000000000000000",
      "old_mode": 0,
      "old_path": "/dev/null",
      "new_id": "1def70121c4076d66957e5ce05b4c81522a1fac9",
      "new_mode": 33188,
      "new_path": "docs/geography-queries.zh.md"
    },
    {
      "type": "modify",
      "old_id": "37797fc453e92cb1f9642d417627dd7e52f12326",
      "old_mode": 33188,
      "old_path": "mkdocs.yml",
      "new_id": "95798c5d3e20a7127adfecce39c1a0155d953162",
      "new_mode": 33188,
      "new_path": "mkdocs.yml"
    },
    {
      "type": "add",
      "old_id": "0000000000000000000000000000000000000000",
      "old_mode": 0,
      "old_path": "/dev/null",
      "new_id": "2929c2136d968eec188cfaf50417a93cdf8cdfad",
      "new_mode": 33188,
      "new_path": "notebooks/geography-queries.ipynb"
    },
    {
      "type": "add",
      "old_id": "0000000000000000000000000000000000000000",
      "old_mode": 0,
      "old_path": "/dev/null",
      "new_id": "7ffc599249612aa834bc158966fb4a6c1990f6f7",
      "new_mode": 33261,
      "new_path": "spatialbench-queries/print_geography_queries.py"
    }
  ]
}
