[dev] modify commit

This commit is contained in:
jinli.yl 2024-07-27 21:59:17 +08:00
parent ad65f3592e
commit 6174f84b23
2 changed files with 2 additions and 3 deletions

View file

@ -27,8 +27,7 @@ class LlamaIndexEsMemoryStore(BaseMemoryStore):
retrieval_strategy = ESCombinedRetrieveStrategy(retrieve_mode=retrieve_mode, hybrid_alpha=hybrid_alpha)
self.es_store = SyncElasticsearchStore(index_name=index_name,
es_url=es_url,
retrieval_strategy=ESCombinedRetrieveStrategy(retrieve_mode=retrieve_mode,
hybrid_alpha=hybrid_alpha),
retrieval_strategy=retrieval_strategy,
**kwargs)
# TODO The llamaIndex utilizes some deprecated functions, hence langchain logs warning messages. By

View file

@ -267,7 +267,7 @@ def _to_elasticsearch_filter(standard_filters: Dict[str, List[str]]) -> Dict[str
}
}
)
result['bool'].update({"should": operands}) # тнР Add 'should' clause for OR logic
result['bool'].update({"should": operands}) # Add 'should' clause for OR logic
result['bool'].update({"minimum_should_match": 1}) # Ensure at least one 'should' match
else:
key_str = f"metadata.{key}.keyword" if isinstance(value, str) else f"metadata.{key}"