You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This commit was created on GitHub.com and signed with GitHub’s verified signature.
Minor Changes
#114000e7c765 Thanks @thushanth-bengre-langchain! - fix(google-genai): throw a typed, catchable EmptyContentError instead of silently returning empty content / an empty generations array when a non-streaming call (.invoke(), .generate(), .batch()) gets back a Gemini candidate with no content — whether from an explicit block (safety/recitation filter, rejected prompt) or the model just not producing usable output (a malformed function call, a thinking model exhausting its token budget). The streaming path (.stream()) is unaffected by this behavior change; it now safely skips a contentless chunk instead of throwing a raw TypeError.
Patch Changes
#114058cfff4d Thanks @hntrl! - Add LangSmith gateway support for Google Gemini (Developer API) models. When LANGSMITH_GATEWAY is set, ChatGoogleGenerativeAI and ChatGoogle (and initChatModel("google-genai:...")) route requests through the gateway's Gemini path, using the gateway key (falling back to LANGSMITH_API_KEY). An explicit baseUrl/endpoint, an explicit apiKey, or a Vertex AI configuration suppress gateway routing. Also adds GEMINI_API_KEY as a fallback env var for ChatGoogleGenerativeAI.