Merge pull request #1770 from jlau-ice/fix/vllm-reply-in-English

fix: 修正VLLM本地调用,question参数为空会用英文回复的问题
This commit is contained in:
hrz 2025-07-07 11:58:58 +08:00 committed by GitHub
commit 5ee7830f1b
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -40,6 +40,7 @@ class VLLMProvider(VLLMProviderBase):
self.client = openai.OpenAI(api_key=self.api_key, base_url=self.base_url)
def response(self, question, base64_image):
question = question + "(请使用中文回复)"
try:
messages = [
{