Repository navigation
Add Gemini to Ask AI via Antigravity subscription or API key - #109
Merged
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
Ask AI supports ChatGPT, Claude, OpenRouter, and custom endpoints, so people who want to use Gemini (#102) have no built-in way to connect either their Google AI / Antigravity subscription or a Gemini API key.
Change
agy): locates the user's own, unmodified Antigravity CLI (agy) across standard macOS, Linux, and Windows install folders (ignoring relativePATHentries and Windows.cmd/.batshims), lists available plan models, and streams answers overstdin/stdoutNDJSON inside a private temporary folder with tools, commands, MCP servers, skills, plugins, and slash commands disabled. Folio never sees or stores Google credentials.x-goog-api-keyheader only), stores keys only with operating-system encryption (safeStorage), fetches and filters compatiblegenerateContentmodels, and streams answers with page citations, Stop cancellation, and passage-only scoping.scripts/test-agy.cjs,scripts/test-gemini.cjs), updated the Electron smoke tests (scripts/smoke-test.mjs,scripts/smoke-gemini.mjs), CI workflow (.github/workflows/ci.yml), and documentation (README.md,SECURITY.md).Issue or approval
Closes #102 (maintainer request).
How I checked it
darwin):npx tsc --noEmitnpm audit --audit-level=highnode --test scripts/test-agy.cjs scripts/test-gemini.cjs scripts/test-openrouter.cjs scripts/test-custom-endpoint.cjs scripts/test-claude-path.cjs(34/34 passed)npm test(all 17 Vitest suites passed)npm run buildnpm run test:reader-securityandnpm run smoke(including Antigravity + Gemini API key smoke flows and print checks)npm run test:chat-math,npm run test:thumbnails, and remainingscripts/test-*.{cjs,mjs}suitesagy 1.5.18)Implemented with Gemini 4 Neon in T3 Code.