mirror of
https://github.com/infiniflow/ragflow.git
synced 2025-12-22 22:26:43 +08:00
Fix: update RAGFlow SDK for consistency (#12065)
### What problem does this PR solve? Fix: update RAGFlow SDK for consistency #12059 ### Type of change - [x] Bug Fix (non-breaking change which fixes an issue)
This commit is contained in:
@ -201,6 +201,8 @@ class RAGFlow:
|
|||||||
keyword: bool = False,
|
keyword: bool = False,
|
||||||
cross_languages: list[str]|None = None,
|
cross_languages: list[str]|None = None,
|
||||||
metadata_condition: dict | None = None,
|
metadata_condition: dict | None = None,
|
||||||
|
use_kg: bool = False,
|
||||||
|
toc_enhance: bool = False,
|
||||||
):
|
):
|
||||||
if document_ids is None:
|
if document_ids is None:
|
||||||
document_ids = []
|
document_ids = []
|
||||||
@ -216,7 +218,9 @@ class RAGFlow:
|
|||||||
"dataset_ids": dataset_ids,
|
"dataset_ids": dataset_ids,
|
||||||
"document_ids": document_ids,
|
"document_ids": document_ids,
|
||||||
"cross_languages": cross_languages,
|
"cross_languages": cross_languages,
|
||||||
"metadata_condition": metadata_condition
|
"metadata_condition": metadata_condition,
|
||||||
|
"use_kg": use_kg,
|
||||||
|
"toc_enhance": toc_enhance
|
||||||
}
|
}
|
||||||
# Send a POST request to the backend service (using requests library as an example, actual implementation may vary)
|
# Send a POST request to the backend service (using requests library as an example, actual implementation may vary)
|
||||||
res = self.post("/retrieval", json=data_json)
|
res = self.post("/retrieval", json=data_json)
|
||||||
|
|||||||
Reference in New Issue
Block a user