wenjin272 commented on code in PR #1037:
URL: https://github.com/apache/flink-agents/pull/1037#discussion_r3850201918


##########
integrations/chat-models/anthropic/src/main/java/org/apache/flink/agents/integrations/chatmodels/anthropic/AnthropicChatModelConnection.java:
##########
@@ -366,15 +471,16 @@ BuiltRequest buildRequest(
         }
 
         Object temperature = modelParams.remove("temperature");
-        if (temperature instanceof Number) {
+        if (temperature instanceof Number
+                && sendSamplingParam(modelName, "temperature", temperature)) {

Review Comment:
   Thanks for fixing this! When both the top-level `temperature` and 
`additional_kwargs.temperature` are set, the latter should take precedence. 
However, the warning is emitted for the top-level value first and may report 
the overridden value. Could we resolve the effective temperature before 
filtering/logging and add a test for this case?



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to