mirror of
https://github.com/RYDE-WORK/Langchain-Chatchat.git
synced 2026-02-06 23:15:53 +08:00
update api.py
This commit is contained in:
parent
8635f63c31
commit
5575079e6b
6
api.py
6
api.py
@ -253,15 +253,15 @@ async def no_knowledge_chat(
|
|||||||
):
|
):
|
||||||
|
|
||||||
for resp, history in local_doc_qa.llm._call(
|
for resp, history in local_doc_qa.llm._call(
|
||||||
query=question, chat_history=history, streaming=True
|
prompt=question, history=history, streaming=True
|
||||||
):
|
):
|
||||||
pass
|
pass
|
||||||
|
|
||||||
return ChatMessage(
|
return ChatMessage(
|
||||||
question=question,
|
question=question,
|
||||||
response=resp["result"],
|
response=resp,
|
||||||
history=history,
|
history=history,
|
||||||
source_documents=None,
|
source_documents=[],
|
||||||
)
|
)
|
||||||
|
|
||||||
async def stream_chat(websocket: WebSocket, knowledge_base_id: str):
|
async def stream_chat(websocket: WebSocket, knowledge_base_id: str):
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user