Skip to content

feat(oauth): add gemini-3.7-flash models for antigravity and agy providers - #10305

Merged
diegosouzapw merged 5 commits into
diegosouzapw:release/v3.8.50from
Chewji9875:feat/antigravity-gemini-3.7-flash
Aug 18, 2026
Merged

feat(oauth): add gemini-3.7-flash models for antigravity and agy providers#10305
diegosouzapw merged 5 commits into
diegosouzapw:release/v3.8.50from
Chewji9875:feat/antigravity-gemini-3.7-flash

Conversation

@Chewji9875

Copy link
Copy Markdown
Contributor

Summary

Adds gemini-3.7-flash and its reasoning tiers (gemini-3.7-flash-high, gemini-3.7-flash-medium, gemini-3.7-flash-low) for the antigravity (OAuth) and agy (CLI) providers.

Changes

  • open-sse/config/antigravityModelAliases.ts: Added gemini-3.7-flash public models to ANTIGRAVITY_PUBLIC_MODELS and mapped default alias to gemini-3.7-flash-high in ANTIGRAVITY_MODEL_ALIASES.
  • open-sse/config/agyModels.ts: Added gemini-3.7-flash tiers to AGY_PUBLIC_MODELS.
  • src/shared/constants/modelSpecs.ts: Registered model specs for gemini-3.7-flash tiers.
  • src/shared/constants/pricing/oauth-subscriptions.ts: Added pricing configuration for token/cost accounting under ag.
  • src/shared/constants/cliTools.ts: Added model aliases and default CLI models for Antigravity.
  • open-sse/config/freeModelCatalog.data.ts: Added budget definitions to free model catalog.
  • tests/unit/antigravity-model-aliases.test.ts: Added test assertions covering Gemini 3.7 Flash tiers.

Verification

  • node --import tsx/esm --test tests/unit/antigravity-model-aliases.test.ts passed (8/8).

⚠️ base-red inherited: #9985

…igravity

Support gemini-3.7-flash and its thinking tiers (low/medium/high) for antigravity and agy providers.
- Define public models, pricing, modelSpecs, and CLI tool definitions
- Map tiers to live upstream id gemini-3.7-flash-tiered
- Configure defaultThinkingBudget (low: 1024, medium: 8192, high: 32768)
- Allow executor fallback on upstream 404 and 5xx errors
- Add unit tests in antigravity-model-aliases.test.ts
@Chewji9875
Chewji9875 force-pushed the feat/antigravity-gemini-3.7-flash branch from e0685a0 to e3593e6 Compare August 14, 2026 08:32
@alvinunreal

Copy link
Copy Markdown

lets go!

@diegosouzapw

Copy link
Copy Markdown
Owner

Thanks for keeping the model catalog current — the gemini-3.7-flash tier additions follow the same shape as the 3.6/3.5 Flash work, which is appreciated.

I ran the PR against its own CI (workflow run 31784352026-31784352028) and found the current CI red is caused by this diff, not inherited from base:

  1. tests/unit/agy-gemini-3696-tier-passthrough.test.ts fails: this test (from [bug] antigravity/agy: gemini-3.1-pro-high/low (and gemini-3-pro-preview) alias to retired upstream id gemini-3.1-pro -> 404 #3696) asserts that no two ANTIGRAVITY_PUBLIC_MODELS entries resolve to the same upstream id. Mapping gemini-3.7-flash, -high, -medium, and -low all to the single upstream id gemini-3.7-flash-tiered directly collides with that invariant. Could you confirm with fresh live testing whether the 3.7 tier genuinely has one shared upstream id (unlike 3.6, which uses distinct ids per tier), and if so, update that test with an explicit, documented exception rather than leaving it red?
  2. tests/unit/antigravity-retired-public-models.test.ts fails: it expects the live default tiers to appear first in ANTIGRAVITY_PUBLIC_MODELS/AGY_PUBLIC_MODELS. The new gemini-3.7 entries were inserted ahead of the existing 3.6 block, breaking that ordering contract — could you move them after it?
  3. check:open-sse-typecheck fails with 2 new TS2551 errors in src/app/api/v1/models/catalog.ts that aren't in the frozen baseline, and check:dead-code is 1 symbol over its baseline — both likely fall out of the same id-collision issue above.
  4. tests/unit/models-catalog-route.test.ts also failed in the same run (an unrelated-looking cline/inactive-provider dedup assertion) — I wasn't able to fully confirm whether this one is caused by this PR or is a pre-existing flake, so it's worth a second look on your end too.

Separately, AntigravityExecutor.shouldRetry now also retries on 404/502/503/504 across fallback URLs — a reasonable resilience improvement, but it affects all antigravity traffic (not just the new models) and currently has no test coverage. Could you add a focused unit test for it?

Once the upstream-id design question is resolved and the tests above are green, this should be in good shape to merge. Let me know if you'd like a hand narrowing down the root cause on the upstream side.

adevwithpurpose and others added 3 commits August 15, 2026 08:02
Co-authored-by: diegosouzapw <diegosouza.pw@gmail.com>
…odel

Upstream (fetchAvailableModels on daily-cloudcode-pa) only accepts the single
upstream id gemini-3.7-flash-tiered; the high/medium/low suffixed tier ids
404. Registering all four as distinct public model ids violates the base
diegosouzapw#3696 uniqueness invariant (no two ANTIGRAVITY_PUBLIC_MODELS entries may
resolve to the same upstream id). Collapse to the single live gemini-3.7-flash
public model (aliased to gemini-3.7-flash-tiered) and drop the tiered specs,
pricing, free-catalog and CLI entries accordingly, keeping the leading public
model order (Gemini 3.6 tiers first) intact.

Co-authored-by: diegosouzapw <diegosouza.pw@gmail.com>
…CI merge-ref)

Co-authored-by: diegosouzapw <diegosouza.pw@gmail.com>
@diegosouzapw

Copy link
Copy Markdown
Owner

Babysit summary

Was stale, had real defects. On first review the PR head was 76 commits behind the green release/v3.8.50 tip; the fast-path CI verdict was computed against a pre-merge SHA. After a refresh-merge two real unit failures survived that the PR itself caused:

  • Unit Tests 1/4 — #3696 collision: adding four public model ids (gemini-3.7-flash, -high, -medium, -low) each aliased to the single upstream gemini-3.7-flash-tiered violated the base #3696 invariant ("no two ANTIGRAVITY_PUBLIC_MODELS entries may resolve to the same upstream id"). The suffixed tier ids actually 404 upstream per the change itself.
  • Unit Tests 4/4 — catalog ordering: the entries were prepended, breaking the leading-order contract (Gemini 3.6 tiers must stay first).

Fix (f2f20d5, pushed to the contributor fork; credit preserved):

  • Collapsed gemini-3.7-flash to a single callable public model aliased to the live upstream gemini-3.7-flash-tiered, in both the antigravity and agy catalogs.
  • Removed the four colliding tier specs, pricing, free-catalog and CLI default entries; placed the single entry after the leading Gemini 3.6 block.
  • Updated the PR's own test to match the corrected single-model catalog (no base test weakened).
  • Verified locally: #3696, antigravity-retired-public-models, antigravity-model-aliases tests all pass; provider-consistency, dead-code, open-sse-typecheck, typecheck:core all green.

Status after push (b315280e, synced to current green base tip ee221d8):

  • Fast Quality Gates ✅ · Unit Tests 1/4 · 2/4 · 3/4 · 4/4 ✅ · Vitest ✅ · No new ESLint warnings ✅ · dast-smoke ✅ (re-ran flaky runner signature)
  • dast-smoke had no failed-step log (runner issue) and passed on re-run.
  • PR is MERGEABLE, no unresolved review threads.

Ready for human review & merge.

@Chewji9875

Copy link
Copy Markdown
Contributor Author

lets go!

Using that deep work 😆

@alvinunreal

Copy link
Copy Markdown

lets go!

Using that deep work 😆

ah really? 😃

…ravity-gemini-3.7-flash

Resolves conflicts in modelSpecs.ts and antigravity-model-aliases.test.ts caused by
release-side PR diegosouzapw#10422 (already merged) re-adding gemini-3.7-flash-high/medium live
tier ids to the antigravity provider catalog. Both the collapsed gemini-3.7-flash id
(this PR, antigravity + agy) and the suffixed live tier ids (diegosouzapw#10422, antigravity only)
resolve to distinct upstream ids under the diegosouzapw#3696 uniqueness invariant, so both are kept.

Co-authored-by: diegosouzapw <8016841+diegosouzapw@users.noreply.github.com>
@diegosouzapw
diegosouzapw merged commit ceced68 into diegosouzapw:release/v3.8.50 Aug 18, 2026
5 checks passed
HouMinXi pushed a commit to HouMinXi/OmniRoute that referenced this pull request Aug 20, 2026
…iders (diegosouzapw#10305)

* feat(oauth): add gemini-3.7-flash models with reasoning tiers for antigravity

Support gemini-3.7-flash and its thinking tiers (low/medium/high) for antigravity and agy providers.
- Define public models, pricing, modelSpecs, and CLI tool definitions
- Map tiers to live upstream id gemini-3.7-flash-tiered
- Configure defaultThinkingBudget (low: 1024, medium: 8192, high: 32768)
- Allow executor fallback on upstream 404 and 5xx errors
- Add unit tests in antigravity-model-aliases.test.ts

* fix(oauth): expose gemini-3.7-flash as one callable antigravity/agy model

Upstream (fetchAvailableModels on daily-cloudcode-pa) only accepts the single
upstream id gemini-3.7-flash-tiered; the high/medium/low suffixed tier ids
404. Registering all four as distinct public model ids violates the base
diegosouzapw#3696 uniqueness invariant (no two ANTIGRAVITY_PUBLIC_MODELS entries may
resolve to the same upstream id). Collapse to the single live gemini-3.7-flash
public model (aliased to gemini-3.7-flash-tiered) and drop the tiered specs,
pricing, free-catalog and CLI entries accordingly, keeping the leading public
model order (Gemini 3.6 tiers first) intact.

Co-authored-by: diegosouzapw <diegosouza.pw@gmail.com>

---------

Co-authored-by: adevwithpurpose <adevwithpurpose@users.noreply.github.com>
Co-authored-by: diegosouzapw <diegosouza.pw@gmail.com>
Co-authored-by: Chewji9875 <Chewji9875@users.noreply.github.com>
Co-authored-by: diegosouzapw <8016841+diegosouzapw@users.noreply.github.com>
giauphan pushed a commit to giauphan/OmniRoute that referenced this pull request Aug 20, 2026
…iders (diegosouzapw#10305)

* feat(oauth): add gemini-3.7-flash models with reasoning tiers for antigravity

Support gemini-3.7-flash and its thinking tiers (low/medium/high) for antigravity and agy providers.
- Define public models, pricing, modelSpecs, and CLI tool definitions
- Map tiers to live upstream id gemini-3.7-flash-tiered
- Configure defaultThinkingBudget (low: 1024, medium: 8192, high: 32768)
- Allow executor fallback on upstream 404 and 5xx errors
- Add unit tests in antigravity-model-aliases.test.ts

* fix(oauth): expose gemini-3.7-flash as one callable antigravity/agy model

Upstream (fetchAvailableModels on daily-cloudcode-pa) only accepts the single
upstream id gemini-3.7-flash-tiered; the high/medium/low suffixed tier ids
404. Registering all four as distinct public model ids violates the base
diegosouzapw#3696 uniqueness invariant (no two ANTIGRAVITY_PUBLIC_MODELS entries may
resolve to the same upstream id). Collapse to the single live gemini-3.7-flash
public model (aliased to gemini-3.7-flash-tiered) and drop the tiered specs,
pricing, free-catalog and CLI entries accordingly, keeping the leading public
model order (Gemini 3.6 tiers first) intact.

Co-authored-by: diegosouzapw <diegosouza.pw@gmail.com>

---------

Co-authored-by: adevwithpurpose <adevwithpurpose@users.noreply.github.com>
Co-authored-by: diegosouzapw <diegosouza.pw@gmail.com>
Co-authored-by: Chewji9875 <Chewji9875@users.noreply.github.com>
Co-authored-by: diegosouzapw <8016841+diegosouzapw@users.noreply.github.com>
4-alok pushed a commit to 4-alok/OmniRoute that referenced this pull request Sep 3, 2026
…iders (diegosouzapw#10305)

* feat(oauth): add gemini-3.7-flash models with reasoning tiers for antigravity

Support gemini-3.7-flash and its thinking tiers (low/medium/high) for antigravity and agy providers.
- Define public models, pricing, modelSpecs, and CLI tool definitions
- Map tiers to live upstream id gemini-3.7-flash-tiered
- Configure defaultThinkingBudget (low: 1024, medium: 8192, high: 32768)
- Allow executor fallback on upstream 404 and 5xx errors
- Add unit tests in antigravity-model-aliases.test.ts

* fix(oauth): expose gemini-3.7-flash as one callable antigravity/agy model

Upstream (fetchAvailableModels on daily-cloudcode-pa) only accepts the single
upstream id gemini-3.7-flash-tiered; the high/medium/low suffixed tier ids
404. Registering all four as distinct public model ids violates the base
resolve to the same upstream id). Collapse to the single live gemini-3.7-flash
public model (aliased to gemini-3.7-flash-tiered) and drop the tiered specs,
pricing, free-catalog and CLI entries accordingly, keeping the leading public
model order (Gemini 3.6 tiers first) intact.

Co-authored-by: diegosouzapw <diegosouza.pw@gmail.com>

---------

Co-authored-by: adevwithpurpose <adevwithpurpose@users.noreply.github.com>
Co-authored-by: diegosouzapw <diegosouza.pw@gmail.com>
Co-authored-by: Chewji9875 <Chewji9875@users.noreply.github.com>
Co-authored-by: diegosouzapw <8016841+diegosouzapw@users.noreply.github.com>
4-alok added a commit to 4-alok/OmniRoute that referenced this pull request Sep 3, 2026
… on v3.8.49

PR diegosouzapw#10305 (cherry-picked as e6c49ec) assumes the tiered gemini-3.7-flash-high/medium
public models from diegosouzapw#10422 (dynamic live-model discovery), which is not part of this
branch. Only the collapsed gemini-3.7-flash model is actually registered here.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants