mirror of
https://github.com/Yidadaa/ChatGPT-Next-Web.git
synced 2025-08-10 19:07:03 +08:00
修复 VISION_MDOELS 在 docker 运行阶段不生效的问题
This commit is contained in:
@@ -6,7 +6,7 @@ import { ServiceProvider } from "./constant";
|
||||
// import { fetch as tauriFetch, ResponseType } from "@tauri-apps/api/http";
|
||||
import { fetch as tauriStreamFetch } from "./utils/stream";
|
||||
import { VISION_MODEL_REGEXES, EXCLUDE_VISION_MODEL_REGEXES } from "./constant";
|
||||
import { getClientConfig } from "./config/client";
|
||||
import { useAccessStore } from "./store";
|
||||
import { ModelSize } from "./typing";
|
||||
|
||||
export function trimTopic(topic: string) {
|
||||
@@ -255,8 +255,8 @@ export function getMessageImages(message: RequestMessage): string[] {
|
||||
}
|
||||
|
||||
export function isVisionModel(model: string) {
|
||||
const clientConfig = getClientConfig();
|
||||
const envVisionModels = clientConfig?.visionModels
|
||||
const visionModels = useAccessStore.getState().visionModels;
|
||||
const envVisionModels = visionModels
|
||||
?.split(",")
|
||||
.map((m) => m.trim());
|
||||
if (envVisionModels?.includes(model)) {
|
||||
|
Reference in New Issue
Block a user