fix ChatCompletion and ChatCompletionChunk object string not compatible with standard openai api (#2089)

Co-authored-by: sunxichen <sun.xc@digitalcnzz.com>
This commit is contained in:
sunxichen 2024-06-25 16:59:50 +08:00 committed by GitHub
parent 83634dc122
commit b69f078041
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 2 additions and 2 deletions

View File

@ -570,7 +570,7 @@ impl ChatCompletion {
};
Self {
id: String::new(),
object: "text_completion".into(),
object: "chat.completion".into(),
created,
model,
system_fingerprint,
@ -682,7 +682,7 @@ impl ChatCompletionChunk {
};
Self {
id: String::new(),
object: "text_completion".to_string(),
object: "chat.completion.chunk".to_string(),
created,
model,
system_fingerprint,