Two-module literal-100% residue lane closed via iface.close() (walk draft->approved->building->verifying->closed in ONE process, CS_RUST_LIB on the built capability_scoring .so). Both feat commits verified gitea/master ancestors: voicebox626f8483(5/11 -> 11/11 — the six talk() closure ports, device IO behind voiceboxSeams, pynput loop facade; 21-case generator-owned truth, live parity via fresh-regen battery, gofmt/vet/build clean), warm_neuron_store318d3bbe(3/6 -> 6/6 — _db connection law + neuron_slugs + handle_hook insertion-order struct; NEW 35-row frozen truth + branch_battery, falsy-coerce defect found+fixed battery-first, clippy -D warnings + fmt clean, LIVE PARITY 76/76 ctypes FFI with negative control). Python suites BOTH pins green (canary + test_p1_03 67/1 skipped each way; no RUNE_WNS_CORE loader — pin inert, documented). Audit regenerated (derived state): FULL 152/193, fn-level 1946/2301; both lane modules at matched==fns, missing lists empty. Evidence: verification/vb-*, verification/wns-*, verification/f2-contract-close.{log,exit}.
104 lines
4.4 KiB
Python
104 lines
4.4 KiB
Python
#!/usr/bin/env python3
|
|
"""Open+close the #2479 literal-100% FINAL-WAVE F2 dichotomy contract
|
|
(2 modules, builder=factory-final-f2). Re-walk law: starts from DRAFT —
|
|
submit_need → approved → building → verifying → closed in ONE process,
|
|
with SHA evidence. CS_RUST_LIB must point at a BUILT capability_scoring
|
|
.so (the Python oracle is retired and raises).
|
|
"""
|
|
import json
|
|
import os
|
|
import sys
|
|
from pathlib import Path
|
|
|
|
REPO = Path(__file__).resolve().parents[1]
|
|
os.environ.setdefault(
|
|
"CS_RUST_LIB",
|
|
str(REPO / "src" / "rust" / "capability_scoring" / "target" / "release"
|
|
/ "libcapability_scoring.so"),
|
|
)
|
|
sys.path.insert(0, str(REPO / "src"))
|
|
|
|
from rune.construction_interface import ConstructionInterface # noqa: E402
|
|
|
|
SHAS = {
|
|
"voicebox": "82dec619",
|
|
"warm_neuron_store": "b3dd6ef2",
|
|
}
|
|
|
|
iface = ConstructionInterface(builder="factory-final-f2")
|
|
|
|
r = iface.submit_need(
|
|
"Close the literal-100% residue for the FINAL-WAVE F2 dichotomy lane "
|
|
"(voicebox +6: _run/start_recording/stop_recording/"
|
|
"_transcribe_and_type/on_press/on_release — audio/IO-adjacent: pure "
|
|
"control logic 1:1, device IO behind injectable seams, pynput loop "
|
|
"facade; warm_neuron_store +3: _db/neuron_slugs/handle_hook) — port "
|
|
"name-preserving into the EXISTING Go crate/Rust crate, extend the "
|
|
"frozen-truth batteries, verify-gated: battery green + truth regen "
|
|
"byte-identical + live parity + gofmt/vet/build + clippy -D warnings "
|
|
"+ Python suites both pins; one commit per module.",
|
|
origin="builder",
|
|
)
|
|
print("submit_need:", json.dumps(r)[:300])
|
|
if not r.get("success"):
|
|
sys.exit(1)
|
|
cid = r["ids"]["contract_id"]
|
|
print("contract_id:", cid)
|
|
|
|
for phase in ("approved", "building", "verifying"):
|
|
t = iface.transition(cid, phase)
|
|
print(f"transition->{phase}:", json.dumps(t)[:200])
|
|
if not t.get("success"):
|
|
sys.exit(1)
|
|
|
|
c = iface.close(cid, observed_evidence=[{
|
|
"kind": "port_evidence",
|
|
"detail": (
|
|
"FINAL-WAVE F2 literal-100% residue lane — 2/2 modules landed on "
|
|
"gitea/master, each SHA ancestor-verified: voicebox 82dec619 "
|
|
"(11/11 — the six talk() closure ports with the voiceboxSeams "
|
|
"injectable: _run argv law, start/stop_recording control law "
|
|
"incl. active-flag ordering + >4000 gate + unlink-swallow, "
|
|
"_transcribe_and_type join law + xdotool check=True except-arm + "
|
|
"finally-unlink, on_press/on_release sentinel twins with "
|
|
"recover-suppression; truth 6→21 cases generator-owned via a "
|
|
"pynput/tempfile/subprocess/faster_whisper rig capturing the "
|
|
"oracle's REAL nested closures over its REAL recording dict; "
|
|
"battery caught + fixed the calledProcessError quote-drop; "
|
|
"gofmt/vet/build clean, live parity 21/21 = fresh regen "
|
|
"byte-identical + battery green on it; canary imports BOTH pins, "
|
|
"adjacent pytest 67/1 skipped BOTH pins) and warm_neuron_store "
|
|
"b3dd6ef2 (6/6 — _db read-only connection law with the sqlite "
|
|
"open peeled off, neuron_slugs sorted-with-duplicates, "
|
|
"handle_hook insertion-order struct; NEW 35-row frozen truth over "
|
|
"real sqlite fixtures with rows captured through the oracle's own "
|
|
"_db()+SELECT; battery PROVED + fixed the W6-era falsy-coerce "
|
|
"defect (slug ''→'warm', importance 0.0→0.5); clippy -D warnings "
|
|
"+ fmt + release .so clean; LIVE PARITY 76/76 via ctypes FFI with "
|
|
"a working negative control; canary list_neurons+neuron_slugs "
|
|
"live + pytest 67/1 skipped BOTH pins). Audit delta: both modules "
|
|
"at literal 100% (missing lists empty), +9 fns programme-wide. "
|
|
"Evidence: verification/vb-* and verification/wns-* "
|
|
"(*.{log,exit,txt,md})."
|
|
),
|
|
}], scope_files=[
|
|
"src/go/voicebox/gaps.go",
|
|
"src/go/voicebox/main.go",
|
|
"src/go/voicebox/battery_gaps.go",
|
|
"src/go/voicebox/main_test.go",
|
|
"src/go/voicebox/truth.json",
|
|
"src/rust/warm_neuron_store/src/lib.rs",
|
|
"src/rust/warm_neuron_store/src/branch_battery.rs",
|
|
"src/rust/warm_neuron_store/src/frozen_wns_truth.json",
|
|
"scripts/gen_voicebox_truth.py",
|
|
"scripts/gen_warm_neuron_store_truth.py",
|
|
"scripts/check_warm_neuron_store_parity.py",
|
|
"scripts/close_contract_final_f2.py",
|
|
"verification/vb-summary.md",
|
|
"verification/wns-summary.md",
|
|
])
|
|
print("close:", json.dumps(c)[:400])
|
|
if not c.get("success"):
|
|
sys.exit(1)
|
|
print("CLOSED", cid)
|