zhayujie / chatgpt-on-wechat

基于大模型搭建的聊天机器人,同时支持 微信公众号、企业微信应用、飞书、钉钉 等接入,可选择GPT3.5/GPT-4o/GPT-o1/ Claude/文心一言/讯飞星火/通义千问/ Gemini/GLM-4/Claude/Kimi/LinkAI,能处理文本、语音和图片,访问操作系统和互联网,支持基于自有知识库进行定制企业智能客服。
https://docs.link-ai.tech/cow
MIT License
30.3k stars 7.97k forks source link

账号有chat4的权限,把key放进去改了模型提示does not exist or you do not have access to it #1591

Open xionghaizhi opened 9 months ago

xionghaizhi commented 9 months ago

前置确认

⚠️ 搜索issues中是否已存在类似问题

操作系统类型?

Linux

运行的python版本是?

python 3.7

使用的chatgpt-on-wechat版本是?

Latest Release

运行的channel类型是?

wx(个人微信, itchat)

复现步骤 🕹

使用gpt-4 模型,提示没有授权,页面chat4 可以使用

问题描述 😯

使用gpt-4 模型,提示没有授权,页面chat4 可以使用

终端日志 📒

[INFO][2023-12-12 09:52:59][bridge.py:45] - create bot chatGPT for chat
[INFO][2023-12-12 09:52:59][chat_gpt_bot.py:49] - [CHATGPT] query=123
[ERROR][2023-12-12 09:53:03][chat_gpt_bot.py:155] - [CHATGPT] Exception: The model `gpt-4` does not exist or you do not have access to it. Learn more: https://help.openai.com/en/articles/7102672-how-can-i-access-gpt-4.
Traceback (most recent call last):
  File "/home/weixin/newWeixin/chatgpt-on-wechat-master/bot/chatgpt/chat_gpt_bot.py", line 123, in reply_text
    response = openai.ChatCompletion.create(api_key=api_key, messages=session.messages, **args)
  File "/usr/local/python3/lib/python3.10/site-packages/openai/api_resources/chat_completion.py", line 25, in create
    return super().create(*args, **kwargs)
  File "/usr/local/python3/lib/python3.10/site-packages/openai/api_resources/abstract/engine_api_resource.py", line 153, in create
    response, _, api_key = requestor.request(
  File "/usr/local/python3/lib/python3.10/site-packages/openai/api_requestor.py", line 298, in request
    resp, got_stream = self._interpret_response(result, stream)
  File "/usr/local/python3/lib/python3.10/site-packages/openai/api_requestor.py", line 700, in _interpret_response
    self._interpret_response_line(
  File "/usr/local/python3/lib/python3.10/site-packages/openai/api_requestor.py", line 763, in _interpret_response_line
    raise self.handle_error_response(
openai.error.InvalidRequestError: The model `gpt-4` does not exist or you do not have access to it. Learn more: https://help.openai.com/en/articles/7102672-how-can-i-access-gpt-4.
[INFO][2023-12-12 09:53:03][wechat_channel.py:194] - [WX] sendMsg=Reply(type=ERROR, content=[ERROR]
我现在有点累了,等会再来吧), receiver=@325bbcf23d6c090e6897dbe4a225dd6821f8465c584034f65a3462d4c5ef0e77
zhayujie commented 9 months ago

在这看有没有API的权限 https://platform.openai.com/account/limits

rolsy commented 4 months ago

在这看有没有API的权限 https://platform.openai.com/account/limits 1715450856002 gpt-4的权限怎么整啊,我这个gpt-4-0613没法用吧