LinearRAG icon indicating copy to clipboard operation
LinearRAG copied to clipboard

调用开源大模型

Open sunny2022mx opened this issue 7 months ago • 1 comments

我想用deepseek、千问等开源大语言模型。 换了两个api调用平台,都显示openai.APIConnectionError: Connection error。 报错位置在 def infer(self, messages): response = self.openai_client.chat.completions.create(**self.llm_config,messages=messages) return response.choices[0].message.content 想请问怎么换GPT以外的大模型。

sunny2022mx avatar Apr 13 '26 02:04 sunny2022mx

请参考vllm等开源平台将qwen等模型进行部署,即可通过相同的方式调用。

https://github.com/vllm-project/vllm

jeremycp3 avatar Apr 19 '26 11:04 jeremycp3