Repository navigation
feat(apps): capture frozen CPU evidence from the evaluation CLI - #620
Conversation
Agent-assisted-by: Codex (author/integrator) Signed-off-by: zengchuang <zengchuang3@huawei.com>
amy-why-3459
left a comment
There was a problem hiding this comment.
LGTM
Codex, acting for @amy-why-3459.
PR review verdict — PASS
复核范围与验证
已核对 base 5a303ca4f9f3d1b1f24f8a1b5bef68b4a327f735 至 head 6fa2078e282b0e5297b6147e28fe054dde6b0f7c 的七文件差异及 #599 的验收范围。仅 execute 接受采集开关;投影器在 Harness 为新尝试调用采集回调时创建,并从已验证的冻结元数据读取候选和报告角色。回归用例覆盖重放、冲突、进行中的尝试及发布失败后的恢复,核对固定的记录引用,并在不应重新执行的路径上禁止再次启动 worker 或构建投影器。
当前提交的 Ready CI 已通过。本次批准覆盖 Apps CLI 的 CPU 证据采集;生成候选的血缘验证与三宿主集成分别由 #621 和 #371 跟踪。
Bounty-hunter
left a comment
There was a problem hiding this comment.
deepseek-v4.1-flash (agent), acting for @Bounty-hunter.
Interim review note — no formal vote. I reviewed 6fa2078e against base 5a303ca4 (main), as a static read of the diff and the cited head files.
Verified:
--capture-evidenceis added only toevaluate execute;_execute_portsreceives it as host assembly, andAppsExecuteRequest,StorageConfigand the runtime-config schemas are untouched, matching the accepted #599 scope.PreparedCapture.__init__only deep-copies storage.read_prepared, the protocol read andProofProjectorconstruction sit insidecapture(), which H invokes only for a fresh attempt; the added replay, conflict and in-progress tests assert zero projection, capture or worker.- Role names come from validated prepared metadata (
candidate_contract.input_role,recipe.outputs[0].role), andpreparation._recipepinsoutputsto the singlegraderentry, so the[0]access is backed by the frozen validator. ProofErroris translated toPublicErroratevidence_capture, preserving H's zero-start refusal for a declared projection error.- The new tests cover correct, wrong, invalid-UTF-8 and missing candidates, fixed references through status/trace/report/dashboard, registered replay, conflict, live attempt, publication failure before and after publication, and the execute-only flag.
Not verified:
- I did not run the tests; the "233 focused tests" and "local Git tree and published source tree are identical" claims were not recomputed.
- At review time
full-check (3.10)was still in progress.full-check (3.11), bothinstalled-packagechecks,declarations,lint-and-smoke,pr-referencesanddashboard-browserhad passed.
Optional, not blocking: the PR body says the repeated installed-launcher checks "will be linked here" — update it once recorded. In production_capture.py, prepared["recipe"]["outputs"][0] relies on the single-output invariant; a one-line comment pointing at the validator would make that explicit (the validator already enforces it).
Stop check: PR #620, governing #599 and ancestors #371/#362 have no bot:stop and no active stop comment.
Scope: static diff and affected-source read on this head; no execution and no test run.
Bounty-hunter
left a comment
There was a problem hiding this comment.
deepseek-v4.1-flash (agent), acting for @Bounty-hunter.
PR review verdict — PASS (non-voting patrol follow-up; the formal vote stays with the account's formal reviewer).
Evidence on unchanged head 6fa2078
This follows my earlier interim note on the same head and the independent approval at 6037150963. All check runs for 6fa2078e282b0e5297b6147e28fe054dde6b0f7c are now green, including full-check (3.10) (success, finished 09:59:17Z), which that note left in progress, full-check (3.11) (09:52:39Z), both installed-package lanes, declarations, lint-and-smoke, pr-references, dashboard-browser and the advisory host-compatibility lanes; the knowledge-model-policy status is success. The ready-lane run linked in that approval (45367280089) is on this same head.
Static findings are unchanged: --capture-evidence exists only on evaluate execute; replay, conflict and in-progress requests return before _run_claimed, so PreparedCapture.capture and any projector or worker construction are fresh-attempt only; role names come from the validated preparation (candidate_contract.input_role, the single recipe.outputs[0].role); and a ProofError becomes a PublicError whose code is in H's fatal-config set, so the record keeps the zero-start refusal (exit 3, started: false).
Not verified: I did not execute the test suite locally, so the "233 focused tests" count and the local/published tree-identity claim were not recomputed.
Scope: static re-read of the seven changed files plus check-run and status reads on this head; no execution.
david6666666
left a comment
There was a problem hiding this comment.
LGTM
Dot, acting for @david6666666 (repository admin) under delegated independent InferRSI PR review and approval.
PASS on 6fa2078e282b0e5297b6147e28fe054dde6b0f7c for #599's bounded CLI composition. I reviewed the seven-file diff and traced the switch from evaluate execute to H's fresh capture callback. The adapter reads frozen role metadata and delegates projection to B; it does not change saved requests or rerun capture for registered attempts. The regression definitions cover independent F/C/M outcomes, fixed views, replay and a publication failure without losing the original reference.
Verified all eight Ready jobs, including installed-package jobs, and the required policy result on this head. I did not rerun the full suite locally. This does not cover generated-candidate lineage (#621) or merged three-host acceptance (#371).
Dong1017
left a comment
There was a problem hiding this comment.
LGTM
Posted by Dong-bot, an automated agent acting on behalf of @Dong1017 (always-on-bot, model claude-sonnet-5-5).
PR review verdict — PASS
Reviewed base 5a303ca4f9f3d1b1f24f8a1b5bef68b4a327f735 against head 6fa2078e282b0e5297b6147e28fe054dde6b0f7c (7 files, seed diff complete). No blocking findings.
Seat first. This head already carries two independent current-head formal Approves — @amy-why-3459 (6037150963) and @david6666666 (6037578062) — so #599's gate of two eligible LGTMs plus green CI is met without this review. @Bounty-hunter's two reviews on this head are COMMENTED patrol notes, not votes. Per the #599 records (by-hand comments there, plus the #597 body that excludes this account as the slice's accountable parent), a Dong1017/Dong-bot check is comment-equivalent and not an independent vote: the two qualifying votes above stay the only ones. This Approve is therefore a Dong-bot (authorized delegate) technical record on 6fa2078e, not a third vote.
Verified in the diff
--capture-evidenceis registered only for theexecuteaction (src/inferrsi/apps/cli/evaluate.py:30-32) and reaches_execute_portsas host assembly (:185-186); no field is added to the saved request,StorageConfigor runtime config.- The adapter is constructed outside the callback and injected at call time (
evaluate.py:116-126→src/inferrsi/harness/api.py:18-26,47-56), so the flag stays opt-in and #597 identities are unchanged when it is absent. - Every read sits inside the callback:
read_prepared, the protocol read throughArtifactReader.open(returnsBytesIO, context-manager safe), thenProofProjector(prepared, protocol), whose__init__runspreparation.validate_prepared, all before any role name is read (src/inferrsi/apps/handoff/production_capture.py:17-36,src/inferrsi/benchmark/proofs.py:186-191). Role derivation is not guessed:_recipepinsoutputs == [{role: "grader", …}](src/inferrsi/benchmark/preparation.py:179-183) and_candidatepinsinput_role: "candidate"(:38-44,154-156). ProofError→PublicError(code, stage="evidence_capture")keeps H's structured refusal; the new test asserts exit 3,started: false,process_outcome: not_startedwith the RecordRef retained forInvalidRequest,UnsupportedSchemaandUnsupportedRuleVersion.- Regression coverage matches the accepted #599 clauses: registered replay, changed-digest conflict and a live in-progress claim never build a projection, recapture or start a worker (each monkeypatched to fail); late opt-in on a registered attempt returns the original checks; publication failure before and after publication keeps the released ref and never reruns; four candidate classes give distinct F/C/M; the flag is rejected on
prepare/assess(exit 2). - Bookkeeping holds:
production_capture.pyandtests/test_apps_production_cli.pyare registered indocs/apps-module-migrations.json,tests/check_installed.pypins the execute-only help flag, and the newcontracts/p1-cpu-smoke.mdlink resolves (docs/contracts/p1-cpu-smoke.mdexists on this head).
Not verified here, and scope limits
- I did not execute the suite, the installed-package lanes, or read the check runs myself. The "233 focused tests" and all-green claims (both
full-checklanes, installed packages,declarations,knowledge-model-policy, Ready run 45367280089) come from the seeded prior reviews and the author, not from my own run. - zengchuang-hw's #599 thread reports this head squashed as
69ccadc6; if that holds, this review is a record on the reviewed head only. - Scope is the P1 single-output CPU CLI composition. Generated-candidate lineage stays #621; merged three-host acceptance and any service/performance claim stay #371. Nothing here is a performance or acceptance claim.
No blocking findings, so no author push is requested.
Governing Issue and delivery slice
Refs #599
Apps implements the accepted opt-in CLI composition. All source prerequisites are on main, including the CPU delivery in #618. Base
5a303ca4f9f3d1b1f24f8a1b5bef68b4a327f735, head6fa2078e282b0e5297b6147e28fe054dde6b0f7c.Anchors touched: A1, A4, A5, A6 (implementation of existing assembly, grading and execution boundaries).
Change and verification
evaluate execute --capture-evidenceuses the frozen Benchmark projector and the existing Apps/Harness capture adapter. Role selection and projection happen inside the fresh capture callback. Existing requests, configuration schemas and the default execution identity stay compatible.Two eligible, independent current-head LGTM approvals and required green CI precede squash. The Apps owner will verify the merged increment and record completion on the issue.
Knowledge authorship declaration