Add environmental footprint visualization for token usage#1108
Add environmental footprint visualization for token usage#1108dailytrap wants to merge 2 commits into
Conversation
|
Codex review: needs real behavior proof before merge. Latest ClawSweeper review: 2026-05-22 12:30 UTC / May 22, 2026, 8:30 AM ET. Workflow note: Future ClawSweeper reviews update this same comment in place. How this review workflow works
Summary Reproducibility: no. high-confidence runtime reproduction was performed in this read-only review. The review finding is source-reproducible: a one-day window can produce identical session and month environmental strings, which makes PR rating Rank-up moves:
What the crustacean ranks mean
Shiny media proof means a screenshot, video, or linked artifact directly shows the changed behavior. Runtime, network, CSP, and security claims still need visible diagnostics. Real behavior proof Mantis proof suggestion Risk before merge
Maintainer options:
Next step before merge Security Review findings
Review detailsBest possible solution: If maintainers want this feature, keep the estimate clearly labeled, fix row identity before merge, and require a redacted runtime screenshot or recording of the cost menu/provider detail UI. Do we have a high-confidence way to reproduce the issue? No high-confidence runtime reproduction was performed in this read-only review. The review finding is source-reproducible: a one-day window can produce identical session and month environmental strings, which makes Is this the best way to solve the issue? No, not yet. The direction may be acceptable if maintainers want the feature, but the implementation should first use stable row identities and provide runtime proof of the visible UI. Label changes:
Label justifications:
Full review comments:
Overall correctness: patch is incorrect Acceptance criteria:
What I checked:
Likely related people:
Codex review notes: model gpt-5.5, reasoning high; reviewed against 097d502afb29. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: f22d22de5c
ℹ️ 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".
| "environmental_impact_energy_today", | ||
| UsageFormatter.formatEnergy(impact.energyKWh), | ||
| impact.smartphoneCharges, | ||
| impact.kettleBoils) | ||
| co2SessionLine = L( |
There was a problem hiding this comment.
Preserve Bedrock billing-day semantics in eco session text
For .bedrock, sessionTokens represents the latest billing day (not necessarily today), but this new branch always formats the session eco line with the environmental_impact_*_today copy. That makes the environmental row claim “Today” even when the data is from an older day, which is a user-visible accuracy regression specific to Bedrock and inconsistent with the existing sessionLine logic that already uses a billing-day label.
Useful? React with 👍 / 👎.
|
I'd love to see screenshots + sources for the calculation. Not completely opposed, but must be correct. |
|
ClawSweeper PR egg 🎁 Pass real behavior proof to wake the egg and unlock a hatchable treat. Where did the egg go?
|
Adds an environmental estimate section to the menu card, extracts shared UI, and keeps the estimates clearly labeled as rough approximations. Includes localization updates and focused tests.