Repository navigation
feat(benchmark): deliver the pinned CPU evidence smoke task - #618
Conversation
Keep the documentary fixture unchanged. Grade a captured answer against a fixed public byte-sum reference, and measure actual AB/BA operations independently of correctness, without performance thresholds. Agent-assisted-by: Codex (author) 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
CPU 冒烟任务的审阅依据
核对了 base 6e7210ba31fadf0959848f570f0eeee6ababcbd8 到 head 8c65d9e40f04ece06437271866c367e343d4a982 的十文件差异。独立复算了 worker 源码、内嵌输入及三种候选的 SHA-256 和字节数,均与事前公布值一致。worker 按 A1/B1/B2/A2 采样;错误答案仍采样,无效时钟不会补值或重试。端到端测试分别核验格式、正确性和测量结论,也核验发布失败后保留 RecordRef,以及重放不再启动 worker。
当前提交的八项 Ready CI 检查均通过,包括两项安装包检查。本票是 Amy 席位对本次 CPU 交付的独立批准;共享生产验收与另一独立审阅席位按 #565 单独核对。
|
@hsliuustc0106 请按 #565 的候补决定 独立检视当前头 |
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 8c65d9e40f04ece06437271866c367e343d4a982, for the CPU smoke task only and for David's named #565 review seat. I reviewed the ten-file increment on actual main and independently recomputed the SHA-256 and byte counts for the worker, embedded input and all three candidates. The worker measures A1/B1/B2/A2 even when the answer is wrong; invalid timing stays incomplete rather than being filled or retried. The existing fixture pair remains supported, and the integration tests exercise separate F/C/M verdicts, failed publication with a retained reference and replay without a new worker start.
Verified all eight Ready checks, including both installed-package jobs, and the required knowledge policy on this head. I did not rerun the full suite locally. This review does not close #565, attest #609's pre-merge review, or establish production acceptance or a performance gain.
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 6e7210ba31fadf0959848f570f0eeee6ababcbd8 and head 8c65d9e40f04ece06437271866c367e343d4a982 (first review on opened, full ten-file diff, diffComplete: true, no previous head). No blockers found. Note for the record: this head already carries two independent formal Approves — @amy-why-3459 (pullrequestreview-6036184961) and @david6666666 (pullrequestreview-6036759138) — so the seat count does not depend on this review, and Dong-bot's Approve is not an independent vote (consistent with #566 7093090941, #576 7119624655, #615 7129011872).
What I traced outside the diff
- Accepted-pair gate is centralised, and the import exists.
preparation._supported_task(src/inferrsi/benchmark/preparation.py:216-219) is the single gate used at:227(_protocol),:286(_prepared) andassessment.validate_assessment(src/inferrsi/benchmark/assessment.py:121);assessment.py:16already importspreparation, so the new call site needs no new import. Unknown revisions and mixed pairs stay rejected — covered bytest_unknown_or_mixed_task_versions_are_not_guessedand themixed-pair/assessorcases. - The cpu-smoke protocol is accepted by the frozen P1 shape, not just by its name.
_requirements(preparation.py:186-213) still demands the same four check ids with their phases and producer kinds,_recipe(:159-183) the same entrypointfixture_worker, args, roles, capabilities and single requiredgraderoutput, and_protocol(:237-259)sampling == {"order": ["AB","BA"], "repetitions": 2},feedback_visibility == ["format"],metric_definitions == [], and the F/C/M claim rules withrequires_completed_measurement/cleanuptrue only for M.cpu_smoke.protocolsupplies exactly those; thebaselineandresourcespins reuse the_RESOURCEshape and_closure(:105-114) rejects duplicate roles. - Worker output is compatible with the existing report codec.
fixture_worker.mainwritesjson.dumps(..., ensure_ascii=False, allow_nan=False), andproofs.decode_report(src/inferrsi/benchmark/proofs.py:96-100) explicitly permits raw report whitespace, so non-canonical worker bytes are not rejected._millisecondsoutput satisfiesproofs._samples(proofs.py:71-79:_DECIMALfull match andDecimal(value) > 0) for every reachable value, including whole-millisecond values, because the trailing-zero strip stops at the.separator. - No fill, clamp or retry path.
_samplestimes A1/B1/B2/A2 in that order — round 1 is A→B, round 2 is B→A, matching the frozen["AB","BA"]— rejects non-intorend <= startpairs (type(...) is intalso rejectsbool), and returnsNoneinstead of a partial family. The single C comparison runs before the four timed operations, so a failed C never skips sampling, and an unreadable candidate yieldsgrader: Nonewith no C proof rather than a mathematical failure. - Packaging and module hygiene. The new
inferrsi.benchmark.workerssubpackage has__init__.pyand is collected by[tool.setuptools.packages.find] where = ["src"](pyproject.toml:21-23), soworker_source()'sfiles(...)read and the newtests/check_installed.pyprobe (unpacksprepare(...), comparesrecipe.code_sha256tosha256(source), re-readsbaseline-code) are reachable from the wheel.docs/apps-module-migrations.jsonlists the new test under both affected canonical modules (:43,:73).
Non-blocking follow-ups (no author push requested)
- Pin label vs delivered path. The frozen artifact location is
tasks/p1-cpu-smoke/fixture_worker.py(src/inferrsi/benchmark/cpu_smoke.py:23) while the bytes actually ship atsrc/inferrsi/benchmark/workers/fixture_worker.py.locationis excluded fromprotocol_digest/prepared_id(preparation.py:117-132) and_verify_resourcechecks size + SHA-256 only, so identity and integrity are unaffected — but[tool.setuptools.package-data] "inferrsi.benchmark" = ["tasks/**/*.py", ...](pyproject.toml:41) makes the task path look resolvable when it is not. Aligning the label or the worker location before the acceptance pins are frozen would keep the pin self-locating. - Partial-measurement semantics worth one doc sentence.
_samplesreturnsNonefor the whole M family when any one operation is invalid (src/inferrsi/benchmark/workers/fixture_worker.py:37). That is consistent with no-fill/no-retry and M→INCONCLUSIVE, but "makes that family incomplete" indocs/contracts/p1-cpu-smoke.mdcould also be read as retaining the valid rows; stating the intended choice keeps the acceptance matrix unambiguous.
Not verified here: I did not execute pytest, ruff, or either installed-package job, and I did not re-read the CI runs the two Approves cite (45355959545 / 45355958848). The PR body was not seeded in this review, so the "record exact worker/source/input pins before running acceptance cases" requirement in docs/contracts/p1-cpu-smoke.md is taken from the reviewers' checks, not mine. Nothing here establishes shared production acceptance, closes #565, or supports a performance/model-quality claim.
Refs #565
Refs #371
Refs #434
Refs #569
This is the CPU-only actual-main replacement for #575. #575 was squash-merged into the temporary review branch
codex/review-base-575-apps-b6904e24, notmain, so that merge is retained as review history and is not treated as delivery.Final source recorded before executing new cases: head
8c65d9e40f04ece06437271866c367e343d4a982is one commit directly on actualmain6e7210ba31fadf0959848f570f0eeee6ababcbd8. That main contains Harness #567, Apps-only #609 (9fa32b44d51d8daedf305f033cbe8af7bfef0698) and #576. The native increment is exactly 10 CPU files, +509/−7. Nine files are byte-identical to #575's frozen CPU increment;docs/operations.mdpreserves current main and adds only the accepted CPU task row.Frozen source and inputs
These pins are recorded before any final-head worker/acceptance execution:
0f17b902c3b90b1a75321ecc2181019a5c3084ca2bffeee775ce86aabe019903cca2fa85fcc1ad89b23d709ecc809786766da48cc95b5f931826ec986f0f6597b6899661828d50335325d289b9cedccdb3dbcbf5b64f094e14896c734bd9c39b543df89fec85b1c280e5be7bc6a33e31203503cd6edb3084312de4db5a9b436ce4688624e5f1ad0629505e6768e3bb36244f2f3e33e751215afa820334a76ed3No workload, AB/BA order, timing validity rule, threshold or claim criterion changed. Revision 1's coarse-clock correct-case
samples=nullresult and revision 2's omitted result-validator failure remain failures in the record; neither is relabelled PASS. Historical #575/#569 approvals and temporary-branch CI do not transfer.Scope
The standalone
p1-cpu-smoke@1worker checks exact candidate bytes against the public byte-sum reference. F is UTF-8 validity, C is exact answer equality, and M is four actualperf_counter_nsoperations A1/B1/B2/A2 regardless of C, with no fill, clamp, retry, re-measure, threshold, performance-gain or model-quality claim. The task/grader pair is explicitly registered while the historical fixture path stays supported.Final integration conditions
Run final-head tests, bare-wheel installed-package validation and Ready CI only after the pins above are on record. Resolve concrete findings. Then require the two eligible independent current-head formal Approves under #565: Amy and David by default; David is requested first, and only the recorded per-head substitute path applies if he does not review. Amy remains required unless she personally records exact-head unavailability, activating the separately accepted conditional substitution. Author, accountable owner/parent, technical-only comments and old-head reviews do not count. Required CI must remain green before squash merge to actual main.
Agent-assisted implementation preserves the commit's DCO and contributor attribution.