-
Notifications
You must be signed in to change notification settings - Fork 1.6k
Description
Determine this is the right repository
- I determined this is the correct repository in which to report this bug.
Summary of the issue
Context
langchain_google_genai added the support for thinking_level (you can see here), But this library uses GenerationConfig from google.ai.generativelanguage_v1beta.types when preparing the request to google, the issue is that it causes this method to break because currently:
GenerationConfig → ThinkingConfig does not support thinking_level making impossible to use different thinking levels on the requests to Gemini 3 models.
Expected Behavior:
You should be able to provide a thinking_level field to ThinkingConfig to utilize the latest Gemini 3 models.
Actual Behavior:
You get an error when providing thinking_level to ThinkingConfig because it currently does not support that field.
API client name and version
google-ai-generativelanguage v0.9.0
Reproduction steps: code
file: main.py
from google.ai.generativelanguage_v1beta.types import GenerationConfig
def reproduce():
gen_config = { ... , "thinking_config" : { "thinking_level": "high" } }
GenerationConfig(**gen_config)
OS & version + platform
No response
Python environment
Python 3.13.17
Python dependencies
No response
Additional context
No response