fix: validate missing text indexing technique (#35941)

This commit is contained in:
juyua9
2026-05-12 05:07:03 +00:00
committed by GitHub
parent 4fd4615c56
commit 4bb987eca3
2 changed files with 4 additions and 4 deletions
@@ -136,7 +136,7 @@ def _create_document_by_text(tenant_id: str, dataset_id: UUID) -> tuple[Mapping[
if not dataset:
raise ValueError("Dataset does not exist.")
if not dataset.indexing_technique and not args["indexing_technique"]:
if not dataset.indexing_technique and not args.get("indexing_technique"):
raise ValueError("indexing_technique is required.")
embedding_model_provider = payload.embedding_model_provider