fix(antigravity): add missing gemini-3.6-flash pricing rows to ag OAuth pricing (#8290)

release/v3.8.49 already ships the Gemini 3.6 Flash catalog entries
(AGY_PUBLIC_MODELS, ANTIGRAVITY_PUBLIC_MODELS, MODEL_SPECS with
supportsThinking: false — Antigravity still rejects client-supplied
thinking params) via #8013. What was still missing: the `ag` pricing
rows in DEFAULT_PRICING_OAUTH, so getPricingForModel("ag", id)
returned null for the three tiers and cost/quota calculations
silently fell back to $0.

Pricing: $1.50 input / $7.50 output / $0.15 cached per MTok (Google's
2026-07-21 announcement), matching the existing 3.5-flash schedule
shape. Thinking tokens billed at output rate.

Extends the existing pricing-ag-flash-tiers.test.ts (RED-first: all
three tiers failed the "non-null pricing row" assertion before this
change) rather than re-adding the already-shipped catalog/modelSpecs
entries.

Co-authored-by: diegosouzapw <8016841+diegosouzapw@users.noreply.github.com>
This commit is contained in:
Bob.Hou
2026-07-24 10:43:52 -04:00
committed by GitHub
parent 2e355dd0b9
commit 97d948cc9e
2 changed files with 45 additions and 0 deletions

View File

@@ -311,6 +311,33 @@ export const DEFAULT_PRICING_OAUTH = {
reasoning: 27.0,
cache_creation: 4.0,
},
// Gemini 3.6 Flash (released 2026-07-21) - three tier variants like 3.5 Flash
// (see ANTIGRAVITY_PUBLIC_MODELS / MODEL_SPECS which already carry the catalog
// entries). Without these rows, getPricingForModel("ag", id) returns null and
// downstream cost and quota calculations silently fall back to $0.
// Pricing: $1.50 input / $7.50 output / $0.15 cached per MTok. Thinking tokens
// billed at output rate.
"gemini-3.6-flash-low": {
input: 1.5,
output: 7.5,
cached: 0.15,
reasoning: 7.5,
cache_creation: 1.5,
},
"gemini-3.6-flash-medium": {
input: 1.5,
output: 7.5,
cached: 0.15,
reasoning: 7.5,
cache_creation: 1.5,
},
"gemini-3.6-flash-high": {
input: 1.5,
output: 7.5,
cached: 0.15,
reasoning: 7.5,
cache_creation: 1.5,
},
"claude-sonnet-4-6": {
input: 3.0,
output: 15.0,

View File

@@ -37,3 +37,21 @@ test("ag/gemini-pro-agent matches the Gemini 3.1 Pro (High) tier", () => {
assert.equal(p.reasoning, 27.0);
assert.equal(p.cache_creation, 4.0);
});
// Gemini 3.6 Flash (released 2026-07-21) ships three public client IDs in
// ANTIGRAVITY_PUBLIC_MODELS (`open-sse/config/antigravityModelAliases.ts`) and
// MODEL_SPECS (`src/shared/constants/modelSpecs.ts`), but was missing pricing
// rows in `ag` (DEFAULT_PRICING.ag) — cost / quota calculations silently fell
// back to $0. Pricing: $1.50 input / $7.50 output / $0.15 cached per MTok
// (Google's 2026-07-21 announcement). Thinking tokens billed at output rate.
for (const tier of ["low", "medium", "high"]) {
test(`ag/gemini-3.6-flash-${tier} has a non-null pricing row`, () => {
const p = getDefaultPricing().ag[`gemini-3.6-flash-${tier}`];
assert.ok(p, `expected a pricing row for ag/gemini-3.6-flash-${tier}`);
assert.equal(p.input, 1.5);
assert.equal(p.output, 7.5);
assert.equal(p.cached, 0.15);
assert.equal(p.reasoning, 7.5);
assert.equal(p.cache_creation, 1.5);
});
}