Skip to content

RAGFlow is an agent-native database: a Retrieval-Augmented Generation (RAG) engine that grew into context infrastructure.

Fix metadata filter issue (#19803)

Wang Qi65fb421d1c16
diff --git a/internal/service/tag.go b/internal/service/tag.go
index 2e2525ae70..8d03ccecc7 100644
--- a/internal/service/tag.go
+++ b/internal/service/tag.go
@@ -131,12 +131,10 @@ func (s *MetadataService) GetAllTagsInPortion(ctx context.Context, tenantIDs []s
}
searchReq := &types.SearchRequest{
- IndexNames: indexNames,
- KbIDs: kbIDs,
- Offset: 0,
- // Python passes limit=0 ("unlimited") which Go SearchRequest treats
- // as engine default (Infinity/ES: 30), so use an explicit large cap.
- Limit: 100000,
+ IndexNames: indexNames,
+ KbIDs: kbIDs,
+ Offset: 0,
+ Limit: common.MAX_RESULT_WINDOW,
SelectFields: []string{"tag_kwd"},
}