Official Codebase of 3DCodeVerse
Python
articulated follow-up from #5, with the review fixes: one walker, docs that match this tree
Claudeca67728fc1a0
diff --git a/harness/bench/penetration_thresholds.py b/harness/bench/penetration_thresholds.pyindex ec2e32ee..62d6eb37 100644--- a/harness/bench/penetration_thresholds.py+++ b/harness/bench/penetration_thresholds.py@@ -26,6 +26,7 @@ from pathlib import Pathsys.path.insert(0, str(Path(__file__).resolve().parent.parent))+from codeverse.flywheel.record import unique_files # noqa: E402from codeverse.languages.urdf import REST_PENETRATION_MAX_M # noqa: E402from codeverse.spatial.connectivity import ( # noqa: E402PENETRATION_ERROR_M,@@ -45,24 +46,17 @@ SWEEP_REST_ERROR_M = float(inspect.signature(sweep_findings).parameters["rest_maassert SWEEP_REST_ERROR_M == REST_PENETRATION_MAX_M, "the urdf runtime disagrees with the sweep default"-#: sub-workspaces a run owns; their records are not runs of their own (`find_runs` skips-#: both, and `scene_stats.runs` did while this file skipped only `_cand`)-SUB_WORKSPACES = ("_cand", "_assets")def records(root: Path) -> list[dict]:"""Every articulated run record under ``root``, once per run.- `resolve()` before the dedupe so a symlinked cell (`run/telemetry/trajectories` is the- documented one) is counted once, not twice — the trap that inflated COST §30. The- review branch adds `flywheel.record.unique_files` for exactly this; both bench walkers- should move to it when that lands.+ The walk is ``flywheel.record.unique_files``: it follows symlinked cells and the+ ``run/telemetry/trajectories`` link and counts each file once, and skips the+ sub-workspaces a run owns — the trap that inflated COST §30, handled in one place."""- out, seen = [], set()- for rec in root.rglob("record.json"):- if rec.resolve() in seen or any(w in rec.parts for w in SUB_WORKSPACES):- continue- seen.add(rec.resolve())+ out = []+ for rec in unique_files(root, "record.json"):try:data = json.loads(rec.read_text())except (OSError, ValueError):diff --git a/harness/docs/PAPER_WRITING.md b/harness/docs/PAPER_WRITING.mdindex 3897a436..3ce6b8ba 100644--- a/harness/docs/PAPER_WRITING.md+++ b/harness/docs/PAPER_WRITING.md@@ -360,21 +360,21 @@ articulation sheet posed every follower at rest, so that complaint is evidence asheet, not about the generation. The sweep poses through fk, which does resolve followers,so the sweep-side evidence stands on its own.-**What did NOT move: the sweep gate's own failure rate.** On those eight prompts the-`joint_sweep` gate fails 30 % of the rounds with couplings declared (11 of 37,-`wave2_lean`) against 31 % without them (12 of 39, `aa_articulated`; `ab_fewer_turns` 19 %-of 37, `compare_art_v4_pf0` 25 % of 8 — the spread across pre-mimic batteries is wider than-the before/after difference). The sampler drives fewer joints and every pose it drives is-reachable, but the gate still finds links overlapping in them. The comparison is also-confounded at the source: a pre-mimic URDF declares no couplings at all, so the two arms-are not the same artefacts measured twice. What can be said is the mechanical claim (which-poses are sampled); the claim that the gate's findings became *truer* is not measured, and-this readout does not support it. The mechanisms the-support was built for — umbrella, step ladder, folding workbench — are the ones that collapse-to 1–2. The pre-mimic batteries (`aa_articulated`, `compare_art_v4_pf0`) contain **zero**-couplings, so nothing else on the battery changed shape. The score effect on the three coupled prompts is inside the noise band-at n = 2 per side (umbrella 0.35/0.65 → 0.54/0.64, scissor 0.46/0.54 → 0.49/0.60, workbench-0.91/0.60 → 0.60/0.60); the **pose count is the readout that resolves.**+**What is NOT shown: that the sweep gate's failure rate moved.** Two comparisons, both+null and both too small to be equivalence claims. On `coupled_v1` the gate fails 5/10+rounds with the coupling declared against 4/10 without (Wilson 0.24–0.76 vs 0.17–0.69, a+hand count over the two arms' records). Across batteries, on the eight coupled prompts,+it fails 30 % of the rounds with couplings declared (11 of 37, `wave2_lean`) against 31 %+without (12 of 39, `aa_articulated`; `ab_fewer_turns` 19 % of 37, `compare_art_v4_pf0`+25 % of 8 — the spread across pre-mimic batteries is wider than the before/after+difference). Neither number is printed by a script: `coupling_stats.py --per-prompt`+reports the gate per battery, not per prompt subset, and the batteries are not in the+tree. The sampler drives fewer joints and every pose it drives is reachable, but the gate+still finds links overlapping in them — and the cross-battery comparison is confounded at+the source, since a pre-mimic URDF declares no couplings at all. What can be said is the+mechanical claim (which poses are sampled); "not detectably different at this n" is what+the gate data carries, and the claim that the gate's findings became *truer* is not+measured.### 5.4 Provider-failure accountingdiff --git a/harness/docs/RUNBOOK.md b/harness/docs/RUNBOOK.mdindex 07941c55..faf6e14e 100644--- a/harness/docs/RUNBOOK.md+++ b/harness/docs/RUNBOOK.md@@ -200,16 +200,16 @@ and measured 38 970 ms at load ~100 with `ok=True` — the build succeeded, thebusy. All three are the same story, and none of them is to be "fixed" by loosening whatit asserts.-**Two arms at once still want separate `CV3D_CACHE_DIR`, though the browser no longer-depends on it.** Until 2026-09-05 the daemon advertised its endpoint at-`CACHE_DIR/browser_<backend>.json`, a newer daemon superseded an older one, and two-worktrees sharing a cache ended up on ONE browser: the arm that did not launch it-rendered through a server rooted in the other tree, its GLB was outside that root, and-`render_glb` returned "produced no result" — on one side only, looking like random-flakiness (2026-09-04). The endpoint, its lock and its failure file now carry a digest of-the `runtime_js` that spawned the daemon, so two trees keep separate browsers inside one-cache dir and neither can retire the other's. Give each arm its own cache dir anyway: the-render cache separates with it, which an A/B wants.+**Two arms at once need separate `CV3D_CACHE_DIR`, not just separate `--out`.** The+browser daemon advertises its endpoint in `CACHE_DIR/browser_<backend>.json` and a newer+daemon supersedes an older one (`runtime_js/browser_daemon.cjs`), so two worktrees sharing+a cache fight over ONE browser, and `render_glb` returns "produced no result" on one side+only, looking like random flakiness (2026-09-04). The mechanism is not confirmed: each+render serves its GLB from its own process (`render_glb.mjs` `serveDirs`), so it is not a+server-root mismatch; the likely cause is the superseded daemon exiting while the other+arm's render is still in flight on its browser, which is a race in shared code that a+separate cache dir avoids rather than fixes. Give each arm its own cache dir; the render+cache separates with it, which an A/B wants anyway.Also halve each arm's `--parallel`: two arms at 3 workers is six concurrent renders, and around with no renders skips the judge, so the loop stops at `judge_unavailable` and the