mirror of
https://github.com/Yanyutin753/ChatGPT-Next-Web-LangChain-Gpt-4-All.git
synced 2025-10-17 16:44:01 +00:00
修改通用MIME
This commit is contained in:
@@ -113,6 +113,7 @@ export class ChatGPTApi implements LLMApi {
|
|||||||
|
|
||||||
const extensionToMIME: MIMEMap = {
|
const extensionToMIME: MIMEMap = {
|
||||||
'png': 'image/png',
|
'png': 'image/png',
|
||||||
|
'jpeg': 'image/jpeg',
|
||||||
'jpg': 'image/jpeg',
|
'jpg': 'image/jpeg',
|
||||||
'webp': 'image/webp',
|
'webp': 'image/webp',
|
||||||
'gif': 'image/gif',
|
'gif': 'image/gif',
|
||||||
@@ -186,7 +187,7 @@ export class ChatGPTApi implements LLMApi {
|
|||||||
}
|
}
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
// 使用通用的MIME类型
|
// 使用通用的MIME类型
|
||||||
mimeType = 'text/plain';
|
mimeType = 'application/octet-stream';
|
||||||
}
|
}
|
||||||
message.content.push({
|
message.content.push({
|
||||||
type: "image_url",
|
type: "image_url",
|
||||||
|
Reference in New Issue
Block a user