netease-youdao / QAnything

Question and Answer based on Anything.
https://qanything.ai
GNU Affero General Public License v3.0
11.43k stars 1.1k forks source link

[BUG] 调用openai 的api 。Connection error. #142

Open sawyerfeng opened 6 months ago

sawyerfeng commented 6 months ago

是否已有关于该错误的issue或讨论? | Is there an existing issue / discussion for this?

该问题是否在FAQ中有解答? | Is there an existing answer for this in FAQ?

当前行为 | Current Behavior

当我部署好openai的apikey后,询问返回Connection error.盲猜是要访问openai的服务器但是没有代理,如何在该代码上正确配置代理呢

期望行为 | Expected Behavior

我想成功联通openai服务器,返回结果

运行环境 | Environment

- OS: ubuntu
- NVIDIA Driver:535.104.05
- CUDA:12.2
- Docker Compose:1.29.2
- NVIDIA GPU Memory: 24G

QAnything日志 | QAnything logs

复现方法 | Steps To Reproduce

sudo bash ./run.sh -c cloud -i 0 -b default # gpu id 0

备注 | Anything else?

huliangbing commented 6 months ago

同样的问题,连不上openai

changqingla commented 6 months ago

如何连接呢

huliangbing commented 6 months ago

如何连接呢

用one-api将通义千问Qwen或者智谱清言ChatGLM4 API 转成OpenAI API

xiapazhi commented 4 months ago

如何连接呢

用one-api将通义千问Qwen或者智谱清言ChatGLM4 API 转成OpenAI API

转换后会报 num_tokens_from_messages() is not implemented for model qwen-plus 这么个错误,大佬有遇到吗

xuzhuang1996 commented 1 month ago

如何连接呢

用one-api将通义千问Qwen或者智谱清言ChatGLM4 API 转成OpenAI API

转换后会报 num_tokens_from_messages() is not implemented for model qwen-plus 这么个错误,大佬有遇到吗

我也遇到这个问题了,铁铁咋解决的?

GreatStep commented 3 weeks ago

用ollama: 任意LLM模型,则可