Port upstream 0.70.0: Antigravity Gemini 3.1 Pro pricing aliases (stacked on #706) - #732
Conversation
Port the Antigravity half of upstream CodexBar 0.70.0 steipete#4094: gemini-pro-default, gemini-pro-agent and the gemini-3.1-pro effort tiers price as gemini-3.1-pro-preview, after the exact recorded model and before routing-suffix bases. The alias stays provider-local, recorded model names stay unchanged, and an unpriced alias also refreshes the catalogued preview row.
|
Important Review skippedAuto reviews are disabled on base/target branches other than the default branch. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Advanced Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
Adversarial validation passed at a49d1b5 Scope: Antigravity Gemini 3.1 Pro pricing aliases (#732, upstream 0.70.0 steipete#4094/8466920937, audit row 5a), validated as merged into release/v0.70.0 (merge a49d1b5 = merge of 77dc904 into 8a8f3f5). Attacks (against the 0.70.0 audit behavior spec, audit-0.70.0.md row 5a):
No defects found. READY for the un-draft rule. |
Summary
Antigravity records Gemini 3.1 Pro under product aliases and effort tiers (
gemini-pro-default,gemini-pro-agent,gemini-3.1-pro,gemini-3.1-pro-high,gemini-3.1-pro-low, and suffixed forms such asgemini-3.1-pro-thinking). None of these names is a catalogued model, so this history stayed unpriced. These rows now get list-price estimates fromgemini-3.1-pro-preview, the only catalogued Gemini 3.1 Pro row.-tiered/-low/-thinkingrouting variant resolved through the same alias table.Gemini-Pro-Default).rust/src/providers/antigravity/cost.rs). Shared Claude/models.dev pricing still reports unknown variants as unpriced.LocalCostEstimate::unpriced_modelskeeps the recorded name. An unpriced alias also addsgoogle/gemini-3.1-pro-previewto the bounded models.dev refresh that Port upstream 0.64.0: Antigravity cost follow-ups - lower bounds, withheld reads, --refresh (stacked on #610) #706 introduced.Stacked on #706 (
port/micro-0.64.0-antigravity-cost-followups) rather than #610, because #706 rewrites the samecost.rs(refresh targets) and thedocs/CLI.mdAntigravity paragraph. Merge after #706.Upstream reference
84669209372e4871be073d8a0c62d01cd0cb82c5), Antigravity half only:AntigravityLocalReader.pricingBaseModelID(for:),pricingModelAliases,costUSD(exact model, then base).AntigravityLocalReaderTests(v0.70.0): thepricingBaseModelIDexpectations (gemini-3.8-flash-tiered,gemini-3.1-pro-low,claude-opus-4-6-thinking,gemini-3.8-flash-> none,-low-> none, the five aliases,Gemini-Pro-Default). Also "gemini pro product aliases price from the catalogued preview model": googlegemini-3.1-pro-previewat input 1 / output 2 / cache read 0.2 USD per million tokens, expected111e-6 + 50 * 0.2e-6 + 37 * 2e-6. Also the shared-target guard (claude-fixture-9-thinkingtargets do not includeclaude-fixture-9).Ported / Deferred
Ported:
pricingModelAliases[base.lowercased()] ?? base).docs/CLI.md, Antigravity cost paragraph).Windows differences:
gemini-pro-default" assertion has no direct counterpart. Its intent is kept: pricing resolves without renaming the recorded model, and unpriced rows keep the recorded name.estimate_cost_usd_withplusModelsDevPricingSnapshot::from_catalog_json_for_tests), using the same built-in-then-routed resolution as production. They never read the per-user models.dev cache.Deferred:
core/cost_pricing.rs) is a separate v0.70.0 backlog item, "Codex Sol cutoff, Cyber rates and daybreak aliases", owned by another lane.Validation
At
77dc904a(inW:\wcb-wt\lane-a, toolchain 1.98.0):cargo +1.98.0 fmt --all --check: passcargo +1.98.0 clippy --workspace --all-targets -- -D warnings: passcargo +1.98.0 test -p codexbar --lib antigravity::cost: 10 passed (5 new)cargo +1.98.0 test -p codexbar: 2252 passed, 0 failed, 1 ignoredcargo +1.98.0 test -p codexbar-desktop-tauri: 478 passed, 1 failed. The failure isbootstrap_payload_exposes_every_provider_variant, the known hardcoded-count drift from Isolate bootstrap payload test from real settings #684 that Make the bootstrap catalog test hermetic (#684) #711 fixes. It is unrelated to this change.Affected areas
rust/src/providers/antigravity/cost.rs: alias table,pricing_base_model, injectableestimate_cost_usd_with, and tests.docs/CLI.md: the Antigravity cost paragraph.UI proof
Not applicable: this is a backend pricing change only, with no UI or locale change. The existing Usage & Spend rendering shows the resulting estimate, which unit tests cover.