Skip to content

Conversation

@pull
Copy link

@pull pull bot commented Jan 16, 2026

See Commits and Changes for more details.


Created by pull[bot] (v2.0.0-alpha.4)

Can you help keep this open source service alive? 💖 Please sponsor : )

Akshat8510 and others added 2 commits January 15, 2026 14:32
Merge #4117

**Overview**
 This PR implements the feature request in #4108 to allow `thinking_config` to be set directly within `generate_content_config`, bringing the Python SDK in line with the Go implementation.

 **Changes**
 - **llm_agent.py**: Relaxed the validation logic in `validate_generate_content_config` to remove the `ValueError` for `thinking_config`.
 - **Precedence Warning**: Added an override of `model_post_init` in `LlmAgent` to issue a `UserWarning` if both a `planner` and a manual `thinking_config` are provided.
 - **built_in_planner.py**: Updated `apply_thinking_config` to log an `INFO` message when the planner overwrites an existing configuration on the `LlmRequest`.

 **Testing**
 Verified with a reproduction script covering:
 1. Successful initialization of an agent with direct `thinking_config`.
 2. Validation of `UserWarning` during initialization when conflicting configurations are present.
 3. Confirmation of logger output when the planner performs an overwrite.

 Closes: #4108
 Tagging @invictus2010 for visibility.

Co-authored-by: Liang Wu <wuliang@google.com>
COPYBARA_INTEGRATE_REVIEW=#4117 from Akshat8510:feat/allow-thinking-config-4108 5deeb89
PiperOrigin-RevId: 856821447
…hema

Co-authored-by: Liang Wu <wuliang@google.com>
PiperOrigin-RevId: 856882485
@pull pull bot locked and limited conversation to collaborators Jan 16, 2026
@pull pull bot added the ⤵️ pull label Jan 16, 2026
@pull pull bot merged commit d0aef8a into CrazyForks:main Jan 16, 2026
1 of 8 checks passed
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants