RAGFlow is an agent-native database: a Retrieval-Augmented Generation (RAG) engine that grew into context infrastructure.
Go agent-harnessagent-native-databaseagentic-aiagentic-retrievalagentic-searchaiai-agentscontext-enginecontext-engineeringcontext-managementharness-engineeringknowledge-compilationragretrieval-augmented-generationretrieval-harnesssearch-harness
Knowledge base search is case sensitive (#797)
KevinHuSh1c4e92ed3518
diff --git a/api/db/services/document_service.py b/api/db/services/document_service.pyindex eca6877a9f..70e7af77c5 100644--- a/api/db/services/document_service.py+++ b/api/db/services/document_service.py@@ -16,6 +16,7 @@import randomfrom datetime import datetimefrom elasticsearch_dsl import Q+from peewee import fnfrom api.settings import stat_loggerfrom api.utils import current_timestamp, get_format_time@@ -40,8 +41,9 @@ class DocumentService(CommonService):orderby, desc, keywords):if keywords:docs = cls.model.select().where(- cls.model.kb_id == kb_id,- cls.model.name.like(f"%%{keywords}%%"))+ (cls.model.kb_id == kb_id),+ (fn.LOWER(cls.model.name).contains(keywords.lower()))+ )else:docs = cls.model.select().where(cls.model.kb_id == kb_id)count = docs.count()