summaryrefslogtreecommitdiffstats
path: root/src/client
diff options
context:
space:
mode:
authorsigoden <sigoden@gmail.com>2023-12-24 16:04:18 +0800
committerGitHub <noreply@github.com>2023-12-24 16:04:18 +0800
commit1c9ca1b002badb511ff21d58b3f20986741ab31f (patch)
tree171edf24341f96ac4a93e00b315a3ce8b90455fc /src/client
parent89fefb4d1a3239496e90daf74be8b08decc603d2 (diff)
downloadaichat-1c9ca1b002badb511ff21d58b3f20986741ab31f.tar.gz
feat: custom REPL prompt (#283)
Diffstat (limited to 'src/client')
-rw-r--r--src/client/qianwen.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/client/qianwen.rs b/src/client/qianwen.rs
index 022e286..5b8755f 100644
--- a/src/client/qianwen.rs
+++ b/src/client/qianwen.rs
@@ -246,7 +246,7 @@ fn build_body(data: SendData, model: String, is_vl: bool) -> Result<(Value, bool
Ok((body, has_upload))
}
-/// Patch messsages, upload emebeded images to oss
+/// Patch messsages, upload embedded images to oss
async fn patch_messages(model: &str, api_key: &str, messages: &mut Vec<Message>) -> Result<()> {
for message in messages {
if let MessageContent::Array(list) = message.content.borrow_mut() {
@@ -258,7 +258,7 @@ async fn patch_messages(model: &str, api_key: &str, messages: &mut Vec<Message>)
if url.starts_with("data:") {
*url = upload(model, api_key, url)
.await
- .with_context(|| "Failed to upload embeded image to oss")?;
+ .with_context(|| "Failed to upload embedded image to oss")?;
}
}
}