mirror of
https://git.mirrors.martin98.com/https://github.com/infiniflow/ragflow.git
synced 2025-08-14 09:45:58 +08:00
fix component rewrite bug (#2549)
### What problem does this PR solve? #2545 ### Type of change - [x] Bug Fix (non-breaking change which fixes an issue)
This commit is contained in:
parent
51dd6d1f90
commit
100c60017f
@ -65,6 +65,8 @@ class RewriteQuestion(Generate, ABC):
|
|||||||
chat_mdl = LLMBundle(self._canvas.get_tenant_id(), LLMType.CHAT, self._param.llm_id)
|
chat_mdl = LLMBundle(self._canvas.get_tenant_id(), LLMType.CHAT, self._param.llm_id)
|
||||||
ans = chat_mdl.chat(self._param.get_prompt(), [{"role": "user", "content": q}],
|
ans = chat_mdl.chat(self._param.get_prompt(), [{"role": "user", "content": q}],
|
||||||
self._param.gen_conf())
|
self._param.gen_conf())
|
||||||
|
self._canvas.history.pop()
|
||||||
|
self._canvas.history.append(("user", ans))
|
||||||
|
|
||||||
print(ans, ":::::::::::::::::::::::::::::::::")
|
print(ans, ":::::::::::::::::::::::::::::::::")
|
||||||
return RewriteQuestion.be_output(ans)
|
return RewriteQuestion.be_output(ans)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user