We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
top_p
1 parent ebbaff0 commit d65547dCopy full SHA for d65547d
src/engine/anthropic.ts
@@ -37,9 +37,14 @@ export class AnthropicEngine implements AiEngine {
37
system: systemMessage,
38
messages: restMessages,
39
temperature: 0,
40
- top_p: 0.1,
41
max_tokens: this.config.maxTokensOutput
42
};
+
43
+ // add top_p for non-4.5 models
44
+ if (!params.model.includes('-4-5')) {
45
+ params.top_p = 0.1;
46
+ }
47
48
try {
49
const REQUEST_TOKENS = messages
50
.map((msg) => tokenCount(msg.content as string) + 4)
0 commit comments