Skip to content

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

Fix enable/disable bug (#3662)

liuhua7f48acb3fd8a
diff --git a/rag/utils/es_conn.py b/rag/utils/es_conn.py
index a5b266b8f2..2e2d7f4ad8 100644
--- a/rag/utils/es_conn.py
+++ b/rag/utils/es_conn.py
@@ -294,7 +294,7 @@ class ESConnection(DocStoreConnection):
f"Condition `{str(k)}={str(v)}` value type is {str(type(v))}, expected to be int, str or list.")
scripts = []
for k, v in newValue.items():
- if not isinstance(k, str) or not v:
+ if (not isinstance(k, str) or not v) and k != "available_int":
continue
if isinstance(v, str):
scripts.append(f"ctx._source.{k} = '{v}'")