safe_mem0_search
Function
This function is defined in the factories module.Defensive wrapper for mem0.search() to handle MongoDB vector store compatibility. Catches the specific TypeError about an unexpected ‘vectors’ kwarg and falls back gracefully by returning an empty result set. This addresses the upstream mem0 bug: https://github.com/mem0ai/mem0/issues/3185 Any other TypeError is re-raised unchanged.
Signature
Parameters
Any
required
No description available.
Returns
List[Dict[str, Any]]
The result of the operation.
Uses
mem0_client.searchlogger.warning
Used By
Source
View on GitHub
praisonaiagents/memory/adapters/factories.py at line 26
