feat: add new parameters for image generation and multimodal conversa…#244
Conversation
There was a problem hiding this comment.
Code Review
This pull request introduces several new parameters across various parameter classes to support advanced features such as thinking/reasoning modes, color palettes, reference image strength/mode, and stop words/tokens. Specifically, it updates ChatCompletionParam, ImageGenerationParam, ImageSynthesisParam, SketchImageSynthesisParam, and MultiModalConversationParam with their respective new fields, along with adding corresponding unit tests. A review comment highlights an issue in MultiModalConversationParam where configuring both stopStrings and stopTokens simultaneously results in stopTokens being silently ignored, and suggests throwing an IllegalArgumentException to handle this conflict.
Important
The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.
Lists EPL-2.0 (JUnit Jupiter, JUnit Pioneer) and other third-party components used in test scope to address license compliance. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
…L env Replaced hardcoded DEFAULT_BASE_HTTP_URL with taskGroup/task/function based URL construction, allowing base URL override via environment variable DASHSCOPE_HTTP_BASE_URL for custom endpoints. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
Use default TingWu constructor instead of hardcoding the base URL, consistent with the TingWu.java fix for environment variable support. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
Add IllegalArgumentException when both stopStrings and stopTokens are configured simultaneously in ConversationParam, GenerationParam, and MultiModalConversationParam to prevent silent parameter override. Previously, stopTokens was silently ignored when both parameters were set due to if-else structure. Now the SDK throws a clear error to help users debug their configuration.
a243d2f to
000f3db
Compare
…tual exclusion rule
…dalMessageAdapter
…mBase to prevent NPE" This reverts commit d667ac8.
…mBase to prevent NPE" This reverts commit 541ad3b.
…mBase to prevent NPE" This reverts commit 4e8b6bf.
…am error logging" This reverts commit b84fb58.
This reverts commit 1714e88.
…response merging issues" This reverts commit 45b4000.
…ing responses" This reverts commit 2112b1d.
…ersation stream responses
…tion