Skip to content

Commit 836c66d

Browse files
committed
fix image
1 parent 982bcb9 commit 836c66d

File tree

5 files changed

+4
-1453
lines changed

5 files changed

+4
-1453
lines changed

gpt_server/model_worker/base/model_worker_base.py

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -91,9 +91,7 @@ def __init__(
9191
multimodal: bool = False,
9292
):
9393
is_vision = False
94-
if model_type in ["image"]:
95-
pass
96-
elif model_type not in ["asr", "tts"]:
94+
if model_type not in ["asr", "tts", "image"]:
9795
try:
9896
self.model_config = AutoConfig.from_pretrained(
9997
model_path, trust_remote_code=True
@@ -143,7 +141,7 @@ def preprocess_params(self, params: dict) -> dict:
143141
# ---------- 添加 chat_template 信息 ----------
144142
params["chat_template"] = self.chat_template
145143
# ---------- 添加多模态信息 ----------
146-
if self.vision_config:
144+
if hasattr(self, "vision_config") and self.vision_config:
147145
params["multimodal"] = True
148146
params["chat_template"] = self.vl_chat_template
149147
# ---------- 如果传入的是 str 则修改为messages ----------

install.sh

Lines changed: 0 additions & 1 deletion
This file was deleted.

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[project]
22
name = "gpt_server"
3-
version = "0.6.8"
3+
version = "0.6.8.1"
44
description = "gpt_server是一个用于生产级部署LLMs、Embedding、Reranker、ASR和TTS的开源框架。"
55
readme = "README.md"
66
license = { text = "Apache 2.0" }

0 commit comments

Comments
 (0)