Repository navigation
refactor(replan): qualify semantic progress in TypeScript - #6613
Conversation
Exact-head author validationRun state: finished. Performance disposition: Base: This is a proposed rule-owner cutover. It does not authorize merge, provider promotion, deployment, or whole-program completion. Inputs were synthetic/public fixtures on Linux x86_64, CPython 3.13.12, official Node.js 22.22.3 and embedded SQLite 3.51.3. Checks and limits
Re-run the focused committed checks from this head with the qualified Node version on export LOOPX_USAGE_PING=0
uv run --extra test python -m pytest -q \
tests/control_plane/test_progress_observation.py \
tests/control_plane/test_external_progress_review.py \
tests/control_plane/test_replan_writeback_projection.py \
tests/control_plane/test_replan_context_evidence.py \
tests/control_plane/test_replan_progress_native_cli.py
node --no-warnings --experimental-sqlite --experimental-strip-types --test \
tests/control_plane_ts/progress_delta.test.ts \
tests/control_plane_ts/replan_semantics.test.ts \
tests/control_plane_ts/replan_history.test.ts \
tests/control_plane_ts/effect_runtime_snapshot.test.ts
npm run typecheck:control-plane
uv run --extra test python scripts/generate_semantic_inventory.py \
--changed-from a4483aaece5bc74ec3f969fd067229487022401b
uv run --extra test loopx canary smoke-suite --script semantic-vocabulary-drift-smoke.py
git diff --check a4483aaece5bc74ec3f969fd067229487022401b HEADReal successful writeback and replay compare the ACK's original obligation/Todo/Turn binding, every material file, run artifact, all durable JSONL and the actual canonical snapshot. The original Todo stays open; authority/revision/Todos/leases stay unchanged. A replay duplicates no persisted effect. Rejected writebacks preserve source/index/artifact/provider state; the existing paused-delivery audit is retained and compared. These are complete JSON-value comparisons with no removed fields, not stdout-whitespace comparisons. The six scenarios cover: new probe plus proof accepted; evidence churn alone refused; new probe without proof refused; old blocker under another work item refused; inconsistent terminal stop refused; new terminal scope with matching no-followup/stop accepted. The two accepted cases require literal outcome lists containing only Migration economics
Full console/distribution parityEach row compares pinned base, frozen source, fresh normal wheel and fresh normal sdist. All four produce the same full JSON observation and durable state.
Performance qualificationMatched source baseline/head on the same synthetic path. The reported p95 is the sorted sample at index
Disposition: not_met — owner review remains required. The thresholds remain greater than 5% or an unexplained additive 25 ms p95. No result is waived or called noise. Before approval, the runtime/migration owner must explain or remove each tail regression using the same complete CLI workload and unchanged bounds. The runs establish neither sustained adoption nor whole-program performance. Runtime profile and actual CLI boundary
Baseline managed RSS: 99.45 MiB idle; 102.18 MiB after 200 calls. Candidate managed RSS: 108.20 MiB idle; 111.11 MiB after 200 facade calls. These are separate bounded Linux profile runs, not interleaved improvement evidence. The cold row includes startup plus the complete three-request facade; it is not a pure Node spawn timer. The facade records context validation, one qualifier, and trigger-checkpoint read: three requests per nonempty-context call. The selected delta+outcome qualifier remains one request; successful CLI replay makes zero qualifier requests. Shared codecs and the other two facade requests are still Python-owned orchestration. The console refresh fallback does not have that command scope. Its actual measured qualifier RPC is shown separately:
RPC timing includes the existing unscoped runtime-revision/fingerprint work. The prior Python delta is outside that RPC timer and the native delta is inside it, so RPC differences are not complete rule-cost differences. The scoped microbenchmark does not qualify the full CLI tail. No command-scope optimization is part of this PR. An earlier direct compatibility-parser diagnostic also reported a +61.560 ms File evidence-only p95 tail (+4.36%). It remains a noncanonical diagnostic, not a console acceptance run and not a claimed improvement or explanation. The final protocol uses the actual published entrypoint and asserts the observed full-parser fallback. A failed hypothetical scope=True assertion on the base was a harness error, not a semantic test result; it was corrected before these final runs. Reproduce the console CLI comparisonPinned source comparison: base The receiver calls the published console target, The scripts fix only the shared observation/rollout clock codecs and 1. Create disposable worktrees and one test environmentRun from a LoopX Git clone containing the two commits. If needed, fetch set -euo pipefail
export LOOPX_USAGE_PING=0
repo_dir=$(git rev-parse --show-toplevel)
base_oid=a4483aaece5bc74ec3f969fd067229487022401b
head_oid=02fbace7658b96489cf8be20dce6463c3d8c388d
git -C "$repo_dir" fetch https://github.com/loopx-project/loopx.git main
git -C "$repo_dir" fetch https://github.com/hhyykk/loopx.git codex/ts-replan-progress-20261016
scratch_dir=$(mktemp -d "${TMPDIR:-/tmp}/loopx-replan-replay.XXXXXX")
base_tree="$scratch_dir/base"
head_tree="$scratch_dir/head"
evidence_dir="$scratch_dir/evidence"
mkdir -p "$evidence_dir"
git -C "$repo_dir" worktree add --detach "$base_tree" "$base_oid"
git -C "$repo_dir" worktree add --detach "$head_tree" "$head_oid"
test "$(node --version)" = v22.22.3
uv sync --project "$head_tree" --python 3.13.12 --extra test
python_bin="$head_tree/.venv/bin/python"Save the two exact script blocks below as "$python_bin" - "$base_tree" "$head_tree" "$evidence_dir/source-variants.json" <<'PY_DESCRIPTOR'
import json
from pathlib import Path
import sys
base_tree, head_tree, destination = map(Path, sys.argv[1:])
variants = {
label: {"python": sys.executable, "pythonpath": str(tree), "expected": str(tree / "loopx")}
for label, tree in (("base", base_tree), ("head", head_tree))
}
destination.write_text(json.dumps(variants, indent=2))
PY_DESCRIPTOR
for stage in parity negative happy; do
mkdir -p "$evidence_dir/$stage"
cp "$evidence_dir/cli_receiver.py" "$evidence_dir/$stage/cli_receiver.py"
done2. Run full parity, then the two performance scopes# Six scenarios, each on real File and SQLite authority, without timed samples.
cd "$head_tree"
"$python_bin" "$evidence_dir/qualify_cli.py" \
"$head_tree" "$evidence_dir/parity" "$evidence_dir/source-variants.json" 0
# 64 paired samples per provider/scenario; both refusal paths are warmed first.
"$python_bin" "$evidence_dir/qualify_cli.py" \
"$head_tree" "$evidence_dir/negative" "$evidence_dir/source-variants.json" 64
# 32 paired samples per provider; each restores the same owned synthetic seed.
"$python_bin" "$evidence_dir/qualify_cli.py" \
"$head_tree" "$evidence_dir/happy" "$evidence_dir/source-variants.json" 32 advanced
The negative run times repeated refusals after warming both managed daemons. The positive run resets only its owned synthetic workspace, reads the actual authority to prime the provider outside the timer, then times the first successful CLI write. These are distinct workloads. Variant order alternates by iteration. Raw paired samples and complete observations remain under
An assertion, non-JSON output, wrong package, changed scope, timeout, or unexpected exit is a qualification failure. Keep the evidence and diagnose it before continuing. A mutation is detected only when the expected product output/state assertion fails; a setup or scope failure does not prove sensitivity. The receiver metadata distinguishes those failures. Do not reuse fixture contents for production work. Exact cli_receiver.py"""Disposable real CLI receiver; deterministic observation clocks, no domain mocks."""
from collections import Counter
from datetime import datetime, timezone
import json
from pathlib import Path
import sys
import time
request_path, expected_prefix, metadata_path = map(Path, sys.argv[1:4])
request = json.loads(request_path.read_text())
import loopx
assert Path(loopx.__file__).resolve().is_relative_to(expected_prefix.resolve()), loopx.__file__
# Freeze only the shared clock codec, before consumers bind its functions.
from loopx.control_plane.runtime import time as clock
clock.now_utc = lambda: datetime(2026, 10, 16, 12, tzinfo=timezone.utc)
clock.now_local_iso = lambda: '2026-10-16T12:00:00+00:00'
from loopx import rollout_event_log
rollout_event_log._now_iso = lambda: '2026-10-16T12:00:00Z'
from loopx.control_plane import effect_runtime as runtime
counts = Counter()
qualify_ms = []
qualify_scope = []
actual = runtime.effect_runtime_request
def observed(method, params, **kwargs):
operation = params.get('operation', '')
counts[method + ':' + str(operation)] += 1
if method == 'work_item.replan_semantics.project' and operation == 'qualify':
qualify_scope.append(runtime._REQUEST_RUNTIME_REVISION.get() is not None)
started = time.perf_counter()
result = actual(method, params, **kwargs)
if method == 'work_item.replan_semantics.project' and operation == 'qualify':
qualify_ms.append((time.perf_counter() - started) * 1000)
return result
runtime.effect_runtime_request = observed
started = time.perf_counter()
code = 0
try:
if request.get('control') == 'stop':
print(json.dumps(runtime.restart_effect_runtime(wait_for_exit=True)))
elif request.get('control') == 'authority':
from loopx.control_plane.coordination.canonical_snapshot import read_canonical_snapshot
print(json.dumps(read_canonical_snapshot(rpc=runtime.effect_runtime_result,
runtime_root=request['runtime'], goal_id=request['goal'], include_leases=True,
projection_readback=None, timeout=20)))
else:
from loopx.entrypoint import main
sys.argv = ['loopx', *request['args']]
code = main()
finally:
metadata_path.write_text(json.dumps({'module': loopx.__file__, 'code': code,
'elapsed_ms': (time.perf_counter()-started)*1000,
'counts': counts, 'qualify_ms': qualify_ms, 'qualify_scope':qualify_scope, 'entrypoint':'loopx.entrypoint.main'}))
raise SystemExit(code)Exact qualify_cli.py"""Bounded synthetic CLI source/distribution parity; all raw evidence stays local."""
import hashlib
import importlib.util
import json
import os
from pathlib import Path
import shutil
import statistics
import subprocess
import sys
import time
source, output, variants_file = map(Path, sys.argv[1:4])
samples = int(sys.argv[4])
variants = json.loads(variants_file.read_text())
sys.path.insert(0, str(source))
sys.path.insert(0, str(source/'tests/control_plane'))
spec = importlib.util.spec_from_file_location('replan_cli_fixture', source/'tests/control_plane/test_replan_progress_native_cli.py')
fixture_api = importlib.util.module_from_spec(spec)
spec.loader.exec_module(fixture_api)
def digest(value):
return hashlib.sha256(json.dumps(value, sort_keys=True).encode()).hexdigest()
def call(label, request, cwd):
variant = variants[label]
runtime = output/'managed'/label
runtime.mkdir(parents=True, exist_ok=True)
args_file = output/'request.json'
meta_file = output/'receiver-meta.json'
args_file.write_text(json.dumps(request))
env = {**os.environ, 'LOOPX_USAGE_PING':'0', 'PYTHONHASHSEED':'0', 'NODE_OPTIONS':'--experimental-sqlite',
'PYTHONPATH':variant.get('pythonpath',''), 'TMPDIR':str(runtime), 'TEMP':str(runtime), 'TMP':str(runtime)}
started = time.perf_counter()
result = subprocess.run([variant['python'], str(output/'cli_receiver.py'),str(args_file),variant['expected'],str(meta_file)],
cwd=cwd, env=env, text=True, capture_output=True, timeout=90)
elapsed = (time.perf_counter()-started)*1000
metadata = json.loads(meta_file.read_text())
assert metadata['entrypoint']=='loopx.entrypoint.main'
if metadata['qualify_ms']:
assert metadata['qualify_scope']==[False],(label,'refresh-state fallback scope changed')
assert result.returncode in (0,1), (label,result.returncode,result.stderr)
packet = json.loads(result.stdout)
return {'code':result.returncode,'packet':packet,'meta':metadata,'wall_ms':elapsed}
def stop(label):
result=call(label, {'control':'stop'},output)
assert result['code']==0
def report(values):
return {'p50_ms':round(statistics.median(values),3),
'p95_ms':round(sorted(values)[min(len(values)-1,int(len(values)*.95))],3)}
def files(fixture):
result={key:fixture[key].read_text() for key in ('registry','state','index')}
result['artifacts']={str(path.relative_to(fixture['index'].parent)):path.read_text()
for path in sorted(fixture['index'].parent.iterdir()) if path.suffix in ('.json','.md')}
result['journals']={str(path.relative_to(fixture['runtime'])):path.read_text()
for path in sorted(fixture['runtime'].rglob('*.jsonl'))}
return result
scenarios=('evidence_only','known_blocker') if samples else ('advanced','evidence_only','advanced_no_evidence','known_blocker','terminal_inconsistent','terminal_stop')
if len(sys.argv)>5:
scenarios=tuple(sys.argv[5].split(','))
assert set(scenarios)<=set(('advanced','evidence_only','advanced_no_evidence','known_blocker','terminal_inconsistent','terminal_stop'))
records=[]
for provider in ('file','sqlite'):
for scenario in scenarios:
name=provider+'-'+scenario
workspace=output/'cases'/name
seed=output/'seeds'/name
workspace.parent.mkdir(parents=True,exist_ok=True)
seed.parent.mkdir(parents=True,exist_ok=True)
if workspace.exists(): shutil.rmtree(workspace)
workspace.mkdir()
fixture=fixture_api.make_progress_cli_fixture(workspace,provider,scenario)
primary='head' if 'head' in variants else next(iter(variants))
common=['--registry',str(fixture['registry']),'--runtime-root',str(fixture['runtime']),'--format','json']
guard=['quota','should-run','--codex-app','--goal-id',fixture_api.GOAL,'--agent-id',fixture_api.AGENT,
'--turn-instance-id',fixture_api.TURN,'--scan-path',str(fixture['project'])]
assert call(primary,{'args':common+guard},fixture['project'])['packet']['decision']=='autonomous_replan_required'
bound=call(primary,{'args':common+guard+['--todo-id',fixture_api.TODO]},fixture['project'])['packet']
obligation=bound['autonomous_replan_obligation']
before=call(primary,{'control':'authority','runtime':str(fixture['runtime']),'goal':fixture_api.GOAL},output)['packet']
before_files=files(fixture)
fixture_hash=digest({'authority':before,'files':before_files,'obligation':obligation})
stop(primary)
if seed.exists(): shutil.rmtree(seed)
shutil.copytree(workspace,seed)
observations={}
timings={label:[] for label in variants}
native={label:[] for label in variants}
for label in variants:
stop(label)
shutil.rmtree(workspace);shutil.copytree(seed,workspace)
result=call(label,{'args':common+fixture['refresh']},fixture['project'])
assert result['meta']['counts'].get('work_item.replan_semantics.project:qualify')==1,(name,label,result)
after=call(label,{'control':'authority','runtime':str(fixture['runtime']),'goal':fixture_api.GOAL},output)['packet']
assert after==before,(name,label,'provider changed')
after_files=files(fixture)
if scenario in ('advanced','terminal_stop'):
assert result['code']==0 and result['packet']['appended'] is True
expected=['new_probe_family'] if scenario=='advanced' else ['coverage_backed_no_followup']
delta=result['packet']['autonomous_replan_ack']['semantic_delta']
assert delta['outcomes']==delta['satisfying_outcomes']==expected
assert delta['obligation_id']==obligation['obligation_id']
replay=call(label,{'args':common+fixture['refresh']},fixture['project'])
assert replay['code']==0 and replay['packet']['idempotent_replay'] is True
replay_qualify_calls=replay['meta']['counts'].get('work_item.replan_semantics.project:qualify',0)
replay_files=files(fixture)
replay_authority=call(label,{'control':'authority','runtime':str(fixture['runtime']),'goal':fixture_api.GOAL},output)['packet']
assert replay_files==after_files,(name,label,'replay duplicated a persisted effect')
assert replay_authority==after,(name,label,'replay changed provider authority')
observations[label]={'code':result['code'],'packet':result['packet'],'files':after_files,
'authority':after,'replay':replay['packet'],
'post_replay_files':replay_files,'post_replay_authority':replay_authority,
'qualify_calls':1,'qualify_scope':result['meta']['qualify_scope'],
'replay_qualify_calls':replay_qualify_calls,
'replay_qualify_scope':replay['meta']['qualify_scope']}
else:
assert result['code']==1 and result['packet']['appended'] is False,(name,label,'expected typed-progress refusal',result['code'])
assert {k:v for k,v in after_files.items() if k!='journals'}=={k:v for k,v in before_files.items() if k!='journals'},(name,label,'rejected write changed source')
observations[label]={'code':1,'packet':result['packet'],'files':after_files,'authority':after,'qualify_calls':1,'qualify_scope':result['meta']['qualify_scope']}
(output/f'{name}-{label}-observation.json').write_text(json.dumps(observations[label],indent=2))
stop(label)
expected=next(iter(observations.values()))
assert all(value==expected for value in observations.values()),name
if samples:
if expected['code']==0:
# Restore only this owned synthetic seed; prime the real provider outside the timed CLI.
for iteration in range(samples):
order=list(variants) if iteration%2==0 else list(reversed(variants))
for label in order:
stop(label)
shutil.rmtree(workspace);shutil.copytree(seed,workspace)
prime=call(label,{'control':'authority','runtime':str(fixture['runtime']),'goal':fixture_api.GOAL},output)
assert prime['packet']==before
result=call(label,{'args':common+fixture['refresh']},fixture['project'])
assert result['code']==0 and result['packet']==expected['packet'],(name,label)
assert result['meta']['counts'].get('work_item.replan_semantics.project:qualify')==1
assert files(fixture)==expected['files'],(name,label,'happy-path effects changed')
timings[label].append(result['wall_ms']);native[label].extend(result['meta']['qualify_ms'])
stop(label)
else:
# The existing paused audit is deduplicated; prime both daemons before timing.
for label in variants:
warmup=call(label,{'args':common+fixture['refresh']},fixture['project'])
assert warmup['code']==1 and warmup['packet']==expected['packet'],(name,label,'warmup')
for iteration in range(samples):
order=list(variants) if iteration%2==0 else list(reversed(variants))
for label in order:
result=call(label,{'args':common+fixture['refresh']},fixture['project'])
assert result['code']==1 and result['packet']==expected['packet'],(name,label)
assert result['meta']['counts'].get('work_item.replan_semantics.project:qualify')==1
timings[label].append(result['wall_ms']);native[label].extend(result['meta']['qualify_ms'])
assert files(fixture)==expected['files']
for label in variants:stop(label)
records.append({'provider':provider,'scenario':scenario,'fixture_sha256':fixture_hash,
'observation_sha256':digest(expected),'full_observation_parity':True,'normalization':[],'pythonhashseed':'0',
'clock':'shared Python observation and rollout-event clock codecs fixed before imports; all event IDs/receipt bindings retained',
'entrypoint':'loopx.entrypoint.main','qualify_scope':expected['qualify_scope'],'samples':samples,'raw_cli_ms':timings,'raw_qualify_ms':native,'cli_ms':{k:report(v) for k,v in timings.items()} if samples else {},
'qualify_ms':{k:report(v) for k,v in native.items()} if samples else {}})
(output/'cli-receipts.json').write_text(json.dumps(records,indent=2))
print(json.dumps({k:v for k,v in records[-1].items() if not k.startswith('raw_')}),flush=True) |
|
This pull request has merge conflicts with Choose the remote for the base repository, not an out-of-date fork. git fetch upstream
git rebase upstream/main
# Resolve each conflict, git add the resolved files, then git rebase --continue.
git push --force-with-lease origin HEADFor a same-repository clone whose Keep the DCO |
Signed-off-by: aihop <4408344+hhyykk@users.noreply.github.com>
Signed-off-by: aihop <4408344+hhyykk@users.noreply.github.com>
Signed-off-by: aihop <4408344+hhyykk@users.noreply.github.com>
02fbace to
ed1bd14
Compare
Main synchronization and current-head validation
Current-main changes were inventoried separately: quota capture/checkpoint diagnostics, approved delivery-check presentation, #6615 complete replan snapshot transport, and unrelated benchmark/research/UI work. None duplicates progress novelty or changes its shared codec/qualifier owner. The refreshed frontend and packages include those upstream changes. The dedicated temporary base worktree is removed after qualification; the PR branch and other open PR worktrees remain. New-head results
The matrix compares all six scenarios on File/SQLite: novel probe accepted, evidence-only refused, new probe without proof refused, historical blocker refused, inconsistent terminal refused, matching terminal stop accepted. The original Todo remains open; canonical authority/revision/Todos/leases stay unchanged. Accepted replay is checked against all post-write files and journals plus the actual canonical snapshot. Fresh qualification/replay use 1 / 0 qualifier requests. The real public entrypoint is Current-main/source/installed parity hashesAll four variants match the complete captured JSON value and durable state. No output normalization. Qualifier scope is
Migration economics against synchronized main
Historical limits remain openThe previous full validation and replay scripts are for old The old oversized DSH decision-function failure also remains a review hold. The relevant source bytes are unchanged. No ratchet exception or unrelated repair was added. Old-head CI completed after the original submission. TS/static, real PostgreSQL, Windows and DCO checks passed. Python Tests had browser and Stage2C failures. Release Artifacts failed its browser probe. Stage2C collection fails because No local whole-repository suite, Windows/macOS, PostgreSQL or real-model journey was run during this sync. This update requests review; it grants no merge, deployment or provider promotion authority. Reproduce the synchronized source comparisonUse Linux, Python 3.13.12, set -euo pipefail
export LOOPX_USAGE_PING=0
repo_dir=$(git rev-parse --show-toplevel)
base_oid=b543d076995423544b0eeb1990d59d7480f48339
head_oid=ed1bd14336e4c34038cfafdf0bc6b71a11d67b61
git -C "$repo_dir" fetch https://github.com/loopx-project/loopx.git main
git -C "$repo_dir" fetch https://github.com/hhyykk/loopx.git codex/ts-replan-progress-20261016
scratch_dir=$(mktemp -d "${TMPDIR:-/tmp}/loopx-sync-replay.XXXXXX")
base_tree="$scratch_dir/base"
head_tree="$scratch_dir/head"
evidence_dir="$scratch_dir/evidence"
mkdir -p "$evidence_dir"
git -C "$repo_dir" worktree add --detach "$base_tree" "$base_oid"
git -C "$repo_dir" worktree add --detach "$head_tree" "$head_oid"
test "$(node --version)" = v22.22.3
uv sync --project "$head_tree" --python 3.13.12 --extra test
python_bin="$head_tree/.venv/bin/python"
# Save the two unchanged scripts under evidence_dir before the next commands.
"$python_bin" - "$base_tree" "$head_tree" "$evidence_dir/variants.json" <<'PY_DESCRIPTOR'
import json
from pathlib import Path
import sys
base_tree, head_tree, destination = map(Path, sys.argv[1:])
destination.write_text(json.dumps({
label: {"python": sys.executable, "pythonpath": str(tree), "expected": str(tree / "loopx")}
for label, tree in (("base", base_tree), ("head", head_tree))
}, indent=2))
PY_DESCRIPTOR
cd "$head_tree"
npm ci --ignore-scripts
"$python_bin" "$evidence_dir/qualify_cli.py" \
"$head_tree" "$evidence_dir" "$evidence_dir/variants.json" 0
uv run --extra test python -m pytest -q \
tests/control_plane/test_progress_observation.py \
tests/control_plane/test_external_progress_review.py \
tests/control_plane/test_replan_writeback_projection.py \
tests/control_plane/test_replan_context_evidence.py \
tests/control_plane/test_replan_progress_native_cli.py \
tests/control_plane/test_quota_decision_capture.py \
tests/control_plane/test_replan_semantics_transport.py \
tests/control_plane/test_lifecycle_guard_reentry.py
node --no-warnings --experimental-sqlite --experimental-strip-types --test \
tests/control_plane_ts/progress_delta.test.ts \
tests/control_plane_ts/replan_semantics.test.ts \
tests/control_plane_ts/replan_history.test.ts \
tests/control_plane_ts/effect_runtime_snapshot.test.ts \
tests/control_plane_ts/checkpoint_artifacts.test.ts
npm run typecheck:control-plane
uv run --extra test loopx canary smoke-suite --script semantic-vocabulary-drift-smoke.py |
loopx-agent
left a comment
There was a problem hiding this comment.
Reviewer: model_agent | gpt-6.1-sol | OpenAI | runtime_reported | reasoning_effort=max
REQUEST_CHANGES · [P2] 当前 head 的完整调用性能资格尚未满足。 未发现本轮有界实际调用中的新语义/持久化错误;当前正确性证据不替代已接受的 payoff 晋升门。
动机
需要让停滞工作恢复推进的 Agent 与维护者,依赖同一套语义进展规则区分新结果、旧 blocker 和真正完成。
原来 Python 先判断新颖性、TypeScript 再决定结果能否解除当前义务;提案把两步合到同一个原生请求,仍应让合法进展写回、旧 blocker 被拒,并在重试后保持原回执。
源码、正常 wheel 和 sdist 的真实 File/SQLite CLI 完整输出、持久化和重放一致;当前配对性能仍有超过回退门槛的路径,尚未满足迁移晋升资格。
本次不迁移存储或 settlement writer,不完成整个控制面或全部 Python codec 退役,也不认证真实模型采用、其它宿主与长期净益。
本切片还需完成当前 head 的性能资格判断;共享 observation/fingerprint、history 与 Vision codec 随其余既有消费者迁移后退役。
改动思路
原生 progress_delta 是语义规则 owner,既有 replan_semantics 决定义务是否满足;Python 只传规范化事实和保留共享 codec。二者在同一个请求内组合,不新增 RPC、provider、开关或持久状态,归属与原接受规范相符。 当前 PR 是把完整新颖性规则并入既有 replan qualifier 的有界切片;可保留有真实调用者的共享 codec,但需交代并验证生产调用的收益与成本,不能用微测或单一通过路径替代晋升证据。
新颖性回答“结果有没有改变前沿”,既有 outcome kernel 回答“这种改变能否解除当前义务”,两者职责不同但应在一次调用内完成。Python 保留仍供 refresh、context/history、external review 和 Explore 使用的 normalization/fingerprint/Vision codec;当前就复制它们会制造第二权威。实际命令、授权和拒绝恢复入口保持,用户不需要额外配置或确认;正常任务仍是一轮提交与原回执重试。未来改动检查已应用到共享 PROGRESS_RESULT_CLASSES 与同请求组合 seam,未借机扩大为完整 codec 或存储迁移。
| 原路径 | 当前路径 | 必须保留 |
|---|---|---|
| Python计算delta→原生判定义务 | Python事实codec→同一原生请求内计算delta并判定 | 公共输入、错误顺序、诊断和持久化 |
| 显示窗口之外的旧blocker仍已知 | 完整规范化历史走既有私有snapshot | 不截断旧声明、不靠换Turn冒充新结果 |
| 第一次接受与后续重放 | 原writer一次append、重放不重复qualify | 原receipt/obligation identity及无副作用重放 |
具体改动
head ed1bd14336e4c34038cfafdf0bc6b71a11d67b61,实际 base b543d076995423544b0eeb1990d59d7480f48339。spec_ref: docs/architecture/rfcs/typescript-control-plane-migration-v0.md;spec_revision: b543d076995423544b0eeb1990d59d7480f48339。独立依据为该基线 Accepted RFC,并关联 #3225;候选 checkpoint 改写不豁免旧条款。
| 规范原条款 | 当前判断 |
|---|---|
| §5 Canonical owner | implemented:删除Python新颖性/terminal coverage定义107行,native owner与原outcome在同请求组合。 |
| §5 Boundary cost | implemented:产品5文件+140/-122净18;真实首次qualify1→1,重放0→0。 |
| §5 Facade exit | implemented:共享codec有实际调用者,随既有refresh/history/context/external-review/Explore消费者迁移退役。 |
| §6 Semantic parity | implemented:真实File/SQLite完整输入输出/状态/重放、重叠非法条件和物理mutation已核。 |
| §6 Packaging | implemented:正常wheel/sdist、隔离安装来源及完整CLI消费一致。 |
| §6 Performance | not_met:当前完整CLI仍有未解释的p95回退,完整冷/热/RSS资格尚未收口。 |
| Whole control-plane retirement | deferred:以上真实共享消费者仍需迁移,不把整个父RFC完工当此切片前置。 |
| Provider and deployment | out_of_scope:不改store、writer、promotion、权限或发布。 |
关键代码讲解
- semantic_delta_from_writeback 保留原context/history来源校验与codec顺序;非对象current仍跳过无效baseline/window,正常current→prior→容错window→Vision。不因为显示预算而遗漏旧证据,12000行反例保留旧blocker。
- projectProgressDelta 从规范化current/prior/window计算语义维度、terminal覆盖、evidence/fingerprint/blocker复用;闭合结果词汇来自原replan_history。TS校验形状,不伪称再次验证fingerprint真实性,避免第二normalization owner。
- projectReplanWriteback 只对qualify要求progress_source并拒绝调用者预计算delta,在本进程内先算delta再交原outcome;其它operation不变。Python复用上游既有project_replan_semantics transport,本PR没有再加snapshot allowlist或一层RPC。
整提案15路径+624/-355:产品5净18,验证/配置7净231,文档3净20;测试搬动不计作policy退役。3个当前提交均有DCO。69base/91head调用搜索核对了共享codec、旧helper剩余引用与真实退役条件。这个纯内部资格计算未新增operator-facing projection,因此没有给它强加新读模型封套验收。
对主干的风险
[P2] 完成当前 head 的性能资格后再晋升。 当前同工作负载、交替执行顺序、每格每版本32次完整公共CLI,真实File/SQLite,保留全部样本和完整输出:
| 后端/场景 | p50 ms base→head | p95 ms base→head | p95增量ms |
|---|---|---|---|
| file/advanced | 1242.550→1240.031 | 1730.243→1757.530 | +27.287 |
| file/known_blocker | 1061.949→1044.953 | 1334.760→1281.473 | -53.287 |
| sqlite/advanced | 1287.676→1288.977 | 1539.770→1465.254 | -74.516 |
| sqlite/known_blocker | 872.238→876.346 | 1127.316→1166.301 | +38.985 |
File首次成功写回+27.287ms、SQLite旧blocker拒绝+38.985ms,均超过未解释25ms additive目标。该有界样本不能证明稳定的生产回归原因,p50改善或拒绝路径变快也不能消除未完成的资格判断。当前qualifier区间包含现有bridge/回退scope,不能冒充同作用域纯native warm<2ms微测;冷/热、RSS和完整调用成本应按规范边界分别交代。作者先前Linux的+33.757/+54.407ms是其历史证据,本轮没有将它们改名为当前B实测,或声称已修复。最小后续是同head按代表工作负载完成分层配对、解释回退或做既有owner内有界优化;若增加回归预算更合理,在现有PR里以消费者价值、冗余、成本和headroom证据修正规则与测试,不能静默抬限或截掉历史/义务。
正确性独立证据:151 Python、78 native TS,0skip;全control-plane typecheck、advisory后fullsemantic、Chat生产构建、正常wheel/sdist通过。5个产品文件与37Chat资产在源码/归档/两份全新安装逐字节相同。已完整读过并检查安全边界的公开author harness被独立执行,调用的是public entrypoint.main,source只提供合成fixture;4receiver(不可变base、当前source、正常wheel、sdist)×6场景×2存储比较完整JSON、registry/state/artifacts/journals及独立provider快照,没有删字段归一化。固定的是导入前共享观测/rollout时钟codec和hashseed,不删receipt或Turn identity。
新probe/新证据和一致terminal可写一次;evidence-only、缺证据、历史blocker换work、terminal不一致保留完整拒绝。成功重放不追加效果、不改变provider/lease,首次1qualify、重放0。将正常安装副本的delta_kinds物理置空,使同一publicCLI合法成功断言失败;原包矩阵通过。首次只改accepted=false未影响现有outcome判定,已保留为不敏感试验,未冒充mutation成功。没有真实模型/外部provider调用、存储迁移或活跃Goal测试。
语义与 CI 对齐
原生premerge5direct通过、19selected完成,其中18通过、DSH为继承advisory,整体仍因旧base的quality_stale_receipt失败。相同原maintainability命令在b543与ed1b均为同一 _run_dsh_operation_host 大函数身份和完整细节,0magnitude增长;其AST/source不在此diff,独立归为既存无关红项。它不替代本PR性能缺口,也不要求本PR修无关代码。未生成新质量回执、豁免或削弱预算,未查、触发或等待GitHub CI。
PROGRESS_RESULT_CLASSES复用既有已注册值;没有新增用户状态或宽泛生命周期名称。状态规则由typed decoder/稳定身份/明确分支决定,不用prose或substring;generic错误仍中立。原硬义务未改称guidance,classification/ACK不构成新进展。完整公共诊断及修复指令在实测中一致;课程把已移除的内部helper替换为完整资格入口,既有history和terminal义务保留。模型是否理解/采用仍未验证,绿色语义扫描不代替该证据。
我的整体评价
REQUEST_CHANGES。 归属、局部代码量和已有codec保留合理,真实publicCLI与正常安装语义证据较完整;当前阻塞是Accepted §6 Performance未收口。当前 PR 是把完整新颖性规则并入既有 replan qualifier 的有界切片;可保留有真实调用者的共享 codec,但需交代并验证生产调用的收益与成本,不能用微测或单一通过路径替代晋升证据。 long_horizon=preserved和user_experience=preserved只覆盖已测完整历史、写回/重放和同入口零新增交互,不代表持续运行性能或全部父迁移完成。完成当前成本资格后应重新核对完整新head及原反例;无需为合理codec保留另建框架或仪式性后续。此评审不授合并、升级或dismiss权限。
English verdict: REQUEST_CHANGES — ed1bd14. Full real File/SQLite public CLI semantics, persistence and replay match across immutable base/current source/normal wheel/sdist;151Python/78TS and a meaningful physical semantic mutation are verified. The bounded payoff refactor still lacks accepted current-head performance qualification: File first-write full-CLI p95 increases27.287ms and SQLite blocker refusal increases38.985ms in the current32paired samples. Attribute/qualify the relevant cost or record an evidence-backed budget decision without dropping history or obligations. Unrelated DSH/CQR holds remain separate; CI was not consulted.
|
This pull request has merge conflicts with Choose the remote for the base repository, not an out-of-date fork. git fetch upstream
git rebase upstream/main
# Resolve each conflict, git add the resolved files, then git rebase --continue.
git push --force-with-lease origin HEADFor a same-repository clone whose Keep the DCO |
Signed-off-by: LoopX Agent <337587101+loopx-agent@users.noreply.github.com>
Signed-off-by: LoopX Agent <337587101+loopx-agent@users.noreply.github.com>
Signed-off-by: LoopX Agent <337587101+loopx-agent@users.noreply.github.com>
Signed-off-by: LoopX Agent <337587101+loopx-agent@users.noreply.github.com>
loopx-agent
left a comment
There was a problem hiding this comment.
Reviewer: model_agent | gpt-6.1-sol | OpenAI | runtime_reported | reasoning_effort=max
APPROVE · 当前 head 的有界规则收敛、真实调用与成本资格已满足。 本轮由同一 maintainer Agent 完成修复、对照执行和评审,不将它称为另一位独立 reviewer。
动机
需要让停滞任务继续推进,并用回执安全重试的用户和 Agent。 原来 Python 判断结果是否新颖,TypeScript 再判定义务是否解除;两套规则分散,完整写回还重复解析运行时代码,增加每轮命令成本。
同一条写回命令仍接受新探针、拒绝旧 blocker,并在冷启动重试时返回原回执;当前完整 CLI 的四条路径 p95 均改善,用户不用新增配置或确认。
不迁移存储或 settlement writer,不改变 claim/lease、provider 默认、实际执行和验收权限;不认证完整 Agent 迁移、生产采用或长目标 soak。
共享 observation/fingerprint/history/Vision codec 仍有 refresh、context、external review 与 Explore 消费者,随这些既有消费者迁移后退役;迁移主线由原产品验收继续推进。
改动思路
新颖性与义务结果在同一 TS 请求内分工,Python 保留有实际消费者的规范化和持久化;现有代码版本作用域消除重复解析,状态读取与授权仍由原 owner 执行。
本次完成既有 replan 写回资格规则与真实命令成本的有界收敛,完整 Agent 迁移与剩余 codec 退役仍按既有路线推进。
| 旧路径 | 当前路径 | 保留的不变量 |
|---|---|---|
| Python 判新颖性,再跨运行时判能否解除义务 | Python 传规范化事实;同一原生请求内先判新颖性,再交既有 outcome kernel | 完整历史、证据来源、拒绝顺序、诊断和回执身份 |
| fallback refresh 每次原生请求都解析代码 | 有限 CLI 复用既有 request scope,独立 qualifier 同样可复用 | 只固定代码;每次真实 source/provider 读取、canonical 写入与权限检查仍执行 |
| 首次写入与重试 | 仍由原 writer 追加一次;冷启动重试返回原回执 | 不重复 qualify、追加或修改 Todo/lease |
这是现有有界 owner 的收敛,没有新 provider、配置、缓存、worker、RPC 或生命周期模型。共享 normalization/fingerprint/历史/Vision codec 有真实调用者,提前再复制一份会制造第二来源。未来改动检查已应用:复用既有结果词汇与代码作用域;完整 codec 或 writer 迁移留在它们真实消费者的边界。
具体改动
精确 head 004e0b3e5302b006cce83d4a01297011a0aa6116;不可变对照/spec_revision ad5c2b57605273cc567d85f8f3ee39ba6f11f023。spec_ref: docs/architecture/rfcs/typescript-control-plane-migration-v0.md;Accepted RFC §§5–6。主干后来只新增独立 finance provider/test;共享 runtime/build/RFC/UI 源码未变,17 个提案路径与评审 head 未变,CQR 已按新 base 重新核对。
| 原规范条款 | 当前判断与证据 |
|---|---|
| §5 Canonical owner | implemented:projectProgressDelta → projectReplanWriteback;107 Python definition lines retired. |
| §5 Boundary cost | implemented:Seven product files+146/-122;first qualifier1→1/replay0→0;full refresh31calls unchanged, fingerprint31→2. |
| §5 Facade exit | implemented:Shared observation/fingerprint/history/Vision codecs remain for refresh/context/external review/Explore; retire with those consumers. |
| §6 Semantic parity | implemented:12 File/SQLite scenario rows across4 variants;12000-row old blocker;cold replay;normal-wheel semantic mutation. |
| §6 Packaging | implemented:7 production and37 compiled UI files match source/archives/installs;all normal installed scenarios and8 cold replays pass. |
| §6 Performance | implemented:Fixed32 alternating pairs per4arms all<=5% AND25ms;p95 warm1.826ms<2;16cold/128warm/256burst measured. |
父 RFC 的完整控制面退役仍 deferred;provider/promotion/deployment 与 settlement writer 为 out_of_scope。不是把整个父阶段完工当作本切片前置。
关键代码讲解
- semantic_delta_from_writeback 保留 context/history 先校验、current→prior→容错 window→Vision 的顺序;完整历史不会被显示预算截掉,main 新增的 source-bound stride review evidence 与 progress_source 同时保留。Python 只提供规范化事实,历史归一化错误的既有容错和明确拒绝不变。
- projectProgressDelta 拥有维度变化、终态覆盖和 evidence/fingerprint/blocker 新颖性;closed set 来自既有 replan_history。它验证规范化 carrier 形状而不另算 fingerprint,不冒充新的身份真实性来源。改 work/Turn 或刷新证据不会把已知 blocker 变新。
- projectReplanWriteback 仅对 qualify 要求 progress_source,拒绝调用者预计算 observation_delta,再在本进程组合原 outcome/stride kernel。其余 operation 沿原路。私有载体变化已明示,公共 refresh/ACK 与现有 artifact/runtime 配对保持。
- 有限 CLI handler 与 独立 qualifier 复用既有代码版本作用域。真实 refresh 仍有31次原生调用,指纹解析31→2;没有缓存来源数据、跳过 provider/权限校验、缩短历史或加粗超时。
整提案17路径+644/-355:产品7路径+146/-122、净24;验证/config7路径+452/-221;文档3路径+46/-12。删除107行 Python 决策定义不等于产品净删107行,测试搬迁也不当作policy退役。未新增依赖/生成源码;7个原作者及维护提交都有DCO,正常快进保留原作者历史。课程改为真实完整资格入口,成对 RFC 交代当前 scope 与剩余 codec 条件。
对主干的风险
最危险的是只验证 native 小函数而漏掉完整调用:旧 blocker 在显示窗外被当新结果、context/错误优先级改变、写后重试重复效果,或 warm 更快却整条 CLI 更慢。本轮分别跑真实 provider、完整输出/持久化、冷启动重放和完整成本,并没有用同一实现的当前输出编造预期。
正确性按阶段保留:177项 integrated Python 在 scope 修复前通过;资格 scope 后164项通过;最终入口/scope/大历史 lifecycle32项通过(其中18个较小 lifecycle 变体在该次有意 deselect,旧完整运行已覆盖),另28项 CLI companion通过。79项 native 对应的 TS policy blob 未再改变。实际 File/SQLite ×6场景 ×base/source/正常 wheel/sdist 比较完整 JSON、registry/state/index/artifacts/journals、provider revision/Todo/lease 与 replay;只把 private scope instrumentation 单独比较,公共诊断、身份、字段存在性和效果没有归一化删除。固定的是双方观测/rollout clock codec 与 hashseed,monotonic/performance clock 未改。
新探针/一致 terminal 可写一次;evidence-only、缺证明、旧 blocker 换 work、terminal不一致仍完整拒绝。12000条历史反例保留旧声明。8项 installed冷重放均0次qualify,完整回执、文件与 provider不变。对独立正常 wheel 副本物理清空 native delta kinds,同一公共CLI新探针成功断言失败;未改共享源码或把无效 mutation 当敏感性证明。
完整调用每格固定32对、交替顺序,原门仍同时<=5%及<=25ms;测量代码 head fcd76c5b1d29471aa12a0c651aed8be419c215e7 与最终 head 的全部7个产品 blob 相同:
| 后端/场景 | p50 ms base→head | p95 ms base→head | p95增量 |
|---|---|---|---|
| File/new probe | 860.639→649.198 | 1346.543→871.952 | -474.591ms |
| File/old blocker | 728.849→527.423 | 1069.071→776.967 | -292.104ms |
| SQLite/new probe | 925.945→653.793 | 1350.479→894.738 | -455.741ms |
| SQLite/old blocker | 767.790→560.882 | 1088.654→769.066 | -319.588ms |
另测16次 cold、128次 warm qualifier、256次 burst:实际私有传输 warm p95 1.588→1.826ms,两者<2;managed startup p95 338.139→354.444ms;macOS RSS idle/burst 87.31/89.98→88.28/90.89MiB。输入从实际 CLI 请求捕获;warm不含 provider IO。冷启动增加16.306ms和输入6250→7863bytes已计入成本,不能称所有维度更快。
历史失败没有消失:此前作者和 ed1bd14 评审 的 gate 失败,以及只 scope qualifier 的中间版本 SQLite +249.300ms/+30.240ms,均原样保留。相同代码、同一物理 checkout 的32对 A/A 中位数近等,p95仍相差542.106ms,这是波动证据,不是历史原因证明、重采直到绿或放宽门。随后6行既有 scope 使用覆盖真实有限 CLI;其一次固定最终比较如上。收益包含调用方少解析指纹,不能全归因于语言迁移。
语义与 CI 对齐
PROGRESS_RESULT_CLASSES 复用既有五值,没有新增用户状态或宽泛 actor 命名。类型/显式分支与稳定身份决定状态,不用 substring/prose 规则;通用错误仍中立。强制 accepted/义务校验没有改称 guidance,classification/作者声明不构成进展。external review off/shadow 与 stride-off 仍不触发新的 review 义务;完整旧 schema、输入、文本、quota与效果在实际反例中保留。前端/Lark无新增交互,当前 CLI也无需配置或确认;这不是模型是否实际理解/采用的证据。
同一正常 sdist 的真实 SQLite 入口还连续验证了旧 blocker 拒绝→新有效 probe 写入一次→冷启动原 Turn 重放;Goal/Todo/Turn/obligation 绑定保持,canonical revision/Todo/lease 不变,没有新增设置或确认。
正常 Chat build/verify、全 control-plane tsc、Ruff、Python compile、advisory后 full semantic、committed EN/ZH及17路径公开边界通过。7个产品文件和37个编译 UI 文件在 source/archive/两个新安装逐字节相同。既有 Vite chunk-size warning 保留。当前 CQR 与六项 direct/19项 source检查通过、0manual holds;先前仅因 main ref变化的 stale-CQR记录不冒充已过门,已重新核对。未查/等 GitHub CI。无 PG store改动;未验证 Windows、真实模型、installed App/fleet、历史 Linux runtime或长目标soak。
我的整体评价
APPROVE。 本轮当前 head 的 canonical owner、完整实际调用兼容性、正常分发和原成本门均有独立规则/基线证据;这使它成为有用且可回滚的有界增量。long_horizon=preserved:完整历史、稳定回执和重复执行边界保持,但不等于长期 Goal 完成。user_experience=improved:同一个写回/恢复入口、原完整诊断,当前整条命令尾延迟改善,无新增用户步骤。
本次完成既有 replan 写回资格规则与真实命令成本的有界收敛,完整 Agent 迁移与剩余 codec 退役仍按既有路线推进。 保留有真实消费者的 Python codec 合理,不保留已无调用者的旧 novelty facade。类型化规则与 scope 复用的未来改动检查已执行,没有扩为新框架。批准针对 004e0b3e5302b006cce83d4a01297011a0aa6116;合并仍须显式 maintainer授权与原生 unchanged-head readiness,不能由本评审、绿色检查或 admin bypass替代。
English verdict: APPROVE — 004e0b3. Complete real File/SQLite public CLI output, persistence, refusal and replay match the immutable baseline across source/normal wheel/sdist; eight cold installed replays and a physical semantic mutation are verified. All four fixed32-pair full-CLI rows meet unchanged5%/25ms gates; warm qualifier p95 is1.826ms<2. Historical failures and A/A variability remain separate. Code-only scope reuse preserves all source/provider reads and31RPCs while reducing fingerprint resolutions31→2. No fleet/live-model/long-goal or whole-codec-retirement claim; CI was not consulted.
Outcome
Move semantic-progress novelty and terminal-coverage decisions into the existing TypeScript replan qualifier. Python passes normalized current/baseline/full-window facts; the native delta and obligation-outcome owners compose in one request. The public refresh/ACK, refusal, persisted identity and replay behavior remain compatible. The two replaced Python decision definitions (107 lines) are removed; shared observation/fingerprint/history/Vision codecs still have production consumers.
Current head
004e0b3e5302b006cce83d4a01297011a0aa6116integrates mainad5c2b57605273cc567d85f8f3ee39ba6f11f023. The main source-bound stride-review evidence check is preserved alongside the newprogress_source. The finite refresh/checkpoint CLI and standalone qualification reuse the existing code-revision scope: actual refresh RPCs remain 31, code-fingerprint resolutions fall from 31 to 2, and source/provider reads and writes remain live. This is code reuse, with no data cache, new setting, provider, daemon or extra leaf RPC.Specification and scope
Accepted migration RFC §§5–6, specification revision
ad5c2b57605273cc567d85f8f3ee39ba6f11f023; related #3225. Canonical owner, boundary cost, facade exit, semantic parity, normal packaging and relevant cost are qualified as one bounded caller cutover. Whole control-plane retirement, provider promotion, settlement writers and deployment stay outside this PR. Remaining codecs retire with their actual refresh/history/context/external-review/Explore consumers.The private qualify carrier intentionally replaces caller-precomputed
observation_deltawith normalizedprogress_source; the wire entrypoint refuses the old/precomputed carrier. Public CLI input and output stay compatible. Malformed-input order, complete historical claims, source-bound stride evidence, terminal consistency, exact Turn/obligation binding and idempotent replay remain enforced. No user configuration or extra interaction is introduced; frontend and Lark contracts are unchanged.Product diff: seven files, +146/-122 (net24), including strict native decoding and the two existing scope uses. Tests/configuration and docs are counted separately; no policy-deletion claim is based on moved tests. The bounded future-facing pass reuses the progress vocabulary and request scope rather than copying codecs or creating another orchestration layer.
Current validation
Fixed full-CLI cost qualification
32 alternating pairs for every row, complete real entrypoint and original workload. Same Python3.14.8/Node24.21.0 environment on both arms; immutable base above, measured runtime head
fcd76c5b1d29471aa12a0c651aed8be419c215e7. All seven production blobs are identical at final documentation head004e0b3e5302b006cce83d4a01297011a0aa6116. Both original gates remain <=5% and <=25ms p95.Separate16 cold starts,128 warm private-transport qualifier calls and256-request bursts per arm: warm p95 1.588→1.826ms (both<2); managed startup p95 338.139→354.444ms; macOS RSS idle/burst 87.31/89.98→88.28/90.89MiB. This is bounded source evidence, with no HWM, forced GC, fleet, Windows, Linux-runtime, live-model or long-goal-soak claim. The improvement includes caller fingerprint reuse; it is not attributed to language movement alone.
Historical failures remain distinct: the prior exact-head review, earlier author holds and the intermediate qualification-only scope still failed. That intermediate run had SQLite p95 +249.300ms for first write and +30.240ms for blocker refusal. A same-code/same-checkout32-pair A/A control showed near-equal medians but542.106ms tail difference: variability evidence, not a waiver or proof of the historical cause. The final finite-CLI intervention and its single fixed comparison above are a separate result; all prior samples are retained.
Authorship
Original refactor by @hhyykk, declared model_agent / OpenAI Codex / GPT-6 family. Maintainer repair and current validation: model_agent / OpenAI / gpt-6.1-sol, runtime-reported. All seven PR commits retain DCO sign-off; contributor history is preserved with normal fast-forward pushes.