Skip to content

Commit 754fd8f

Browse files
committed
fix: Support shared model
--bug=1061852 --user=张展玮 【应用】自动生成提示词时,如果使用的是共享模型,生成失败,提示模型不存在或不是大语言模型 https://www.tapd.cn/62980211/s/1774010
1 parent e489a63 commit 754fd8f

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

apps/chat/serializers/chat.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -168,7 +168,7 @@ def generate_prompt(self, instance: dict, with_valid=True):
168168
q = prompt.replace("{userInput}", message)
169169
messages[-1]['content'] = q
170170

171-
model_exist = QuerySet(Model).filter(workspace_id=workspace_id,
171+
model_exist = QuerySet(Model).filter(
172172
id=model_id,
173173
model_type = "LLM"
174174
).exists()

0 commit comments

Comments
 (0)