Deprecated max_token to max-completion_tokens

This commit is contained in:
2024-12-08 16:46:09 +08:00
parent 5039bdfca8
commit 9dd4d99e54

View File

@@ -231,7 +231,7 @@ class Chat {
body["top_p"] = this.top_p; body["top_p"] = this.top_p;
} }
if (this.enable_max_gen_tokens) { if (this.enable_max_gen_tokens) {
body["max_tokens"] = this.max_gen_tokens; body["max_completion_tokens"] = this.max_gen_tokens;
} }
if (this.json_mode) { if (this.json_mode) {
body["response_format"] = { body["response_format"] = {