Learn

Vector search retrieves records by comparing the numerical meaning (embeddings) of a query against stored content to find semantically similar results, while keyword search retrieves records by matching the literal terms a query contains, so the two answer different retrieval questions over the same mission data.
Last updated: October 19, 2026
Why it matters to your mission. An analyst searching a classified corpus for "vessels evading sanctions" misses the report that only ever says "ships circumventing export controls," because a literal keyword index never saw those words as the same idea. Vector search closes that gap by matching meaning instead of spelling, and keyword search still pins down the exact selector, case number, or unit designator that meaning-based search blurs. The outcome is retrieval that surfaces the right record whether the query matches the words or the intent, so a decision rests on the full picture rather than the fraction a single matching method happened to return.
Vector search retrieves records by comparing the numerical meaning (embeddings) of a query against stored content to find semantically similar results, while keyword search retrieves records by matching the literal terms a query contains, so the two answer different retrieval questions over the same mission data. Vector search is also called semantic search, dense retrieval, or embedding search; keyword search is also called lexical search, full-text search, or sparse retrieval (BM25 and TF-IDF are the common scoring methods).
Neither is a newer version of the other. They fail in opposite directions. Keyword search misses anything phrased differently from the query; vector search can return something topically close but factually wrong for the exact identifier you needed. In most mission systems the question is not which one to pick but how to run both and govern the combined result.
Keyword search treats a query as a bag of terms and ranks documents by how often and how distinctively those terms appear, using scoring methods such as BM25 or TF-IDF. It is exact, fast, and transparent: you can see precisely which words caused a match. Its weakness is that it only matches the words present. A report that describes the same event in different language, a different transliteration, or an acronym the analyst did not type does not surface.
Vector search converts the query and every stored record into embeddings, which are lists of numbers that place text with similar meaning close together in a mathematical space. Retrieval then becomes a nearest-neighbor comparison: find the stored vectors closest to the query vector. This is what lets "ships circumventing export controls" match a query about "vessels evading sanctions" even with no shared words. Its weakness is the mirror image of keyword search: it can rank a semantically related but incorrect record above the exact one, and the reason for a match lives in opaque numbers rather than visible terms.
The practical contrast:
| Dimension | Keyword search (lexical) | Vector search (semantic) |
|---|---|---|
| What it matches | The literal terms in the query | The meaning of the query, via embeddings |
| Also called | Full-text search, lexical search, sparse retrieval (BM25, TF-IDF) | Semantic search, dense retrieval, embedding search |
| Handles synonyms and paraphrase | No; misses differently worded records | Yes; matches related meaning without shared words |
| Exact identifiers (selectors, case numbers, unit designators) | Strong; matches the string precisely | Weak; can blur an exact string into a similar one |
| Transparency of a match | High; you see which terms matched | Lower; the match is a distance between vectors |
| Index it needs | Inverted term index | Vector index with an embedding model |
| Typical failure | Misses relevant records phrased differently | Returns topically close but wrong records |
Reach for keyword search when the query is a precise string that must match exactly: a phone selector, a hull number, a case file ID, a named unit, a quoted phrase. In those cases a semantic match is a liability, because returning a record that is merely close to the identifier is worse than returning nothing.
Reach for vector search when the query is a concept and the corpus is unstructured prose written by many hands: open-source reporting, message traffic, human intelligence narratives, after-action write-ups. These are exactly the conditions where the same idea appears under many surface forms and a literal index leaves relevant records invisible.
Most mission questions contain both a concept and a constraint ("find reporting about sanctions evasion involving this specific vessel"), which is why production retrieval systems run hybrid search: execute both methods, then combine their rankings so the exact identifier and the semantic neighbors both get their due. The design decision is how to fuse the two scores, and whether a human can see why a record ranked where it did.
Vector search is the retrieval half of retrieval-augmented generation (RAG). RAG grounds a language model's answer in records pulled from an external source at query time rather than relying only on what the model memorized in training. The original formulation of RAG pairs a parametric model with a "dense vector index" accessed through a neural retriever (P. Lewis et al., Retrieval-Augmented Generation for Knowledge-Intensive NLP Tasks, NeurIPS 2020). That dense vector index is vector search.
For a defense or intelligence deployment, the quality of the retrieval step bounds the quality of everything the model says next. If vector search alone misses the exact selector in the query, or keyword search alone misses the paraphrased report, the generated answer inherits that gap and states it with unwarranted confidence. This is why mission-grade retrieval favors hybrid search feeding RAG, with provenance preserved so an analyst can trace each cited record back to its source and classification. Retrieval that cannot be inspected is not defensible in a briefing, regardless of how fluent the answer reads.
Yes. Federal agencies are adopting generative AI at scale, and the retrieval layer underneath it is now a governance concern, not a lab curiosity. The U.S. Government Accountability Office found that generative AI use cases across the agencies it reviewed increased roughly nine-fold in a single year, from 32 to 282 between 2023 and 2024, while agencies struggled to align that adoption with existing policy and guidance (GAO, Artificial Intelligence: Generative AI Use and Management at Federal Agencies, GAO-25-107653, 2025).
For the Department of War and the intelligence community, the practical consequence is that any generative system fielded on mission data depends on a retrieval step that is accurate, inspectable, and respectful of classification. Choosing vector search, keyword search, or a governed hybrid of both is a prerequisite for deploying generative AI that a commander can trust and an auditor can trace, not a tooling preference.
Three risks matter most for mission use:
None of these rules out vector search. They define what a mission-grade implementation has to add on top of it: provenance, classification awareness, and a keyword path for the queries that demand exactness.
Torch.AI builds government-owned reasoning infrastructure that the customer can own and govern, reasoning on top of existing systems of record rather than replacing them. Retrieval is one layer of that infrastructure, not a product in itself.
NEXUS makes mission data meaningful: it extracts entities and relationships from unstructured text and builds the semantic representation and embeddings that vector search runs over, so a corpus of reports becomes searchable by meaning rather than only by the words it happens to contain. Because that representation is interoperable and government-owned, the resulting index is not trapped in a vendor's proprietary semantic model. HALO makes the relationships understandable, fusing resolved entities into a graph so that retrieval can follow connections between records, not just rank individual documents. ORCUS is the data-availability layer underneath, connecting to multi-source data where it lives and carrying provenance and classification through the pipeline so retrieval stays inspectable and compartment-aware.
Keyword exactness, semantic recall, and graph context are composed together and governed as one, with every retrieved record traceable back to its source. You can see how this is packaged as a capability on the Torch.AI software page.
This sits alongside the broader retrieval and reasoning questions covered in the related explainers on knowledge graph vs vector database and RAG for defense.
Evaluating a capability? Bring these seven requirements to a scoping call and we will walk each one against your corpus and classification environment: request a technical walkthrough.
Keyword search matches the literal terms in a query and ranks records by how often and how distinctively those terms appear (using methods such as BM25 or TF-IDF); vector search converts the query and records into embeddings and finds the ones closest in meaning, so it can match paraphrases and synonyms the keyword index would miss. They fail in opposite directions and are often best combined.
Use keyword search when the query is an exact string that must match precisely, such as a selector, case number, or unit designator. Use vector search when the query is a concept and the corpus is unstructured prose where the same idea appears under many wordings. Most mission queries contain both, which is why hybrid search is common.
Vector search is the retrieval step in retrieval-augmented generation (RAG). RAG grounds a language model's answer in records pulled from an external index at query time, and the original formulation used a dense vector index as that retriever. The accuracy of retrieval bounds the accuracy of the generated answer.
The main risks are opaque matches an analyst cannot challenge, embeddings and indexes that carry the classification of their source and must respect releasability during retrieval, and missed exact identifiers when semantic similarity outranks a precise string. The mitigations are provenance, classification-aware retrieval, and a keyword path for exact queries.
In practice the terms are used interchangeably; semantic search is the goal (retrieval by meaning) and vector search using embeddings is the common technique that delivers it. Keyword search, by contrast, is lexical: it retrieves by matching terms, not meaning.
Describe the problem.
Define the constraints. We will structure the session.
No demo.
No slide deck.
Real work.
Describe the problem.
Define the constraints. We will structure the session.
No demo.
No slide deck.
Real work.