Track multi-provider spend and model usage - #2759
Conversation
|
Codex review: needs real behavior proof before merge. Reviewed August 11, 2026, 1:46 AM ET / 05:46 UTC. ClawSweeper reviewWhat this changesThis PR expands Usage & Spend into a coverage-aware multi-provider dashboard, menu summary, and local share card with 7-, 30-, and 365-day periods. Merge readiness⛔ Blocked until stronger real behavior proof is added - 7 items remain Keep open: current main still caps an unset Overview selection at six providers, so this is a distinct feature, but replacing that default needs owner approval and the changed Codex RPC timeout recovery still lacks live proof. Likely related people: Peter Steinberger (high confidence) and Yuxin Qiao (medium confidence). Priority: P2 Review scores
Verification
How this fits togetherCodexBar gathers usage and cost snapshots from enabled providers, aggregates them by currency and coverage, then renders settings, menu, and share-card summaries. This PR changes both the aggregation horizon and which providers are surfaced to users. flowchart LR
A[Enabled providers] --> B[Usage and cost snapshots]
B --> C[Coverage-aware aggregation]
C --> D[Settings dashboard]
C --> E[Menu overview]
C --> F[Share card]
Decision needed
Why: Current main deliberately caps this path at six, while the PR intentionally changes that behavior; the compatibility trade-off is product policy rather than a mechanical correction. Before merge
Findings
Agent review detailsSecurityNone. Review metrics
Root-cause clusterRelationship: Members:
Proposal only: this assessment does not dispatch repair, suppress jobs, mutate sibling items, close, or merge anything. Merge-risk optionsMaintainer options:
Technical reviewBest possible solution: Land the all-provider default only after explicit upgrade-policy approval and a redacted live Codex app-server timeout trace that shows timeout classification and recovery. Do we have a high-confidence way to reproduce the issue? Not applicable: this is a feature PR, not a report of a currently failing behavior. Is this the best way to solve the issue? No: the expanded default is not ready to land until its upgrade behavior is explicitly approved and the timeout-path change has production-boundary proof. Full review comments:
Overall correctness: patch is incorrect AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning high; reviewed against 8d113c642516. LabelsLabel justifications:
EvidenceWhat I checked:
Likely related people:
Rank-up movesOptional improvements that raise the rating; they are not merge blockers.
Rating scale
Overall follows the weaker of proof and patch quality. Workflow
HistoryReview history (57 earlier review cycles; latest 8 shown)
|
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: b03a03bd1a
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
|
Thanks for the sharp review. Two clarifications on the product and architecture decisions:
I also fixed the two concrete hosted-Xcode regressions exposed by the previous run at |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 2194fc72c4
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
|
@Yuxin-Qiao this is ready for final review/merge when you have a moment. Exact head |
What this changes
CodexBar Usage & Spend now works as a true multi-provider overview instead of stopping at Claude and Codex.
Unknown spend is never turned into
$0. Estimates use~, currencies remain separate, and incomplete coverage stays explicit.Screenshots
All values shown here are synthetic.
Combined Overview
Share card
Wide settings · Narrow settings · Proof notes
OpenRouter scope
OpenRouter stays inside the existing plugin boundary on JavaScriptCore and QuickJS. An ordinary API key continues to report credits and key quota.
Management
/activityenrichment is deliberately deferred to a separate follow-up. Removing it restores the existing single optional-request timeout budget and avoids adding a provider-specific history payload or a broader async QuickJS host contract to this PR.Final integration fixes
mainatbff43f8a2cc736a9dd248f6fb275f594b3a472c7.Verification
Exact head:
6e7b6178a3cc2ed86e1e9490b7e551b1eed997a8git diff --checkpassed for the follow-up fixes.This is the current-main successor to #2469 and includes the provider-runtime convergence from #2758. OpenRouter
/activityis preserved separately for a clean follow-up after this lands.Stacked follow-up
#2855 adds the next focused layer: a provider-colored known-token allocation strip and approximate same-row cost per 1M tokens in the Overview summary card.
ff3374eandeb12b5e.