Canonical reference for everything Google ships under the Gemini brand: the Gemini 3.x / 2.5 / 2.0 / 1.5 model line, the Gemini Developer API (AI Studio path) and Vertex AI (enterprise path), the unified google-genai SDK that talks to both, the auxiliary features (context caching, function calling, structured output, code execution, Google Search grounding, long context, embeddings, batch mode, thinking budgets), and the multimodal sister-models (Nano Banana, Imagen, Veo, Lyria, Live API). House style matches the Claude sub-library; every non-obvious claim cites a ai.google.dev doc page, a cloud.google.com/vertex-ai page, or a google-gemini/* GitHub repo. Where the docs are silent but the behavior is observable, the entry is labelled “Undocumented as of 2026-05-25 — observed behavior” so a future reader knows to verify.
This sub-library lives inside Math-and-Compute/Compute/ as a sibling of Claude/, OpenAI/, the Tier3/ folder, and the operating-systems / databases / ML notes. The contents are intentionally version-pinned because the Gemini line moves fast — the 2.5 generation was the production default through most of 2025, the 3.x generation became dominant in 2026, and the 1.5 line is on a deprecation path. Read this index for the map, then drill into the specific note.
See also
_index — sister sub-library for Anthropic’s Claude line; many architectural choices mirror each other in inverted form (Gemini’s explicit caching vs Claude’s cache_control breakpoints, etc.)
_index — sister sub-library for OpenAI; useful for cross-vendor comparisons (Responses API ↔ generateContent, Realtime ↔ Live API)
The Gemini Developer API surface (REST + google-genai Python / Node / Go / Java / C# SDKs), client.models.generate_content shape, streaming, chats, async, AI Studio vs Vertex AI client modes, error model
Choosing Developer API vs Vertex AI — gemini-api-and-sdks for the surface comparison, vertex-ai-enterprise-gemini for the enterprise-feature delta (private VPC, regional endpoints, IAM, audit logs).
Production / compliance deployments — vertex-ai-enterprise-gemini is the start; everything else cross-links from there.
Conventions used in this library
Model IDs are quoted verbatim with the models/ prefix where the API requires it (e.g. models/gemini-2.5-pro, models/gemini-3.5-flash). The SDK accepts bare IDs; the REST API requires the prefix.
Pricing is in USD per million tokens (MTok). Where multiple \$ symbols appear on the same line they are backslash-escaped to avoid Obsidian MathJax interpretation.
Code examples use the unified google-genai SDK (the new one as of 2025) — not the legacy google-generativeai package, which is on deprecation track.
“Per ai.google.dev 2026-05” tags a claim sourced from official documentation as of the file’s created date.
“Per cloud.google.com/vertex-ai/generative-ai/docs 2026-05” tags Vertex-side claims (note: Vertex docs are migrating to the Gemini Enterprise Agent Platform docs site as of 2026; the old URLs redirect).
Where Google has rebranded between AI Studio and Gemini Developer API, this library uses Gemini Developer API as the canonical term and notes AI Studio only as the web UI for that API.
Sources read while building this library (2026-05-25 pass)
ai.google.dev/gemini-api/docs/thinking (thinking_budget vs thinkingLevel, summaries)
cloud.google.com/vertex-ai/generative-ai/docs (Vertex AI overview — now redirects to Gemini Enterprise Agent Platform)
github.com/google-gemini/cookbook (canonical worked examples)
github.com/googleapis/python-genai (unified SDK README + API surface)
Sections that required inference (rather than direct doc lookup) are flagged in each file under “Undocumented as of 2026-05-25 — observed behavior” so they can be re-verified later.