[autofix.ci] apply automated fixes

This commit is contained in:
autofix-ci[bot]
2026-02-01 16:04:47 +00:00
committed by GitHub
parent 591db73479
commit 4c5fd13fc3
3 changed files with 3 additions and 8 deletions

View File

@ -1341,10 +1341,7 @@ class DocumentGenerateSummaryApi(Resource):
# Update need_summary to True for documents that don't have it set
# This handles the case where documents were created when summary_index_setting was disabled
documents_to_update = [
doc for doc in documents
if not doc.need_summary and doc.doc_form != "qa_model"
]
documents_to_update = [doc for doc in documents if not doc.need_summary and doc.doc_form != "qa_model"]
if documents_to_update:
document_ids_to_update = [str(doc.id) for doc in documents_to_update]

View File

@ -58,7 +58,7 @@ class BaseIndexProcessor(ABC):
For each segment in preview_texts, generate a summary using LLM and attach it to the segment.
The summary can be stored in a new attribute, e.g., summary.
This method should be implemented by subclasses.
Args:
tenant_id: Tenant ID
preview_texts: List of preview details to generate summaries for

View File

@ -1390,9 +1390,7 @@ class DocumentService:
return documents
@staticmethod
def update_documents_need_summary(
dataset_id: str, document_ids: Sequence[str], need_summary: bool = True
) -> int:
def update_documents_need_summary(dataset_id: str, document_ids: Sequence[str], need_summary: bool = True) -> int:
"""
Update need_summary field for multiple documents.