Repository navigation
Description
What the finding is
When Plan usage routes a factory Command's session Steps away from its first configured route ([harness] routes), the pull request's and Run notification's Built with line still names the Command's first route, not the route that ran the implement session.
For example, with routes = ["claude", "codex"] and Claude at its max_utilization ceiling, every Step runs on Codex, but the PR says Built with claude …. Scoring reads Built with as the Harness, Model and Effort that built the change, so it would credit Claude.
Evidence
- Raised by the Spec review of Route factory session Steps across configured Plan usage routes #2200 (Ticket Route factory session Steps proactively and reactively across configured Plan usage routes #2183, parent Spec Spec: view subscription Plan usage and route Steps across Harnesses #583).
src/delivery.rswriteswrite_built_with(&child_asks.harness), andsrc/main.rswritesstarted.built_with(&harness). Both use the Command's resolved choice. In Route factory session Steps across configured Plan usage routes #2200 that is the first route,ChosenBy::Routes.- The design sources disagree:
- The Spec: view subscription Plan usage and route Steps across Harnesses #583 grill, Q2.9(a) in
docs/grill-with-docs/583-available-usage-routing.md, says the single tuple names "the Harness/Model/Effort that ran the primary implementation session (or the Command's resolved first route if rerouted before implementation)". - ADR 0021 and the consequence in ADR 0031 keep
Built withon "the Command's primary choice" when a Step runs on another Harness. - Route factory session Steps proactively and reactively across configured Plan usage routes #2183 asks only to "Keep pull-request and notification
Built withas the single parseable primary tuple".
- The Spec: view subscription Plan usage and route Steps across Harnesses #583 grill, Q2.9(a) in
- Per-Step attribution is already recorded in Route factory session Steps across configured Plan usage routes #2200:
.models.json, each Command record stage'sharness/model/effort, and the Run notification's Session models list.
Why the call is not the implementing session's
Which tuple Scoring credits is a product decision that ADR 0021/0031 and the grill answer differently. The Built with line is written before and after Repairs from the Command's choice in several places (src/main.rs, src/delivery.rs, src/notification.rs). Changing it would also change Scoring's historical attribution semantics. #2200 keeps the ADR's behaviour; the Spec or the Day shift should decide whether Built with should name the route that ran the implement session.
Activity
JacobStephens2 commentedon Nov 14, 2026
Investigation summary
The attribution decision remains unresolved. The selected Base is commit 12da417. It writes the Command's configured Harness/Model/Effort into Built with: src/main.rs:540 supplies asks.harness to the notification; src/delivery.rs:731 and :1376 supply child_asks.harness when publishing and refreshing the PR, including after Repairs. src/notification.rs:236 explicitly describes this as configured attribution, and notifications append '(configured)'.
ADR 0021 explicitly retains the Command's Harness. ADR 0031 preserves that single primary tuple. However, the accepted Q2.9(a) in docs/grill-with-docs/583-available-usage-routing.md:191 and Spec #583 refer to the primary implementation session, with a resolved-first-route exception whose meaning needs clarification. Ticket #2183 requires a single parseable primary tuple without resolving which choice it represents.
The consequences extend beyond displayed credit. src/scoring/sample.rs:39 reads Harness, Model and Effort directly from the PR's Built with line, then groups samples by Harness/Model. src/scoring/grader.rs:77 uses that Model to choose an independent Grader. Therefore, if the tuple differs from the implementing Model, Grader selection also follows the configured Model; it could select the Model that actually implemented the change. This is a code-derived consequence, not an observed production incident.
Existing coverage supports the current contract: tests/security_review.rs:1402 retains the Command's Built with while recording another Harness for Security review; tests/scoring.rs:769 checks factory-written attribution flowing into Scoring. These tests were inspected, not executed.
Day shift decision
Choose and document whether Built with represents the Command's configured primary choice or an implementation session's actual route. Changing to actual-route attribution would reopen ADR 0021 and clarify ADR 0031. Keeping configured attribution requires reconciling the grill and Spec wording and deciding whether Scoring should independently consult implementation evidence for Grader independence.
If actual-route attribution is chosen, define which session wins when implementation reroutes after preserving commits, when Repairs use another route, and when a later Command continues existing work. Also decide whether historical attribution remains unchanged or is migrated. Preserve the single parseable format unless an explicit compatibility change is approved.
After this decision, shape a follow-up covering consistent PR/notification attribution, Scoring behavior, documentation and regressions for proactive routing, mid-Step fallback, Repairs and Continuations. Coordinate with #2183/#2200; this issue addresses their unresolved attribution policy rather than duplicating their routing implementation.