Skip to content

Commit

Permalink
feat:去掉测试代码
Browse files Browse the repository at this point in the history
  • Loading branch information
zgqgit committed Jun 28, 2024
1 parent 74c0339 commit b9b581a
Showing 1 changed file with 1 addition and 16 deletions.
17 changes: 1 addition & 16 deletions src/backend/bisheng/chat/handlers.py
Original file line number Diff line number Diff line change
Expand Up @@ -172,11 +172,6 @@ async def process_message(self,
chat_id=chat_id,
)

questions = []
if is_begin and langchain_object.memory and langchain_object.memory.buffer:
questions = self.recommend_question(langchain_object,
langchain_object.memory.buffer)

except Exception as e:
# Log stack trace
logger.exception(e)
Expand Down Expand Up @@ -223,17 +218,7 @@ async def process_message(self,
user_id=user_id,
source=int(source))
await session.send_json(client_id, chat_id, response)
if questions:
# 提示问题
for question in questions:
question_resp = ChatResponse(type='start',
message='',
category='autoQuestion',
user_id=user_id)
await session.send_json(client_id, chat_id, question_resp, add=False)
question_resp.type = 'end'
question_resp.message = question
await session.send_json(client_id, chat_id, question_resp, add=False)


# 循环结束
if is_begin:
Expand Down

0 comments on commit b9b581a

Please sign in to comment.