skylark95 / skylark95-cogs Goto Github PK
View Code? Open in Web Editor NEWA collection of my personal cogs for use with Red-DiscordBot.
License: MIT License
A collection of my personal cogs for use with Red-DiscordBot.
License: MIT License
Whant I try to load the chatgpt cog, I get the following error: TypeError: 'type' object is not subscriptable
Traceback (most recent call last):
File "{HOME}/.local/share/Red-DiscordBot/data/jarvis/cogs/CogManager/cogs/chatgpt/chatgpt.py", line 103, in call_api
response = openai.ChatCompletion.create(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "{HOME}/.local/share/Red-DiscordBot/data/jarvis/cogs/Downloader/lib/openai/lib/_old_api.py", line 39, in __call__
raise APIRemovedInV1(symbol=self._symbol)
openai.lib._old_api.APIRemovedInV1:
You tried to access openai.ChatCompletion, but this is no longer supported in openai>=1.0.0 - see the README at https://github.com/openai/openai-python for the API.
You can run `openai migrate` to automatically upgrade your codebase to use the 1.0.0 interface.
Alternatively, you can pin your installation to the old version, e.g. `pip install openai==0.28`
A detailed migration guide is available here: https://github.com/openai/openai-python/discussions/742
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "{HOME}/redenv/lib/python3.11/site-packages/discord/client.py", line 441, in _run_event
await coro(*args, **kwargs)
File "{HOME}/.local/share/Red-DiscordBot/data/jarvis/cogs/CogManager/cogs/chatgpt/chatgpt.py", line 52, in on_message
await self.do_chatgpt(ctx)
File "{HOME}/.local/share/Red-DiscordBot/data/jarvis/cogs/CogManager/cogs/chatgpt/chatgpt.py", line 76, in do_chatgpt
reply = await self.call_api(
^^^^^^^^^^^^^^^^^^^^
File "{HOME}/.local/share/Red-DiscordBot/data/jarvis/cogs/CogManager/cogs/chatgpt/chatgpt.py", line 113, in call_api
except openai.error.APIError as e:
^^^^^^^^^^^^
AttributeError: module 'openai' has no attribute 'error' #57 [2024-03-04 18:44:25] ERROR [discord.client] Ignoring exception in on_message. ```
had this error show up on chatgpt today with your cog
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.