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
fix bugs in searching file using keywords (#780)
KevinHuShd8c080ee522d
diff --git a/api/db/services/file_service.py b/api/db/services/file_service.pyindex 664a117739..e551509cc8 100644--- a/api/db/services/file_service.py+++ b/api/db/services/file_service.py@@ -34,9 +34,9 @@ class FileService(CommonService):orderby, desc, keywords):if keywords:files = cls.model.select().where(- (cls.model.tenant_id == tenant_id)+ (cls.model.tenant_id == tenant_id),(cls.model.parent_id == pf_id),- (fn.LOWER(cls.model.name).like(f"%%{keywords.lower()}%%")),+ (fn.LOWER(cls.model.name).contains(keywords.lower())),~(cls.model.id == pf_id))else:diff --git a/api/db/services/task_service.py b/api/db/services/task_service.pyindex 8d96fefbcb..6dcad82650 100644--- a/api/db/services/task_service.py+++ b/api/db/services/task_service.py@@ -96,7 +96,7 @@ class TaskService(CommonService):return doc.run == TaskStatus.CANCEL.value or doc.progress < 0except Exception as e:pass- return True+ return False@classmethod@DB.connection_context()