This repository was archived by the owner on Oct 23, 2026. It is now read-only.
Repository navigation
Slice 2: coverage window follows the rider on a triangle-only floor contract (#77) - #84
Merged
Merged
Conversation
Prefactor for the moving coverage window. connection.rs now has one entry point, Surface::install: install these triangles for this rider, or refuse with a reason. Mount and replace in the in-process backend, the worker parent and the worker child all call it; the refresh_basis -> query_matches_pose -> observation -> finish_at -> contains_pose -> triangles -> build -> install chain is gone from callers. The flat path is deleted end to end: Surface::new, points, contains, the flat observation/triangle branches and is_geometry in Rust; the COMBINE_SKATE_VERTEX/MOUNT/TICK natives in plugin.cpp and prepare_definitions.py; Request.points and the layer == 0 rules in the wire (version 4, 96-byte request). Thresholds are defined once in connection.rs: floor agreement (0.3 m), query agreement and same floor (0.001 m), pose height (3 m), 4096 triangles, minimum area and coordinate bounds. The wire takes its triangle limit from there. Floor agreement now applies only while Skate reports ground contact (any physical state but the air states); the worker reports it in the response's spare word and the adapters expose it as value 4. Each installed floor carries a revision (mount 1, +1 per replacement). The 1000 m bound now limits one upload's reach from the rider. The Skate frame stays at the mount origin, since Session cannot move the skater without resetting its bodies, bounded at 8192 m where f32 still resolves a millimetre; a 1500 m ride is tested to round-trip within 1 mm. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Riding continues past the first window. combine_skate.js centres every window on a fixed 2 m world-cell lattice; crossing out of the centre cell resamples through the Coverage window module (sampleWindow, shared with mount) and installs through SURFACE_REPLACE as a new revision, logged as coverage-installed:N, with no remount. Neighbouring windows share lattice samples, so a swap leaves the floor under the rider unchanged. Floor agreement is checked only while Skate reports ground contact (VALUE(4) is not 0); an airborne frame is not refused. A coverage gap reached mid-ride (wall-height step, unloaded or missing ground) dismounts with "coverage gap (...)" through the existing restore path. "Window edge" is no longer a reason; leaving coverage is "outside supplied floor coverage". The JS floor rules live in one FLOOR constant set; the Rust contract defines each again and decides. Tests: sampled slope crossing cells 51 and 52 installs revisions 2 and 3 on the lattice without dismounting; a wall and unloaded ground 5 m ahead dismount with their gap reasons and restore GTA; an airborne skater over a planter keeps riding; neighbouring lattice windows agree everywhere they overlap on curved ground. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Review follow-up. native-surface.cpp injected a 0.06 m ground disagreement and expected refusal; floor agreement is 0.3 m, so the Windows harness would have failed. It now injects 0.31 m, and the README matches. The coverage window names its wall threshold again (equal to FLOOR.agreement, ADR 0004), and Response::read decodes ground contact once. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
6 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Wire format v4. The flat-patch path and its natives are removed. The native fault check now injects a 0.31 m mismatch, so it is above the 0.3 m threshold.
Evidence
main(Slice 1: Mount on a sampled slope through a Coverage window module #76) installs one window at mount and never moves it.python3 scripts/verify.pypasses: JS, Rust and C++ suites (coverage-window.cjs,tests/connection.rs,tests/wire.rs,native-surface.cpp), ending "PASS: repository gate".proposed.Merge Danger
Door: two-way
Reverting restores the v3 wire format and the flat-patch path.
Blast Radius: adapter
Worker and plugin must be rebuilt together, because the wire version changed.
Closes #77
🤖 Generated with Claude Code