From 8baaec182bc46f0967af3b050e5cccefcc58d1a2 Mon Sep 17 00:00:00 2001 From: Skye Date: Sun, 19 Mar 2023 10:05:08 +0900 Subject: [PATCH] max token --- src/main.rs | 1 + 1 file changed, 1 insertion(+) diff --git a/src/main.rs b/src/main.rs index c547e3f..06beebe 100644 --- a/src/main.rs +++ b/src/main.rs @@ -150,6 +150,7 @@ impl EventHandler for Handler { .create_chat_completion(openai::ChatCompletion { model: self.model.clone(), messages: msgs, + max_tokens: Some(450), // abt 1800 characters ..Default::default() }) .await