diff --git a/dist/index.js b/dist/index.js index c2d30b5..c53be8a 100644 --- a/dist/index.js +++ b/dist/index.js @@ -2318,11 +2318,7 @@ class Bot { // eslint-disable-next-line camelcase anthropic_version: 'bedrock-2023-05-31', // eslint-disable-next-line camelcase - max_tokens: 4000, - // eslint-disable-next-line camelcase - top_p: 0.9, - // eslint-disable-next-line camelcase - top_k: 250, + max_tokens: 4096, temperature: 0, messages: [ { @@ -5053,8 +5049,9 @@ class TokenLimits { this.responseTokens = 3000; } else { - this.maxTokens = 4000; - this.responseTokens = 1000; + // The latest models usually have this level of limits. + this.maxTokens = 200_000; + this.responseTokens = 4096; } // provide some margin for the request tokens this.requestTokens = this.maxTokens - this.responseTokens - 100; diff --git a/src/bot.ts b/src/bot.ts index bf8980f..2c90c10 100644 --- a/src/bot.ts +++ b/src/bot.ts @@ -64,11 +64,7 @@ export class Bot { // eslint-disable-next-line camelcase anthropic_version: 'bedrock-2023-05-31', // eslint-disable-next-line camelcase - max_tokens: 4000, - // eslint-disable-next-line camelcase - top_p: 0.9, - // eslint-disable-next-line camelcase - top_k: 250, + max_tokens: 4096, temperature: 0, messages: [ { diff --git a/src/limits.ts b/src/limits.ts index 04e738e..279d783 100644 --- a/src/limits.ts +++ b/src/limits.ts @@ -11,8 +11,9 @@ export class TokenLimits { this.maxTokens = 100_000 this.responseTokens = 3000 } else { - this.maxTokens = 4000 - this.responseTokens = 1000 + // The latest models usually have this level of limits. + this.maxTokens = 200_000 + this.responseTokens = 4096 } // provide some margin for the request tokens this.requestTokens = this.maxTokens - this.responseTokens - 100