Skip to content

Commit

Permalink
fix: oops, we're passing negative values; let's just remove this
Browse files Browse the repository at this point in the history
  • Loading branch information
KernelDeimos committed Jan 22, 2025
1 parent 61824ea commit cf7aa27
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/backend/src/modules/puterai/OpenAICompletionService.js
Original file line number Diff line number Diff line change
Expand Up @@ -354,13 +354,13 @@ class OpenAICompletionService extends BaseService {
}
}

const max_tokens = 4096 - token_count;
// const max_tokens = 4096 - token_count;

const completion = await this.openai.chat.completions.create({
user: user_private_uid,
messages: messages,
model: model,
max_tokens,
// max_tokens,
stream,
...(stream ? {
stream_options: { include_usage: true },
Expand Down

0 comments on commit cf7aa27

Please sign in to comment.