[feature]: Antigravity v2 support (Gemini CLI quota merging, rate-limit overrides, GPT-OSS)
Pre-flight checks
- [x] I searched existing issues and did not find a duplicate request.
- [x] I reviewed current behavior on the production released OpenCode version.
OpenCode version reviewed
1.2.24
Problem statement
The Google Antigravity provider currently lacks support for newer models and features available in the Gemini CLI v2 API. Users with multiple Google accounts and newer models (Gemini 3.1 Pro, Claude Sonnet 4.6, GPT-OSS) see incomplete or inaccurate quota data.
Proposed change
Add the following features to the Antigravity provider:
-
Gemini CLI quota merging: Fetch cloudcode-pa.googleapis.com/v1internal:retrieveUserQuota for more accurate rate-limit data and merge with standard Antigravity etchAvailableModels results.
-
Rate-limit overrides: Apply local ateLimitResetTimes from ~/.config/opencode/antigravity-accounts.json account entries. When a model is temporarily rate-limited (e.g., ateLimitResetTimes: { "claude": 1234567890 }), show 0% remaining and the correct reset time.
-
GPT-OSS support: Add gpt-oss-120b-medium model key to GOOGLE_MODEL_KEYS and GoogleModelId union.
-
Provider grouping improvements: Group Antigravity entries by displayName with explicit label and classicStrategy: "preserve" for cleaner sidebar output.
Alternatives considered
Keeping these as local .js patches only, but they would be useful for all Antigravity users.
Acceptance criteria
- [ ] queryGoogleQuota calls etrieveUserQuota and merges results
- [ ] ateLimitResetTimes in account config is respected
- [ ] GPT-OSS appears in quota output when configured
- [ ] Antigravity entries are grouped by model name in sidebar