mirror of
https://github.com/infiniflow/ragflow.git
synced 2025-12-08 20:42:30 +08:00
Fix Text2SQL (#2131)
### What problem does this PR solve? Fix exeSQL component Update DB Assistant template Fix canvas Message window size ### Type of change - [x] Bug Fix (non-breaking change which fixes an issue) --------- Co-authored-by: Kevin Hu <kevinhu.sh@gmail.com>
This commit is contained in:
@ -260,7 +260,7 @@ class Canvas(ABC):
|
||||
|
||||
def get_history(self, window_size):
|
||||
convs = []
|
||||
for role, obj in self.history[window_size * -2:]:
|
||||
for role, obj in self.history[(window_size + 1) * -1:]:
|
||||
convs.append({"role": role, "content": (obj if role == "user" else
|
||||
'\n'.join(pd.DataFrame(obj)['content']))})
|
||||
return convs
|
||||
|
||||
Reference in New Issue
Block a user