> ## Documentation Index
> Fetch the complete documentation index at: https://docs.lyzr.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Retrieval Strategies

> 6 retrieval strategies for different use cases

The hosted Cognis service supports multiple retrieval strategies that control how memories are searched and ranked. The default strategy (`COGNIS`) works well for most cases, but you can switch strategies for specific use cases.

## Available Strategies

| Strategy                | Description                                                                        | Best For                         |
| ----------------------- | ---------------------------------------------------------------------------------- | -------------------------------- |
| **COGNIS**              | Optimized hybrid pipeline (default). Vector + BM25 + RRF fusion with recency boost | General-purpose memory retrieval |
| **FOUR\_WAY\_TEMPR**    | Semantic + BM25 + Graph with Hindsight pattern                                     | Complex relationship queries     |
| **MULTI\_QUERY\_RAG**   | Generates 5 query variants + HyDE + RRF fusion                                     | Ambiguous or broad queries       |
| **SINGLE\_QUERY**       | Simple vector search without BM25 or fusion                                        | Fast, straightforward lookups    |
| **SIMPLEMEM\_ADAPTIVE** | Adaptive k based on query complexity                                               | Variable-complexity workloads    |
| **RFM\_EVIDENCE\_POOL** | Iterative gap-filling retrieval                                                    | Research and evidence gathering  |

## Default Behavior

The `COGNIS` strategy is used by default for all `search()` and `context()` calls. It combines:

1. Matryoshka vector search (256D shortlist → 768D rerank)
2. BM25 keyword matching
3. Reciprocal Rank Fusion (70% vector, 30% BM25)
4. Recency boost with exponential decay
5. Temporal query detection

This is the same pipeline architecture used in the [open-source hybrid search](/cognis/features/hybrid-search).

<Note>
  The open-source `lyzr-cognis` package uses the COGNIS (hybrid RRF) strategy only. Multiple retrieval strategies are a hosted-only feature.
</Note>
