Skip to content

Commit

Permalink
修复 request error 问题
Browse files Browse the repository at this point in the history
  • Loading branch information
wzpan authored Apr 15, 2024
1 parent a68ac57 commit 3b568bd
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions robot/AI.py
Original file line number Diff line number Diff line change
Expand Up @@ -298,10 +298,10 @@ def stream_chat(self, texts):

header = {
"Content-Type": "application/json",
# "Authorization": "Bearer " + self.openai.api_key,
# "Authorization": "Bearer " + self.openai.api_key
}
if self.provider == 'openai':
header['Authorization'] = "Bearer " + self.openai.api_key,
header['Authorization'] = "Bearer " + self.openai.api_key
elif self.provider == 'azure':
header['api-key'] = self.openai.api_key
else:
Expand Down

0 comments on commit 3b568bd

Please sign in to comment.