Skip to content

Commit

Permalink
Update api.py
Browse files Browse the repository at this point in the history
  • Loading branch information
Haibersut authored Jul 17, 2023
1 parent 0c61443 commit 0fb82e1
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions adapter/chatgpt/api.py
Original file line number Diff line number Diff line change
Expand Up @@ -308,6 +308,7 @@ async def ask(self, prompt: str) -> AsyncGenerator[str, None]:
except Exception as e:
logger.error(f"[ChatGPT-API:{self.bot.engine}] 请求失败:\n{e}")
yield f"发生错误: \n{e}"
raise

async def preset_ask(self, role: str, text: str):
self.bot.engine = self.current_model
Expand Down

0 comments on commit 0fb82e1

Please sign in to comment.