Skip to content

Commit 4b7f4f0

Browse files
committed
fix: chatProvider updated
1 parent b44c667 commit 4b7f4f0

File tree

2 files changed

+5
-3
lines changed

2 files changed

+5
-3
lines changed

requirements.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,4 +3,5 @@ python-dotenv==1.0.0
33
asgiref==3.6.0
44
openai==1.13.3
55
selenium==4.9.1
6+
g4f==0.2.6.1
67
g4f[all]

src/aclient.py

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,10 +10,11 @@
1010
from discord import app_commands
1111
from asgiref.sync import sync_to_async
1212

13+
import g4f.debug
1314
from g4f.client import Client
14-
from g4f.Provider import RetryProvider, OpenaiChat, Liaobots, Bing, Gemini
1515
from g4f.stubs import ChatCompletion
16-
import g4f.debug
16+
from g4f.Provider import RetryProvider, OpenaiChat, Bing, You
17+
1718
g4f.debug.logging = True
1819

1920
load_dotenv()
@@ -25,7 +26,7 @@ def __init__(self) -> None:
2526
super().__init__(intents=intents)
2627
self.tree = app_commands.CommandTree(self)
2728
self.chatBot = Client(
28-
provider = RetryProvider([Liaobots, OpenaiChat, Bing], shuffle=False),
29+
provider = RetryProvider([You, Bing, OpenaiChat], shuffle=False),
2930
)
3031
self.chatModel = 'gpt-4'
3132
self.conversation_history = []

0 commit comments

Comments
 (0)