claude temperature check fixed

This commit is contained in:
mic 2025-12-28 21:36:31 +01:00
parent 7803fc3006
commit 7f4f3e6fe7

View file

@ -99,7 +99,7 @@ export class Anthropic {
stream: this.stream,
};
if(parseFloat(this.temperature) != NaN) claude_body.temperature = parseFloat(this.temperature);
if(this.temperature != '' && parseFloat(this.temperature) != NaN) claude_body.temperature = parseFloat(this.temperature);
const response = await fetch("https://api.anthropic.com/v1/messages", {
method: "POST",