Repository navigation
[None][feat] trtllm_modeling_v2: one verdict rule and a final round instead of mid-run re-certification - #21796
Closed
Wanli-Jiang wants to merge 2 commits into
Closed
Wanli-Jiang wants to merge 2 commits into
Wanli-Jiang wants to merge 2 commits into
Conversation
…rrency, the tree marker A verdict now counts for a check only when it was recorded on the target's current marker, the whole gate-relevant tree with the native libraries, and with the check's inputs. Equivalent checks still share a pass on that marker. The narrowed marker is gone end to end: the rank hook no longer writes what each process imported, snapshots no longer collect it, gate results and verdicts no longer carry it, and the workflow no longer keeps lists of read files or judges a verdict by them. The reuse it was built for never applied in a real run. On the Qwen3.8 MV2 run every new tree changed every check's narrowed marker, and on the FP8 run the verdicts kept by hand had imported every changed op. Its cache also kept a stale answer after a native rebuild under the same commit. Rows of contract_status.jsonl written with `reads` and `reads_marker` still load; the loader ignores keys a verdict no longer has. Signed-off-by: Wanli Jiang <35160485+Wanli-Jiang@users.noreply.github.com>
… final tree, not after every landing While required work is open, the orchestrator no longer re-runs stale checks on its own. A check runs when a task that claims it lands, when the planner adds a `check` task that names it, and in one final round: once no required task is open, every claimed check with no verdict on the target as it is runs again, the non-delivery tiers first and the delivery tier once everything else holds, and delivery proceeds as before. Re-certifying after every landing cost more than it caught. On the Qwen3.8 MV2 run three full rounds of 23 checks took 34.1 of 57.4 gate job-hours (59%); on the FP8 run 98 of 137 gate runs were re-runs across 10 commits. The checks a task claims still run as it lands: those caught premature UNIT_READY decisions on the step5 runs. The re-checks beside running work, the deferral of stale accuracy checks to milestones and the once-per-process delivery rehearsal go with it. A planner `check` task may now name delivery-tier checks, so the planner rehearses delivery when it wants to, and the contract standing it reads names, for each missing check, the commit of its last pass, the tree to diff a change from. The planner prompt says the rest. Signed-off-by: Wanli Jiang <35160485+Wanli-Jiang@users.noreply.github.com>
Wanli-Jiang
force-pushed
the
user/williamj/mv2flow-verdict-slim
branch
from
November 6, 2026 13:52
8b995f0 to
344f652
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
@coderabbitai summary
Description
trtllm_modeling_v2agent flow (agent-flow/) only. Follow-up to the review of #21629: slim the verdict machinery main already has, instead of extending it.One rule for a verdict's currency: the tree marker. A verdict counts for a check when its marker (the content of every file a gate can read, plus the native libraries) is the target's current one and its inputs match. The narrowed marker is gone: the list of Python files each check imported (
reads), its marker narrowed to them (reads_marker),_narrowed,_verdict_holdsand the rank hook's capture of every imported file. In practice it never carried a verdict: on the Qwen3.8 MV2 run every new tree changed every check's narrowed marker, and on the Qwen3.8 FP8 run the 11 verdicts kept by hand had all imported the ops that changed. Its cache also kept a stale answer after a native rebuild under the same commit.Re-certify once, on the final tree, not after every landing. Mid-run the orchestrator no longer re-runs stale checks by itself. Checks run when a task lands (its claimed checks, as before: they caught premature
UNIT_READYon the Step-5 runs), when the planner adds achecktask after reading a diff, and in one final round: once no required task is open, every claimed check stale on the final tree runs, the delivery tier last, then delivery as before. On the Qwen3.8 MV2 run three full automatic rounds took 34.1 of 57.4 gate job-hours (59%); on the FP8 run 98 of 137 gate runs were re-runs across 10 commits.checktask may name delivery-tier checks, so delivery can be rehearsed when the planner wants; the once-per-process automatic rehearsal and the accuracy deferral are gone.Unchanged on purpose.
contract_status.jsonl; workers write only their own decision files. So workers already keep separate logs that one writer consolidates.Behavior changes against main
checktask.contract_status.jsonlrows withreads/reads_markerstill load; those fields are ignored.contract: one rule for a verdict's currency, the tree markercontract.py,workflow.py,snapshots.py,verdict.py, rank hook,tune/stage.pytested_source(−238 LOC)orchestrator: re-certify once, on the final tree, not after every landingorchestrator._settle, planner prompt and DONE text, contract standing, docs, 3 testsTest Coverage
agent-flow/tests: 1848 passed. New intest_orchestrator.py, each failing on the old orchestrator:test_a_landing_that_leaves_a_pass_stale_runs_nothing_while_required_work_is_open(also the last-passed commit in the standing),test_the_final_round_runs_each_stale_check_once_on_the_final_tree_delivery_last,test_a_check_task_may_rehearse_a_delivery_tier_check. Removed: the native-rebuild test of the narrowed marker.pre-commit(root andagent-flow/.pre-commit-config.yaml) passes on the changed files.PR Checklist
Please review the following before submitting your PR:
PR description clearly explains what and why. If using CodeRabbit's summary, please make sure it makes sense.
PR Follows TRT-LLM CODING GUIDELINES to the best of your knowledge.
Test cases are provided for new code paths (see test instructions)
If PR introduces API changes, an appropriate PR label is added - either
api-compatibleorapi-breaking. Forapi-breaking, includeBREAKINGin the PR title.Any new dependencies have been scanned for license and vulnerabilities
CODEOWNERS updated if ownership changes
Documentation updated as needed
Update tava architecture diagram if there is a significant design change in PR.
The reviewers assigned automatically/manually are appropriate for the PR.
Please check this after reviewing the above items as appropriate for this PR.
GitHub Bot Help
To see a list of available CI bot commands, please comment
/bot help.