@nhtio/adk/batteries/llm/gemini_generate_content/adapter
Cross-environment executor adapter for Google's native Gemini generateContent endpoint.
Remarks
Targets POST {baseURL}/models/{model}:generateContent (and :streamGenerateContent when stream is set) — Gemini's OWN wire format, not an OpenAI-compatible façade in front of it.
That distinction is the reason this battery exists. Pointing openai_chat_completions at a Gemini-compatible gateway means some translator, not the ADK, decides how your primitives become contents[] — including whether a thoughtSignature is stamped, whether consecutive same-role turns get merged, and how a tool result is correlated to its call. For ordinary use that is fine. For anything that needs to reason about what the VENDOR actually received — an ordering guard, a wire-shape audit, a bug report against Google — the translation has to be ours and observable. See the validation battery's "Which API surface a rule applies to" guide.
Options layer exactly as the other batteries: constructor baseline → executor() overrides → per-iteration ctx.stash.geminiGenerateContent, re-validated each iteration.
Classes
| Class | Description |
|---|---|
| GeminiGenerateContentAdapter | Native Gemini generateContent executor adapter. |