Skip to content

feat: hide untouched Antigravity model families - #2875

Open
urda wants to merge 1 commit into
steipete:mainfrom
urda-forks:agy/upgrades
Open

feat: hide untouched Antigravity model families#2875
urda wants to merge 1 commit into
steipete:mainfrom
urda-forks:agy/upgrades

Conversation

@urda

@urda urda commented Aug 12, 2026

Copy link
Copy Markdown
Contributor

Problem

Antigravity's RetrieveUserQuotaSummary reports every model family the plan
covers, not just the ones the account uses. An account that only runs Gemini
still receives a Claude/GPT group, so the menu card, the provider settings
Usage list, and the widget each carry two rows pinned at 0% used that will never
move. On a small widget, where the row limit is 2, those dead rows can crowd out
the lanes that matter.

Fix

Hide a model family once no lane in it reports known usage above zero.

Hiding is per family, never per lane, so a family in use keeps its full 5-hour
and weekly pair even when one of them happens to sit at zero. That matters every
week: a weekly lane resets to 0% while the 5-hour lane is still active, and
per-lane hiding would drop the weekly row until the next call.

When every family is untouched, nothing hides, so the card never renders empty.
An "unavailable" lane (bucket disabled, or no remainingFraction) counts as
not used.

AntigravityQuotaFamilyVisibility in CodexBarCore owns the rule so the menu
card and the widget cannot drift apart. Family grouping uses the bucket ID first
(gemini, 3p, third-party), which matches the widget's existing row
resolver, because the ID survives a display-text change. A group with neither
signal uses the rendered title without its 5-hour or weekly suffix, so an
unfamiliar family still pairs its lanes.

Provider settings opts out through a new showsAllUsageLanes flag on the card
model input, set at exactly one call site. It is the diagnostic surface and
always lists every family, the same principle the pane already applies to cost
data:

Display style only controls the main menu. Provider details always expose
available cost data in their Usage section.

The change is display-only. The snapshot, CLI output, and diagnostics still
carry every window. Menu-bar text and icon selection rank by highest used, so an
untouched family never won there anyway, and quota warnings fire on low
remaining, so an untouched family never triggered one. No new setting: no
UserDefaults key, no provider config field, no sync field, no toggle. The rule
is computed from the snapshot at render time.

Behavior

Case Gemini Claude/GPT
both used shown shown
Gemini used only shown hidden
Claude/GPT used only hidden shown
neither used shown shown
Surface both used one used neither used
Menu card both the used one both
Widget rows both the used one both
Provider settings both both both

Screenshots

Menu card, both usage-bar modes.

Case Percent used Percent left
both used antigravity-01-both-used-percent-used antigravity-01-both-used-percent-left
Gemini used only antigravity-02-gemini-only-percent-used antigravity-02-gemini-only-percent-left
Claude/GPT used only antigravity-03-claude-gpt-only-percent-used antigravity-03-claude-gpt-only-percent-left
neither used antigravity-04-neither-used-percent-used antigravity-04-neither-used-percent-left

Provider settings, same payload as the Gemini-only row above, showing all four
lanes.

Surface Percent used Percent left
Settings Usage section antigravity-settings-gemini-only-percent-used antigravity-settings-gemini-only-percent-left

Every image above is the real SwiftUI view rendered through ImageRenderer from
a synthetic snapshot. No account data.

Side benefit

The Antigravity widget row limit is 2 on small and 3 on medium
(AntigravityProviderDescriptor.swift). With four lanes the medium widget
truncated the last row. With the untouched family gone, both Gemini lanes fit.

Proof

  • Green: swift test --filter "MenuCardAntigravityTests|UsageStoreWidgetSnapshotTests" — 27/27 tests.
  • Green: swift test --filter ProviderArchitectureGatekeeperTests — 38/38 tests.
  • Green: make test — 70/70 groups, 840 selections.

New cases cover hiding an untouched family, hiding a family whose only known
lane is untouched, keeping every family when all are untouched, provider
settings keeping every family, and the widget dropping untouched families.

The allowlist in ProviderArchitectureGatekeeperTests pins exact line numbers,
so inserting lines into MenuCardView+ModelHelpers.swift shifted five anchors.
Those entries move by three; anchors, provider sets, reference counts, and
fingerprints are unchanged. The new CodexBarCore file also carries a
Provider-specific by design: marker, since the scanner reads the gemini and
claude string literals in the family match as provider references.

@clawsweeper

clawsweeper Bot commented Aug 12, 2026

Copy link
Copy Markdown

🦞👀
ClawSweeper picked this up.

Pull request received. I will update this pull request when review starts.

@urda
urda marked this pull request as ready for review August 12, 2026 00:21
@urda

urda commented Aug 12, 2026

Copy link
Copy Markdown
Contributor Author

@clawsweeper ready

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: da5ede2283

ℹ️ About Codex in GitHub

Codex has been enabled to automatically 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 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".

@clawsweeper clawsweeper Bot added merge-risk: 🚨 compatibility 🚨 Merging this PR could break existing users, config, migrations, defaults, or upgrades. P2 Normal priority bug or improvement with limited blast radius. proof: 📸 screenshot Contributor real behavior proof includes screenshot evidence. proof: sufficient Contributor real behavior proof is sufficient. rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. status: ⏳ waiting on author ClawSweeper has contributor-facing work open and is waiting for author action. labels Aug 12, 2026
@clawsweeper

clawsweeper Bot commented Aug 12, 2026

Copy link
Copy Markdown

Codex review: needs maintainer review before merge. Reviewed August 12, 2026, 11:36 PM ET / August 13, 2026, 03:36 UTC.

ClawSweeper review

What this changes

Filters Antigravity quota families with no known usage from menu cards and widgets while keeping all reported lanes in provider settings.

Merge readiness

⚠️ Ready for maintainer review - 2 items remain

Keep open for a maintainer product decision. The implementation is scoped and appears correct, but it intentionally changes menu-card and widget semantics from complete plan inventory to curated active-usage views.

Priority: P2
Reviewed head: ba47389d0392cd7cfd5abf5eb5d40d06e547402a
Owner decision: Required. See Decision needed.

Review scores

Measure Result What it means
Overall readiness 🦞 diamond lobster (5/6) The implementation is focused, well-covered, and directly demonstrated; the remaining blocker is product acceptance rather than patch quality.
Proof confidence 🦞 diamond lobster (5/6) ✨ media proof bonus Sufficient (screenshot): Rendered SwiftUI screenshots directly show the changed menu-card and provider-settings states, supplemented by reported focused and full-suite validation.
Patch quality 🦞 diamond lobster (5/6) No actionable review findings were identified.

Verification

Check Result Evidence
Real behavior Verified Sufficient (screenshot): Rendered SwiftUI screenshots directly show the changed menu-card and provider-settings states, supplemented by reported focused and full-suite validation.
Evidence reviewed 6 items Current main does not contain this behavior: The current main revision has no Antigravity family-visibility helper or all-lanes presentation flag, so the PR’s central behavior is not already implemented.
Authoritative quota shape: Current provider documentation describes the quota-summary payload as Gemini and Claude/GPT groups with weekly and five-hour lanes.
Shared display rule: The PR groups quota-summary windows, retains all families when every family is untouched, and returns IDs only for idle families.
Findings None None.
Security None None.

How this fits together

Antigravity quota snapshots feed CodexBar’s menu card, widget snapshot, and provider-settings usage view. The PR adds a shared family-level display filter between quota parsing and the curated presentation surfaces.

flowchart LR
A[Antigravity quota snapshot] --> B[Quota family grouping]
B --> C{Any family has usage?}
C -->|Yes| D[Hide idle families]
C -->|No| E[Keep all families]
D --> F[Menu card and widget]
E --> F
A --> G[Provider settings]
G --> H[Show every lane]
Loading

Decision needed

Question Recommendation
Should Antigravity menu cards and widgets become curated active-usage views that hide untouched plan families while provider settings remains the complete quota inventory? Accept curated display: Merge the behavior with provider settings as the documented complete inventory for all reported quota lanes.

Why: The patch is technically coherent, but the visibility change is a user-facing presentation policy with no maintainer approval in the discussion.

Before merge

  • Resolve merge risk (P1) - Merging intentionally removes untouched plan-family rows from existing menu and widget views; users who use those surfaces as complete plan inventories must use provider settings instead.
Agent review details

Security

None.

Review metrics

Metric Value Why it matters
Production and test delta production +66/-2; tests +415/-5; docs/release notes +9 Most of the growth is focused regression coverage for menu and widget family-pairing behavior.

Merge-risk options

Maintainer options:

  1. Accept the curated view (recommended)
    Merge with the explicit understanding that provider settings, rather than the menu or widget, is the complete quota inventory.
  2. Retain complete menu inventory
    Pause or close the PR if untouched covered families must remain visible in every existing presentation surface.

Technical review

Best possible solution:

If the curated-display policy is accepted, retain the shared family filter and the provider-settings complete-inventory escape hatch exactly as implemented.

Do we have a high-confidence way to reproduce the issue?

Not applicable: this PR proposes a display-policy change rather than fixing a failing current behavior; its rendered before/after scenarios are supplied as proof.

Is this the best way to solve the issue?

Yes conditionally: one core filter shared by menu and widget, with provider settings retaining all lanes, is the narrowest maintainable implementation if maintainers accept the curated-display policy.

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning high; reviewed against 208016687098.

Labels

Label justifications:

  • P2: This is a bounded presentation-policy change with limited impact to Antigravity users.
  • merge-risk: 🚨 compatibility: Existing menu and widget views will no longer always show every quota family covered by an account plan.
  • rating: 🦞 diamond lobster: Overall readiness is 🦞 diamond lobster; proof is 🦞 diamond lobster and patch quality is 🦞 diamond lobster.
  • status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR. Sufficient (screenshot): Rendered SwiftUI screenshots directly show the changed menu-card and provider-settings states, supplemented by reported focused and full-suite validation.
  • proof: sufficient: Contributor real behavior proof is sufficient. Rendered SwiftUI screenshots directly show the changed menu-card and provider-settings states, supplemented by reported focused and full-suite validation.
  • proof: 📸 screenshot: Contributor real behavior proof includes screenshot evidence. Rendered SwiftUI screenshots directly show the changed menu-card and provider-settings states, supplemented by reported focused and full-suite validation.

Evidence

What I checked:

Likely related people:

  • Peter Steinberger: Recent main-branch history covers Antigravity provider parsing and widget snapshot presentation, including the current implementations adjacent to this change. (role: recent area contributor; confidence: high; commits: fc57a317cee4, b43ba3a02c4e, 61fbe9fac507; files: Sources/CodexBarCore/Providers/Antigravity/AntigravityStatusProbe.swift, Sources/CodexBar/UsageStore+WidgetSnapshot.swift)
  • Yuxin Qiao: The feature history attributes the Antigravity quota-summary lane fix and subsequent quota-ranking work to this contributor. (role: introduced quota-summary lane behavior; confidence: high; commits: 388ee1417386, f997ebcb1a16; files: Sources/CodexBarCore/Providers/Antigravity/AntigravityStatusProbe.swift)

Rating scale

Score Internal tier Crab rank Meaning
6/6 S 🦀 challenger crab Exceptional readiness
5/6 A 🦞 diamond lobster Very strong readiness
4/6 B 🐚 platinum hermit Good normal PR; ordinary maintainer review
3/6 C 🦐 gold shrimp Useful, but confidence is limited
2/6 D 🦪 silver shellfish Proof or implementation needs work
1/6 F 🧂 unranked krab Not merge-ready
N/A NA 🌊 off-meta tidepool Rating does not apply

Overall follows the weaker of proof and patch quality.
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.

Workflow

  • ClawSweeper keeps one durable marker-backed review comment per issue or PR.
  • Re-runs edit this comment so the latest verdict, findings, and automation markers stay together instead of adding duplicate bot comments.
  • A fresh review can be triggered by eligible @clawsweeper re-review comments, exact-item GitHub events, scheduled/background review runs, or manual workflow dispatch.
  • PR/issue authors and users with repository write access can comment @clawsweeper re-review or @clawsweeper re-run on an open PR or issue to request a fresh review only.
  • Maintainers can also comment @clawsweeper review to request a fresh review only.
  • Fresh-review commands do not start repair, autofix, rebase, CI repair, or automerge.
  • Maintainer-only repair and merge flows require explicit commands such as @clawsweeper autofix, @clawsweeper automerge, @clawsweeper fix ci, or @clawsweeper address review.
  • Maintainers can comment @clawsweeper explain to ask for more context, or @clawsweeper stop to stop active automation.

History

Review history (9 earlier review cycles; latest 8 shown)
  • reviewed 2026-08-12T01:38:05.630Z sha 3656925 :: needs maintainer review before merge. :: none
  • reviewed 2026-08-12T02:20:20.456Z sha 88f2111 :: needs changes before merge. :: [P2] Preserve unfamiliar quota-family pairs
  • reviewed 2026-08-12T05:50:44.485Z sha b472564 :: needs maintainer review before merge. :: none
  • reviewed 2026-08-12T08:23:17.227Z sha ed51572 :: needs maintainer review before merge. :: none
  • reviewed 2026-08-12T15:25:44.104Z sha 04e0cd5 :: needs maintainer review before merge. :: none
  • reviewed 2026-08-12T21:41:49.431Z sha 26c014f :: found issues before merge. :: [P2] Record the change in the unreleased section
  • reviewed 2026-08-12T21:49:02.004Z sha f67c60d :: needs maintainer review before merge. :: none
  • reviewed 2026-08-12T22:50:33.927Z sha f67c60d :: needs maintainer review before merge. :: none

@clawsweeper clawsweeper Bot added rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR. and removed status: ⏳ waiting on author ClawSweeper has contributor-facing work open and is waiting for author action. rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. labels Aug 12, 2026
@urda

urda commented Aug 12, 2026

Copy link
Copy Markdown
Contributor Author

@steipete Like a lot of agy users I only really use gemini, this helps "streamline" the UI.

@clawsweeper clawsweeper Bot added rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. status: ⏳ waiting on author ClawSweeper has contributor-facing work open and is waiting for author action. and removed status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR. rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. labels Aug 12, 2026
@clawsweeper clawsweeper Bot added rating: 🦞 diamond lobster Very strong PR readiness with only minor maintainer review expected. status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR. and removed status: ⏳ waiting on author ClawSweeper has contributor-facing work open and is waiting for author action. rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. labels Aug 12, 2026
@clawsweeper clawsweeper Bot added rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. and removed rating: 🦞 diamond lobster Very strong PR readiness with only minor maintainer review expected. labels Aug 12, 2026
@clawsweeper clawsweeper Bot added rating: 🦞 diamond lobster Very strong PR readiness with only minor maintainer review expected. and removed rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. labels Aug 12, 2026
@clawsweeper clawsweeper Bot added rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. status: ⏳ waiting on author ClawSweeper has contributor-facing work open and is waiting for author action. and removed rating: 🦞 diamond lobster Very strong PR readiness with only minor maintainer review expected. status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR. labels Aug 12, 2026
@clawsweeper clawsweeper Bot added status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR. and removed status: ⏳ waiting on author ClawSweeper has contributor-facing work open and is waiting for author action. labels Aug 12, 2026
Drop a quota family from menu cards and widgets when no lane reports known usage;
keep every family when all are untouched;
pair an unfamiliar family's lanes by title so a reset lane never hides beside an active sibling;
keep provider details listing every family as the diagnostic surface.
@clawsweeper clawsweeper Bot added rating: 🦞 diamond lobster Very strong PR readiness with only minor maintainer review expected. and removed rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. labels Aug 13, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

merge-risk: 🚨 compatibility 🚨 Merging this PR could break existing users, config, migrations, defaults, or upgrades. P2 Normal priority bug or improvement with limited blast radius. proof: 📸 screenshot Contributor real behavior proof includes screenshot evidence. proof: sufficient Contributor real behavior proof is sufficient. rating: 🦞 diamond lobster Very strong PR readiness with only minor maintainer review expected. status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant