# Semantic search

> Canonical: https://skillalmanac.com/glossary/semantic-search | Last verified: 2026-11-25 | Index status: index-eligible

Semantic search aims to retrieve information relevant to a query's meaning rather than relying solely on matching word forms. Vector representations and learned ranking models are common implementations; the highest-ranked result can still be irrelevant or wrong.

Also called: meaning-based search.

## In plain language

A semantic-search system might find a page called Refund policy for a question about getting money back. This is an example of the intended behavior, not a promise about a particular query. Learned representations or ranking models can help connect different wording. Check the results themselves: a passage can be on topic without answering the question. Lexical matching, synonyms and semantic ranking can also be combined.

## Technical definition

Single-vector dense retrieval encodes a query and each indexed item into vectors and ranks candidates using a similarity measure. It is one implementation, not a definition of every semantic-search system. ColBERT instead uses contextualized token representations with late interaction between query and document representations. Learned rerankers can score candidates after retrieval. Lexical and vector methods can complement one another, and neither a similarity score nor a top rank guarantees relevance.

## How it shows up when you use agents

An application can use semantic retrieval to select passages for a model, or it can simply display search results without generating an answer. An agent may also use exact text search, a lexical index, a learned reranker or a hybrid pipeline. Check the implementation rather than assuming every search box works the same way.

For a document assistant, inspect the top passages for real user questions. Include paraphrases and exact product identifiers. If results miss exact names, lexical retrieval may help; if the wording differs, learned relevance signals may help. Measure the effect on the actual test queries instead of assuming one method always wins.

## Common confusions

- **Semantic search versus RAG.** Retrieval finds information. [RAG](/glossary/retrieval-augmented-generation) also conditions generation on retrieved evidence.
- **Semantic search versus vector storage.** A [vector database](/glossary/vector-database) is one component a retrieval system may use, not the entire method.
- **One vector versus all semantic methods.** Single-vector retrieval is common, but token-level multi-vector methods such as ColBERT also exist.
- **Relevant-looking versus correct.** Read the retrieved evidence and assess whether it supports the user's requested answer.

## Worked examples in this catalogue

### [rag-chunking-planner](https://skillalmanac.com/skills/skill-almanac/rag-chunking-planner)

Status: illustrative example from the item's own documentation, not executed for this page.

What you see: Your documents split by three chunking strategies, with defects and offline recall reported for each, so chunk settings are chosen with numbers.

Why it exercises the concept: Semantic search ranks the pieces you give it. How a document is cut into pieces decides what can be found, and the skill measures that step before you build the rest.

### [library-docs-lookup](https://skillalmanac.com/skills/skill-almanac/library-docs-lookup)

Status: illustrative example from the item's own documentation, not executed for this page.

What you see: An answer to a library question drawn from the installed package's own files, with file and line cited.

Why it exercises the concept: It is a contrast case: a coding agent can ground an answer in installed files rather than meaning-based search. Those files can still be stale, incomplete or wrong.

### [Context7 MCP: Feed Current Library Docs to an Agent](https://skillalmanac.com/learn/context7-mcp-guide)

Status: illustrative example from the item's own documentation, not executed for this page.

What you see: A hosted MCP server set up in Claude Code that takes a library name and a question and returns documentation, with a check that the agent's answer traces back to the docs it fetched.

Why it exercises the concept: It shows retrieval by question for a coding agent. The guide does not say how that server ranks its results, so treat it as retrieval by query rather than proof of a vector method.

## Related terms

- [Embedding](https://skillalmanac.com/glossary/embedding.md)
- [Vector database](https://skillalmanac.com/glossary/vector-database.md)
- [Retrieval-augmented generation (RAG)](https://skillalmanac.com/glossary/retrieval-augmented-generation.md)
- [Natural language processing (NLP)](https://skillalmanac.com/glossary/natural-language-processing.md)
- [Large language model (LLM)](https://skillalmanac.com/glossary/large-language-model.md)

## Sources

- [What is semantic search?](https://www.elastic.co/what-is/semantic-search), Elastic (accessed 2026-11-23)
- [Semantic search](https://www.pinecone.io/learn/semantic-search/), Pinecone (accessed 2026-11-23)
- [ColBERT: Efficient and Effective Passage Search via Contextualized Late Interaction over BERT](https://arxiv.org/abs/2004.12832v2), Khattab and Zaharia (accessed 2026-11-24)

Definitions are written by Skill Almanac from the sources above and checked against them on 2026-11-25. [Glossary index](https://skillalmanac.com/glossary.md).
