Skip to content
AI Skills Central

Type to search Agent Skills, workflows, tutorials, tools and the glossary.

Hybrid search

Definition

Combining keyword search, such as BM25, with vector search and merging the results into one ranking, often with reciprocal rank fusion.

In more detail

Vector search catches paraphrases; keyword search catches exact names, codes and rare terms. Merging both, often with reciprocal rank fusion, is a reliable default for RAG.

Reciprocal rank fusion combines the two ranked lists by position rather than raw score, so you do not need to make keyword and vector scores comparable. Many vector databases, including Qdrant, Weaviate and Milvus, and Postgres setups with pgvector plus full-text search support hybrid queries. Add a reranker on top when the merged list is long, and test on queries containing product names, error codes and acronyms, which is where pure vector search tends to fail.

  • BM25

    A classic keyword relevance function that scores documents by term frequency and rarity, adjusted for document length. Still a strong baseline.

  • Embedding

    A vector representation of text or other data that places items with similar meaning close together, so they can be searched by similarity.

  • Reciprocal rank fusion (RRF)

    A way to merge ranked result lists into one by scoring each document on its positions in the lists, not their raw scores.

  • Reranking

    Re-scoring an initial set of retrieved results with a slower, more accurate model before passing only the best few on to the LLM.

  • Contextual retrieval

    Adding a short, model-written note on where each chunk sits in its source document before embedding and indexing the chunk.

  • HNSW

    Hierarchical Navigable Small World: a graph-based index for fast approximate nearest-neighbour search, widely used by vector databases.

  • Embeddings and vector search

    Turning text into vectors to find similar items, alone or with keywords.

    SkillIntermediate

  • RAG fundamentals: retrieval before generation

    What RAG is and how retrieval-augmented generation works, when it beats long context or fine-tuning, and a minimal working pipeline in about 80 lines of Python.

    TutorialBeginner30 min

  • Reranking

    Re-scoring an initial set of retrieved results with a slower, more accurate model before passing only the best few on to the LLM.

    Glossary