{
  "article_slug": "smooth-grid-paths-in-godot",
  "artifact": "Godot line-of-sight smoothing and Basic Theta* correctness proof",
  "checks": [
    {
      "details": {
        "open_cells": 109,
        "pairs": 5995,
        "solid_cells": 12
      },
      "id": "integer_line_of_sight_is_symmetric",
      "passed": true
    },
    {
      "details": {
        "permissive_one_side": {
          "cells": [
            {
              "x": 0,
              "y": 0
            },
            {
              "x": 1,
              "y": 0
            },
            {
              "x": 0,
              "y": 1
            },
            {
              "x": 1,
              "y": 1
            }
          ],
          "clear": true,
          "code": "OK",
          "topology_revision": 1
        },
        "permissive_two_sides": {
          "cells": [
            {
              "x": 0,
              "y": 0
            },
            {
              "x": 1,
              "y": 0
            },
            {
              "x": 0,
              "y": 1
            }
          ],
          "clear": false,
          "code": "CLOSED_CORNER_GAP",
          "topology_revision": 2
        },
        "strict_one_side": {
          "cells": [
            {
              "x": 0,
              "y": 0
            },
            {
              "x": 1,
              "y": 0
            },
            {
              "x": 0,
              "y": 1
            }
          ],
          "clear": false,
          "code": "STRICT_CORNER_BLOCKED",
          "topology_revision": 1
        }
      },
      "id": "corner_contact_policy_is_explicit_and_tested",
      "passed": true
    },
    {
      "details": {
        "after_revision": 2,
        "before_revision": 1,
        "blocked_code": "BLOCKED_CELL",
        "stats": {
          "cache_entries": 1,
          "cache_hits": 1,
          "queries": 3,
          "topology_revision": 2,
          "traces": 2
        }
      },
      "id": "topology_revision_invalidates_line_of_sight_cache",
      "passed": true
    },
    {
      "details": {
        "boundary": {
          "cache_hit": false,
          "checked_offsets": 0,
          "clear": false,
          "code": "START_NOT_OPEN",
          "profile": "square_2x2",
          "topology_revision": 1
        },
        "point": {
          "cache_hit": false,
          "checked_offsets": 1,
          "clear": true,
          "code": "OK",
          "profile": "point",
          "topology_revision": 1
        },
        "square_2x2": {
          "cache_hit": false,
          "checked_offsets": 3,
          "clear": false,
          "code": "BLOCKED_CELL",
          "profile": "square_2x2",
          "topology_revision": 1
        }
      },
      "id": "translated_footprint_profile_changes_visibility",
      "passed": true
    },
    {
      "details": {
        "input": [
          {
            "x": 0,
            "y": 1
          },
          {
            "x": 1,
            "y": 1
          },
          {
            "x": 2,
            "y": 2
          },
          {
            "x": 3,
            "y": 2
          },
          {
            "x": 4,
            "y": 3
          },
          {
            "x": 5,
            "y": 3
          },
          {
            "x": 6,
            "y": 4
          }
        ],
        "input_cost": 7.24264061450958,
        "line_of_sight_calls": 1,
        "output": [
          {
            "x": 0,
            "y": 1
          },
          {
            "x": 6,
            "y": 4
          }
        ],
        "output_cost": 6.70820379257202
      },
      "id": "backward_farthest_visible_smoothing_removes_redundant_bends",
      "passed": true
    },
    {
      "details": {
        "code": "MOVEMENT_VISIBILITY_MISMATCH",
        "cost": 0.0,
        "input_waypoints": 2,
        "line_of_sight_calls": 1,
        "ok": false,
        "output_waypoints": 1,
        "path": [
          {
            "x": 0,
            "y": 0
          }
        ],
        "topology_revision": 1
      },
      "id": "smoothing_reports_movement_visibility_policy_mismatch",
      "passed": true
    },
    {
      "details": {
        "blocked": {
          "code": "UNREACHABLE",
          "cost": -1.0,
          "expanded_nodes": 40,
          "line_of_sight_calls": 238,
          "ok": false,
          "path": [],
          "topology_revision": 1,
          "waypoints": 0
        },
        "open": {
          "code": "OK",
          "cost": 10.2956304550171,
          "expanded_nodes": 9,
          "line_of_sight_calls": 120,
          "ok": true,
          "path": [
            {
              "x": 1,
              "y": 1
            },
            {
              "x": 10,
              "y": 6
            }
          ],
          "topology_revision": 1,
          "waypoints": 2
        }
      },
      "id": "basic_theta_star_handles_open_and_disconnected_grids",
      "passed": true
    },
    {
      "details": {
        "cases": 80,
        "reachable": 59,
        "returned_segments": 594,
        "unreachable": 21
      },
      "id": "generated_theta_queries_match_reachability_and_return_legal_segments",
      "passed": true
    },
    {
      "details": {
        "path": [
          {
            "x": 1,
            "y": 0
          },
          {
            "x": 4,
            "y": 4
          },
          {
            "x": 17,
            "y": 8
          }
        ],
        "runs": 21
      },
      "id": "theta_equal_cost_ties_are_deterministic",
      "passed": true
    },
    {
      "details": {
        "astar_cost": 19.3137083053589,
        "astar_path": [
          {
            "x": 1,
            "y": 0
          },
          {
            "x": 2,
            "y": 0
          },
          {
            "x": 3,
            "y": 0
          },
          {
            "x": 4,
            "y": 0
          },
          {
            "x": 5,
            "y": 0
          },
          {
            "x": 6,
            "y": 0
          },
          {
            "x": 7,
            "y": 0
          },
          {
            "x": 8,
            "y": 1
          },
          {
            "x": 9,
            "y": 2
          },
          {
            "x": 10,
            "y": 3
          },
          {
            "x": 11,
            "y": 4
          },
          {
            "x": 12,
            "y": 5
          },
          {
            "x": 13,
            "y": 6
          },
          {
            "x": 14,
            "y": 7
          },
          {
            "x": 15,
            "y": 8
          },
          {
            "x": 16,
            "y": 8
          },
          {
            "x": 17,
            "y": 8
          }
        ],
        "astar_route_side": "top",
        "smoothed_cost": 18.806248664856,
        "smoothed_path": [
          {
            "x": 1,
            "y": 0
          },
          {
            "x": 7,
            "y": 0
          },
          {
            "x": 17,
            "y": 8
          }
        ],
        "smoothed_route_side": "top",
        "theta_cost": 18.6014709472656,
        "theta_path": [
          {
            "x": 1,
            "y": 0
          },
          {
            "x": 4,
            "y": 4
          },
          {
            "x": 17,
            "y": 8
          }
        ],
        "theta_route_side": "bottom"
      },
      "id": "authored_grid_exposes_the_smoothing_escalation_point",
      "passed": true
    },
    {
      "details": {
        "bad_goal": "GOAL_NOT_OPEN",
        "bad_profile": "UNKNOWN_PROFILE",
        "bad_start": "START_NOT_OPEN"
      },
      "id": "invalid_endpoints_and_profiles_return_named_failures",
      "passed": true
    },
    {
      "id": "extracted_package_reruns_cleanly",
      "passed": true,
      "details": {
        "extracted_logic_check_count": 11,
        "check_ids_match_workspace": true,
        "scene_smoke_passed": true,
        "route_family_changed": true,
        "engine": "4.7.2-stable (official)"
      }
    }
  ],
  "engine": {
    "build": "official",
    "hash": "ed1daf0bf001b61586d9930840f2f1394092c079",
    "hex": 263938,
    "major": 4,
    "minor": 7,
    "patch": 2,
    "status": "stable",
    "string": "4.7.2-stable (official)",
    "timestamp": 0
  },
  "failed": [],
  "failed_count": 0,
  "measurement_scope": "Correctness proof only. No benchmark or product API claim.",
  "passed": true,
  "passed_count": 12,
  "proof_boundary": {
    "costs": "binary occupancy and uniform Euclidean segment cost only",
    "footprints": "square_2x2 is a translated occupied-cell profile, not a continuous disk or arbitrary polygon sweep",
    "optimality": "the verifier checks legality and reachability, not global any-angle optimality",
    "performance": "no timing, memory, throughput, or comparative speed claim",
    "verified_here": "symmetric integer LOS traversal, strict corner behavior, profile offsets, cache revision invalidation, backward farthest-visible smoothing, Basic Theta* reachability, segment legality, deterministic ties, and the shared-grid demo"
  },
  "query_contract": {
    "corner_policy": "strict: an exact diagonal corner crossing requires both side cells open",
    "grid": "square occupancy grid with paths between cell centers",
    "neighbors": "eight adjacent cells",
    "profiles": "point and top-left-anchored square_2x2 translated offset sets",
    "segment_cost": "Euclidean distance in cell coordinates",
    "topology": "every query and smoothing/search result records one occupancy revision"
  },
  "scene_smoke": {
    "details": {
      "astar_cost": 19.3137083053589,
      "astar_path": [
        {
          "x": 1,
          "y": 0
        },
        {
          "x": 2,
          "y": 0
        },
        {
          "x": 3,
          "y": 0
        },
        {
          "x": 4,
          "y": 0
        },
        {
          "x": 5,
          "y": 0
        },
        {
          "x": 6,
          "y": 0
        },
        {
          "x": 7,
          "y": 0
        },
        {
          "x": 8,
          "y": 1
        },
        {
          "x": 9,
          "y": 2
        },
        {
          "x": 10,
          "y": 3
        },
        {
          "x": 11,
          "y": 4
        },
        {
          "x": 12,
          "y": 5
        },
        {
          "x": 13,
          "y": 6
        },
        {
          "x": 14,
          "y": 7
        },
        {
          "x": 15,
          "y": 8
        },
        {
          "x": 16,
          "y": 8
        },
        {
          "x": 17,
          "y": 8
        }
      ],
      "astar_route_side": "top",
      "goal": {
        "x": 17,
        "y": 8
      },
      "ready": true,
      "region": {
        "position": {
          "x": 0,
          "y": 0
        },
        "size": {
          "x": 19,
          "y": 15
        }
      },
      "route_family_changed": true,
      "same_occupancy_grid": true,
      "smoothed_cost": 18.806248664856,
      "smoothed_path": [
        {
          "x": 1,
          "y": 0
        },
        {
          "x": 7,
          "y": 0
        },
        {
          "x": 17,
          "y": 8
        }
      ],
      "smoothed_route_side": "top",
      "smoothed_visible": true,
      "smoothing_ok": true,
      "solid_count": 6,
      "start": {
        "x": 1,
        "y": 0
      },
      "theta_cost": 18.6014709472656,
      "theta_ok": true,
      "theta_path": [
        {
          "x": 1,
          "y": 0
        },
        {
          "x": 4,
          "y": 4
        },
        {
          "x": 17,
          "y": 8
        }
      ],
      "theta_route_side": "bottom",
      "theta_visible": true,
      "topology_revision": 1
    },
    "passed": true
  },
  "verified_at": "2026-08-21 19:37:49",
  "published_files": {
    "source_zip": {
      "path": "/downloads/pathforge/smooth-grid-paths-in-godot-source.zip",
      "bytes": 15066,
      "sha256": "a34d12cbdf666492fa4d31f76268f14cd54bf32bcfbf1f7b82102ab8b7bcc80f"
    },
    "proof_image": {
      "path": "/images/blog/smooth-grid-paths-in-godot-proof.png",
      "bytes": 53493,
      "sha256": "0bad03861c6410e8de58456ac95154f5ee4b5f7b30f8294e5983741596b6271c"
    },
    "proof_sources": {
      "scripts/articles/grid_line_of_sight.gd": "9534b755ea15a82a4dbdb6646eaa269aa49fd87753aaac624c235c3a9b4fbe37",
      "scripts/articles/grid_path_smoothing.gd": "c70e0ee7a113c78ea99f35130db7d99921943b740b56e4d56cf250f0ce138af0",
      "scripts/articles/theta_star_grid.gd": "f50b67a7171e127eb7762fb9c415220ba3d87445337344ec7b1acf026aa4e592",
      "scenes/articles/theta_star_any_angle_demo.tscn": "8a491f12c2c6c8674aa7edc1ef2cf408d426e8de9aeb644bf81df141b5dee55a",
      "tools/verify_theta_star_any_angle.gd": "ec176800709e50b776b4f9b6e4f7805cb36514c0267edba58b78b2e510547e4d"
    }
  },
  "extracted_package_rerun": {
    "passed": true,
    "logic_check_count": 11,
    "published_check_count": 12,
    "check_ids_match_workspace": true,
    "scene_smoke_passed": true,
    "route_family_changed": true,
    "engine": "4.7.2-stable (official)"
  }
}
