Official Codebase of 3DCodeVerse
Python
planner: the geometry re-ask ships OFF (CV3D_PLAN_GEOMETRY=1 turns it on) — the A/B found no gain
ziyaof771a71ffb08
diff --git a/harness/codeverse/tracks/plan_features.py b/harness/codeverse/tracks/plan_features.pyindex d8919483..ba1067c0 100644--- a/harness/codeverse/tracks/plan_features.py+++ b/harness/codeverse/tracks/plan_features.py@@ -63,7 +63,7 @@ def pin_plan_blockers(variant_env: dict[str, str]) -> list[str]:LIVE_SWITCHES: dict[str, str] = {"CV3D_PLAN_BRIEF": "codeverse/tracks/planner.py", # brief.py merged in, 2026-08-28# plan-time geometry re-ask for articulated plans (tracks/plan_checks.py); plan-side,- # so an A/B over it can never --pin-plan+ # so an A/B over it can never --pin-plan. Off by default (A/B 2026-08-28: no gain)."CV3D_PLAN_GEOMETRY": "codeverse/tracks/planner.py","CV3D_SCOPED_PARTS": "codeverse/tracks/depth.py","CV3D_DETAIL_ROUNDS": "codeverse/tracks/lifecycle.py",diff --git a/harness/codeverse/tracks/planner.py b/harness/codeverse/tracks/planner.pyindex 446d646d..44d22f3c 100644--- a/harness/codeverse/tracks/planner.py+++ b/harness/codeverse/tracks/planner.py@@ -577,13 +577,16 @@ MAX_QUALITY_REASKS = 1#: a plan whose boxes / pivots / ranges contradict each other (tracks/plan_checks.py) is#: re-asked with the numbers; after this many it ships anyway and the joint sweep decidesMAX_GEOMETRY_REASKS = 2-#: ``CV3D_PLAN_GEOMETRY=0`` turns the geometry re-ask off (a control arm for an A/B;-#: registered in tracks/plan_features.LIVE_SWITCHES)+#: ``CV3D_PLAN_GEOMETRY=1`` turns the geometry re-ask ON (registered in+#: tracks/plan_features.LIVE_SWITCHES). OFF by default since the 2026-08-28 A/B+#: (compare_art_v4 pf vs pf0, n = 14): score Δ +0.064 [−0.188, +0.315], wins 6/6/2,+#: final gate errors 0.00 vs 0.25, round-0 sweep targets 0.54 vs 0.25 — no measurable+#: gain for 7/14 re-asks; the plan-loop rule (docs/PLAN_LOOP.md) keeps such a change off.PLAN_GEOMETRY_ENV = "CV3D_PLAN_GEOMETRY"def geometry_check_enabled() -> bool:- return os.environ.get(PLAN_GEOMETRY_ENV, "1").strip().lower() not in ("0", "false", "off", "no")+ return os.environ.get(PLAN_GEOMETRY_ENV, "0").strip().lower() in ("1", "true", "on", "yes")#: Output room for the plan call, sized from the plan budget. A deep plan is much longer#: JSON than a flat one AND Gemini 3.x bills its thinking against the same ceiling, so the#: flat 24 000 that served 8 box-parts truncates a 12-part plan with sub-parts —diff --git a/harness/docs/DECISIONS.md b/harness/docs/DECISIONS.mdindex 60555d1c..6ce73e6c 100644--- a/harness/docs/DECISIONS.md+++ b/harness/docs/DECISIONS.md@@ -253,7 +253,12 @@ written) that were accepted because the code works that way and the tests pin itway and was reverted). Articulated plans only; `CV3D_PLAN_GEOMETRY=0` is the controlarm (`plan_features.LIVE_SWITCHES`). Retro-fired on the 14 recorded compare_art_v3plans: 8 draw a complaint (mean score 0.362), 6 do not (0.610); the six lowest scorers- all draw one. Its effect is read on judge-free quantities the+ all draw one. **Measured 2026-08-28** (compare_art_v4, flash planner, gemini-cli+ generator, judge pro n = 3, 14 prompts, check ON vs OFF as paired arms): score Δ+ +0.064 [−0.188, +0.315], wins 6/6/2; final gate errors 0.00 vs 0.25; round-0 distinct+ joint_sweep targets 0.54 vs 0.25; the re-ask fired in 7/14 cells. No measurable gain,+ so the switch ships OFF (`CV3D_PLAN_GEOMETRY=1` turns it on) — the plan-loop rule.+ Its effect is read on judge-free quantities the8–14-prompt batteries CAN resolve — joint_sweep error count, build rate, rounds to aclean sweep — not on the judge mean (docs/EVAL.md §8.1).* **D45 Joint-sweep findings reach the fixer aggregated per link pair (2026-08-28).**diff --git a/harness/tests/orchestrator_tracks/test_planner_geometry_reask.py b/harness/tests/orchestrator_tracks/test_planner_geometry_reask.pyindex f93ebdbe..632f3e6a 100644--- a/harness/tests/orchestrator_tracks/test_planner_geometry_reask.py+++ b/harness/tests/orchestrator_tracks/test_planner_geometry_reask.py@@ -4,6 +4,8 @@ from __future__ import annotationsimport copy+import pytest+from codeverse.contracts.common import Language, Trackfrom codeverse.contracts.plan import ArticulatedPlanfrom codeverse.proc import EventLog@@ -27,6 +29,13 @@ def _spec():return make_spec(track=Track.ARTICULATED_OBJECT, language=Language.URDF_BLENDER, prompt="a desk drawer unit")[email protected](autouse=True)+def _geometry_on(monkeypatch):+ from codeverse.tracks.planner import PLAN_GEOMETRY_ENV++ monkeypatch.setenv(PLAN_GEOMETRY_ENV, "1")++def test_geometry_complaint_reasks_then_accepts(tmp_ws):answers = [_bad(), _good()]model = FakeChatModel(lambda req: answers.pop(0))@@ -58,9 +67,10 @@ def test_static_plans_skip_the_geometry_check(tmp_ws):def test_switch_off_skips_the_geometry_reask(tmp_ws, monkeypatch):- from codeverse.tracks.planner import PLAN_GEOMETRY_ENV+ from codeverse.tracks.planner import PLAN_GEOMETRY_ENV, geometry_check_enabled- monkeypatch.setenv(PLAN_GEOMETRY_ENV, "0")+ monkeypatch.delenv(PLAN_GEOMETRY_ENV, raising=False)+ assert not geometry_check_enabled() # off unless asked for (A/B 2026-08-28: no measurable gain)model = FakeChatModel(lambda req: _bad())p = plan(_spec(), "fake:planner", ArticulatedPlan, tmp_ws, model=model, runtime=FakeRuntime(Language.URDF_BLENDER))assert isinstance(p, ArticulatedPlan) and len(model.requests) == 1