Skip to content

fix: group Antigravity models and refresh effort choices - #34518

Merged
brennanb2025 merged 12 commits into
mainfrom
brennanb2025/antigravity-model-effort-33448
Oct 29, 2026
Merged

brennanb2025 merged 12 commits into
mainfrom
brennanb2025/antigravity-model-effort-33448

Conversation

@brennanb2025

@brennanb2025 brennanb2025 commented Oct 27, 2026 •

Copy link
Copy Markdown
Contributor
Files Added Deleted Net
Test 7 $\color{#1a7f37}{\Huge{\mathbf{+}}}$​989 $\color{#cf222e}{\Huge{\mathbf{−}}}$​82 $\color{#1a7f37}{\Huge{\mathbf{+}}}$​907
Prod 19 $\color{#1a7f37}{\Huge{\mathbf{+}}}$​1372 $\color{#cf222e}{\Huge{\mathbf{−}}}$​97 $\color{#1a7f37}{\Huge{\mathbf{+}}}$​1275

The problem

Antigravity Chat listed thinking levels as separate models and had no separate Effort choice. The official server now advertises grouped models with different effort choices for each model. Saved selections and delayed provider replies also need to remain usable when that model list changes.

What changes

  • Updates the managed Antigravity server to 1.4.3 on all four supported platforms.
  • Takes model groups and effort menus from the provider, refreshing the dependent menu when the model changes.
  • Preserves older saved model IDs and explicit effort selections without guessing from model names.
  • Acknowledges saved picks promptly, applies model and effort before a captured prompt, and bounds optional refresh work while preserving cancellation and native-session ownership.

Model and effort choices remain provider-authoritative. Intended: successful native control responses establish the applied selection, using the exact input sent; later model observations cannot override that success or overwrite saved intent. Intended: explicit effort requests reach the provider rather than silently being skipped. Existing desktop, phone and remote formats remain compatible; no new setting, persisted field or wire operation is added.

Intended: A message that genuinely omits effort keeps the running conversation’s effort. Saving a model choice retains any explicit saved effort; the provider decides whether it can apply that effort.

Intended: A chat saved on an older Antigravity runtime with a model the new runtime no longer lists keeps showing that model's exact ID, same as main; picking the listed Flash model restores the effort menu.

Verification

  • The first main reconciliation passed 177 tests in 13 root files and 26 mobile tests (203 total); the follow-up conflict merge passes 175 distinct affected tests across nine root and two mobile files. The required merge pre-commit checks pass. Test-only commits 92317ac and bc7c472 add Antigravity to two extracted fixture type declarations and make a control stub return the required empty protocol response; both normal hooks pass, the declaration repair has identical type-erased runtime output, and the affected option test file passes all 12 tests.
  • Historical before-fix runs reproduce unknown effort menus, action admission and unbounded optional work. Current production-host tests preserve literal saved effort through a model change, reach an actual rejected control without sending the failed prompt, then complete a corrective supported Send. They also cover captured FIFO Sends, legitimate wakes, native retirement and one bounded menu-read join.
  • All four official release archives and their eight executable members match the pinned hashes and sizes. The JSON fixture contains official-schema-shaped provider data; it does not prove account access, an authenticated cross-model capture or real replies.
  • CI is green on bc7c472, including static analysis/typecheck, Mobile verify, all ten test shards, wire compatibility, persistence, Linux/Windows packaging, three WSL distributions and the PR checks gate. Shard 8’s first attempt hit an inherited command-population fixture ordering race tracked in test: stabilize command-population admission order #36111. That main test is unchanged here; the failed-job-only retry passed without a production change.
  • Independent correctness, whole-mechanism reference, performance and readiness-source review accepts merges 59b0729 and 6770d7f. Accepted real-run evidence from a41b31af carries across both main merges and test-only commits 92317ac and bc7c472 under the staleness rule. A signed-in Antigravity chat was saved on the previous build, upgraded through the normal runtime update to 1.4.3, and received two real replies on this branch. A native effort write to Low succeeded before the first provider prompt; the second reply needed no effort repair.
  • Antigravity model switch not exercised: every QA sign-in offers only one model (gemini-3.8-flash), so the model-change request and the menu refresh for a different model couldn't run for real.
  • Shared Claude and Codex upgrade flows pass: the previous build’s chats and native session identities were preserved, actual UI model/effort picks were accepted, and each received two real branch replies. Codex’s second response took about 5m34s; its original completed reply was verified in persisted history and the UI without resending.
  • The shipping native iOS Simulator controls show one grouped Flash model and separate Low/Med/High effort choices; an actual Low tap is visibly selected. This is control presentation proof. Its earlier single setup reply used runtime1.3.0 and does not prove runtime1.4.3 applied Low; the desktop write/real-reply trace supplies that proof. Cross-model switching remains unexercised as stated above.

Visual proof

Previous build Grouped model and separate effort choices
Previous build showing the saved concrete model Branch showing one model group with Low, Med and High effort

The same saved chat after two successful branch replies:

Antigravity branch replies with Flash and Low selected

Preserved shared-agent chats after model/effort selections and two successful branch replies each:

Claude Codex
Claude baseline and two branch replies with Opus Low Codex baseline and two original branch replies with GPT-6.1-Sol Low

Native iOS Simulator control presentation (the visible reply predates the runtime1.4.3 setup upgrade):

Native phone grouped model Native phone per-model effort
phone-native-model.jpg phone-native-effort.jpg

Tracked in STA-12093. Thanks to @gentslava for the original contribution. Supersedes #33448 and retains the contributor's commits and authorship; #33448 remains open.

@brennanb2025
brennanb2025 marked this pull request as ready for review October 28, 2026 14:58
@coderabbitai

coderabbitai Bot commented Oct 28, 2026 •

Copy link
Copy Markdown
Contributor

Review in Change Stack →

Note

Reviews paused

It looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the reviews.auto_review.auto_pause_after_reviewed_commits setting.

Use the following commands to manage reviews:

  • @coderabbitai resume to resume automatic reviews.
  • @coderabbitai review to trigger a single review.

Use the checkboxes below for quick actions:

  • ▶️ Resume reviews
  • 🔍 Trigger review
Walkthrough

ACP model and effort option handling now tracks uncertain writes and uses updated effort-menu rules. Structured session option mutations can confirm eligible idle updates through an ordered delivery cycle. Live option reads can wait for that cycle before reading current options. The changes also add Antigravity and OpenCode protocol fixtures, update the Antigravity runtime pin, and add tests for model selection, delayed responses, delivery ordering, and option reads.

Priority: Normal

Merge Risk: Minimal · up to 59b07

This change groups Antigravity models, refreshes effort choices when the model changes, and tracks uncertain option writes. No actionable merge-blocking risk was identified in the supplied context. Normal CI on the reconciled head is still pending, per the PR description.

Pre-merge checks: Passed 4 · Failed 1

Failed Failed checks: 1 warning

Check name Status Explanation Resolution
Docstring Coverage Warning Docstring coverage is 60.00% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff with cyclomatic complexity of at least 2. Documenta… Write docstrings for the functions missing them to satisfy the coverage threshold.
Passed Passed checks: 4 passed
Check name Status Explanation
Title check Passed The title clearly and concisely describes the main change: grouping Antigravity models and refreshing effort choices.
Linked Issues check Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check Passed Check skipped because no linked issues were found for this pull request.
Description check Passed The description is detailed and covers the problem, implementation, rationale, verification, limitations, compatibility, and visual proof. It does not follow the template headings exactly and uses “ST…
Full details: Description check

Explanation

The description is detailed and covers the problem, implementation, rationale, verification, limitations, compatibility, and visual proof. It does not follow the template headings exactly and uses “STA-12093” instead of a “Fixes #...” issue reference, but the required decision-making information is substantially present.

Full details: Docstring Coverage

Explanation

Docstring coverage is 60.00% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff with cyclomatic complexity of at least 2. Documentation-only edits and deletions within surviving functions are included; unchanged diff context and fully deleted functions are excluded. Analyzed 5 functions across 21 files.

Resolution

Write docstrings for the functions missing them to satisfy the coverage threshold.

Finishing Touches: 💡 1
📝 Generate docstrings: 💡
  • Commit to this branch
  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

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.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Caution

Some comments are outside the diff and can’t be posted inline due to GitHub limitations.

⚠️ Outside diff range comments (1)

Minor · Reread session options after the catalog awaits. · structured-agent-session-option-models.ts:84-106

src/main/native-chat/agent-session-wire/structured-agent-session-option-models.ts:84-106
🎯 Functional Correctness | 🟡 Minor | ⚡ Quick win

Reread session options after the catalog awaits.

recordStructuredAgentSessionOptionIntent can replace the conversation record while readStructuredAgentSessionRestingOptions awaits catalog and proof reads. The at-rest reader then derives model and effort from its earlier saved snapshot. The returned options can show the previous selection instead of the user's current selection.

Keep the initial snapshot for catalog selection, but reread the current record after the final catalog await and use its options for the returned fields.

Suggested fix
   const listedModelIds = proof ? finishedListingIds(proof) : undefined
+  const currentRecord = deps.store.getConversation(sessionId)
+  if (!currentRecord) {
+    throw new Error('agent_session_identity_required')
+  }
+  const currentSaved = currentRecord.options ?? {}
   const defaultModels =
     independentAgentModelCatalog(record.provider) && reader.readsWithoutModel
       ? proof && proof.origin !== 'unknown'
         ? proof.models
         : []
       : models
   const fastMode =
-    saved.fastMode === undefined
+    currentSaved.fastMode === undefined
       ? null
-      : decodeStructuredAgentSessionOptionValue('fastMode', saved.fastMode)
+      : decodeStructuredAgentSessionOptionValue('fastMode', currentSaved.fastMode)
   // Only a real listing confirms account defaults; built-in defaults cannot override client state.
   const model =
-    saved.model ??
+    currentSaved.model ??
     (catalog.origin === 'unknown' ? undefined : models.find((entry) => entry.isDefault)?.id)
   // Prefer saved effort, then live execution or the folder’s matching model default.
   const effort =
-    saved.effort ??
-    (rules?.effortDefaultsToModel || (saved.model === undefined && folderDefault)
+    currentSaved.effort ??
+    (rules?.effortDefaultsToModel || (currentSaved.model === undefined && folderDefault)
       ? defaultModels.find((entry) => entry.id === model)?.defaultEffort
       : undefined)
   const defaulted = (['model', 'effort'] as const).filter(
-    (key) => saved[key] === undefined && Boolean(key === 'model' ? model : effort)
+    (key) => currentSaved[key] === undefined && Boolean(key === 'model' ? model : effort)
   )
-  const serviceTier = savedEffectiveServiceTier(saved, models)
+  const serviceTier = savedEffectiveServiceTier(currentSaved, models)

Review info
Run configuration
  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: Repository UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 12ab668d-2d3e-4011-bebb-0a2592957643
Commits

Reviewing files that changed from the base of the PR and between 24cdd17 and 17d7318.

Files selected for processing: 2
  • src/main/acp/acp-structured-host-model-options.test.ts
  • src/renderer/src/components/native-chat/use-structured-agent-session-options.test.tsx

Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 2 remain after this review.

@greptile-apps

greptile-apps Bot commented Oct 29, 2026 •

Copy link
Copy Markdown

RetriggerView in GreptileConfidence Score: 5/5

[Medium impact] No blocking code issues were found; the author's pending merge reconciliation and CI still need to finish.

Summary

Updates Antigravity to 1.4.3 and uses provider-supplied model groups with separate effort choices.

  • Antigravity chats show grouped models and separate effort choices.
  • Saved model and effort picks reach ACP prompts in order.

brennanb2025 states that reconciliation with newer main and fresh CI remain pending.

Diagram

sequenceDiagram
  participant Client
  participant Host
  participant Provider
  Client->>Host: Save model choice
  Host-->>Client: Acknowledge saved choice
  opt Ready and idle
    Host->>Provider: Apply model
    Provider-->>Host: Return current options
  end
  Client->>Host: Send captured prompt
  Host->>Provider: Apply captured model and effort
  Host->>Provider: Send prompt
Loading

Reviews (1) · Last reviewed commit: "Merge main and reconcile native session ..." · Reviewed by Greptile

@brennanb2025

Copy link
Copy Markdown
Contributor Author

Antigravity Chat showed thinking levels as separate models and had no separate Effort choice. This PR updates all four managed runtime artifacts to 1.4.3, uses the provider’s grouped models and per-model effort menus, and preserves older saved selections through the update.

The full review reached four logical rounds and fixed unknown-menu handling, saved-selection handling, action admission during optional metadata work, and unbounded optional refresh work. Main reconciliation preserves literal model/effort input, sparse messages inherit native effort, and correlated control success establishes applied input independently of readback. Provider observations cannot overwrite saved intent. No new setting, saved field, or wire operation is added. A hypothetical wrong-model success response remains deferred because no official-provider counterexample was found; the implementation trusts correlated successful responses.

Verification: the first main reconciliation passed 203 targeted tests; the follow-up conflict merge 6770d7f passes 175 distinct affected tests, plus the required merge pre-commit check. Independent merge correctness, whole-mechanism reference, performance and readiness-source review is complete; CI is green on bc7c472, including static analysis/typecheck, Mobile verify, all ten test shards, wire compatibility, persistence, Linux/Windows packaging, three WSL distributions and the PR checks gate. Shard 8’s first attempt hit an inherited command-population fixture ordering race tracked in #36111. That main test is unchanged here; the failed-job-only retry passed without a production change. Accepted QA ran on a41b31a and carries across main merges 59b0729 and 6770d7f under the staleness rule; test-only commits 92317ac and bc7c472 repair two fixture type declarations and an empty control response. Both normal hooks pass; the declaration repair has identical type-erased runtime output and the affected option test file passes all 12 tests. Antigravity baseline-to-branch upgrade and two real branch replies are verified: the native Low effort write completed before the first provider prompt, and the second reply required no effort repair. Shared Claude and Codex preserved their previous-build chats/native session identities, accepted actual UI model/effort choices and each received two real branch replies. Codex’s second reply took about 5m34s; its original completed response was verified in history and UI without resending.

Antigravity model switch not exercised: every QA sign-in offers only one model (gemini-3.8-flash), so the model-change request and the menu refresh for a different model couldn't run for real. Existing production-host tests consume official-schema-shaped provider success payloads and assert the target model’s returned Low/High effort menu before any prompt; this is test coverage, not a real model-switch pass.

Intended: A chat saved on an older Antigravity runtime with a model the new runtime no longer lists keeps showing that model's exact ID, same as main; picking the listed Flash model restores the effort menu.

For Brennan’s review:

Previous build Grouped model and effort menu
Concrete saved model Grouped Flash with Low, Med and High effort

Preserved chat with two successful branch replies and Flash/Low selected

Agent Previous build Same chat after two branch replies
Claude Claude previous build Claude preserved chat with Opus Low
Codex Codex previous build Codex preserved chat with GPT-6.1-Sol Low

Source judgments: native menu authority; raw control success and uncertain ownership; one join then current serialized read.

Native iOS Simulator control presentation was exercised on this branch: one grouped Flash row, separate Low/Med/High choices, and Low visibly selected after a real tap. The existing PHONE3185_OK transcript predates the setup upgrade to 1.4.3 and is not provider-effort acknowledgement. Desktop native write/real-reply evidence establishes provider application. No physical-device or iOS 15 lifecycle claim is made.

Native phone grouped model Native phone per-model effort
phone-native-model.jpg phone-native-effort.jpg

@brennanb2025
brennanb2025 merged commit 00de405 into main Oct 29, 2026
77 of 79 checks passed
@brennanb2025
brennanb2025 deleted the brennanb2025/antigravity-model-effort-33448 branch October 29, 2026 23:22
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.

2 participants