max token

This commit is contained in:
Skye 2023-03-19 10:05:08 +09:00
parent e892932090
commit 8baaec182b
Signed by: me
GPG key ID: 0104BC05F41B77B8

View file

@ -150,6 +150,7 @@ impl EventHandler for Handler {
.create_chat_completion(openai::ChatCompletion { .create_chat_completion(openai::ChatCompletion {
model: self.model.clone(), model: self.model.clone(),
messages: msgs, messages: msgs,
max_tokens: Some(450), // abt 1800 characters
..Default::default() ..Default::default()
}) })
.await .await