refactor: update chat record processing to include chat count updates
This commit is contained in:
parent
a0e2403e77
commit
1374ed4171
@ -304,6 +304,8 @@ class ApplicationChatRecordAddKnowledgeSerializer(serializers.Serializer):
|
|||||||
# 批量保存聊天记录
|
# 批量保存聊天记录
|
||||||
ChatRecord.objects.bulk_update(chat_record_list, ['improve_paragraph_id_list'])
|
ChatRecord.objects.bulk_update(chat_record_list, ['improve_paragraph_id_list'])
|
||||||
update_document_char_length(document_id)
|
update_document_char_length(document_id)
|
||||||
|
for chat_id in chat_ids:
|
||||||
|
ChatCountSerializer(data={'chat_id': chat_id}).update_chat()
|
||||||
|
|
||||||
return paragraph_ids, knowledge_id
|
return paragraph_ids, knowledge_id
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user