Skip to content

feat: add google gemini provider#31

Merged
jbj338033 merged 3 commits into
mainfrom
worktree-gemini
Jun 9, 2026
Merged

feat: add google gemini provider#31
jbj338033 merged 3 commits into
mainfrom
worktree-gemini

Conversation

@jbj338033

Copy link
Copy Markdown
Collaborator

Summary

Adds goat-provider-gemini, a new provider crate that lets goat connect to Google Gemini models via either a Gemini API key or Google OAuth (Code Assist, gemini-cli compatible).

The provider is split into four modules: lib (Provider trait impl), wire (Gemini request/response format, thinking config, tool schema conversion), oauth (Google PKCE loopback flow with token refresh), and codeassist (Code Assist envelope + loadCodeAssist/onboardUser project onboarding).

Notable behavior: the OAuth path routes to cloudcode-pa.googleapis.com/v1internal (Code Assist backend) and resolves the GCP project via onboarding on first use. The API key path routes to the standard generativelanguage.googleapis.com/v1beta endpoint. Thinking config is model-generation-aware: 2.5 series uses thinkingBudget (integer), 3.x series uses thinkingLevel (enum).

Verification

  • cargo fmt --all --check — passed
  • cargo clippy --workspace --all-targets -- -D warnings — passed
  • cargo test --workspace — passed (24 new unit tests in wire.rs and oauth.rs)

@jbj338033 jbj338033 merged commit 4a6a012 into main Jun 9, 2026
10 checks passed
@jbj338033 jbj338033 deleted the worktree-gemini branch June 9, 2026 11:27
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.

1 participant