Advanced Retrieval
Mem0’s Advanced Retrieval feature delivers superior search results by leveraging state-of-the-art search algorithms. Beyond the default search functionality, Mem0 offers the following advanced retrieval modes:
-
Keyword Search
This mode emphasizes keywords within the query, returning memories that contain the most relevant keywords alongside those from the default search. By default, this parameter is set to
false
. Enabling it enhances search recall, though it may slightly impact precision.Example:
-
Reranking
Normal retrieval gives you memories sorted in order of their relevancy, but the order may not be perfect. Reranking uses a deep neural network to correct this order, ensuring the most relevant memories appear first. If you are concerned about the order of memories, or want that the best results always comes at top then use reranking. This parameter is set to
false
by default. When enabled, it reorders the memories based on a more accurate relevance score.Example:
-
Filtering
Filtering allows you to narrow down search results by applying specific criterias. This parameter is set to
false
by default. When activated, it significantly enhances search precision by removing irrelevant memories, though it may slightly reduce recall. Filtering is particularly useful when you need highly specific information.Example:
search
method. There is no required sequence for these modes, and any combination can be used based on your needs. Latency Numbers
Here are the typical latency ranges for each search mode:
Mode | Latency |
---|---|
Keyword Search | <10ms |
Reranking | 150-200ms |
Filtering | 200-300ms |
If you have any questions, please feel free to reach out to us using one of the following methods: