---
title: "What is grounding in LLMs? Answers tied to sources | BroadRouter"
description: "Grounding ties an LLM answer to sources you supply, such as documents, search results or database rows, so claims can be checked. Methods and limits."
url: https://broadrouter.com/glossary/grounding/
lang: en
updated: 2026-11-14
publisher: BroadRouter (a BroadNet site); API by BroadNet Inference, https://inference.broadnet.ai
---

# Grounding

Updated 2026-11-14

Grounding is the practice of connecting a language model's output to specific, verifiable sources of information, such as supplied documents, search results or database records, and instructing it to answer from them. Grounded answers can be traced back to a source and are less likely to contain made-up facts.

Also called: grounded generation, source grounding, grounded answers

An ungrounded model answers from memory. A grounded one answers from the page in front of it.

## How it works

Google’s Vertex AI docs define grounding as “the ability to connect model output to verifiable sources of information.” The source can be a web search, your own documents, a map service or a database. Whatever the source, the pattern has three parts:

1.  **Fetch evidence** for the question: retrieved passages, a whole file, an image of an invoice, rows from SQL.
2.  **Put it in the prompt** with an instruction to answer only from it.
3.  **Make the answer checkable** with quotes, citation markers or links back to the source.

Retrieval-augmented generation is the best-known method. Lewis and colleagues paired a generator with a “dense vector index of Wikipedia”, reached by a neural retriever, and reported answers that were more specific and more factual than a model working from its parameters alone. Building that index uses [embeddings](https://broadrouter.com/glossary/embeddings/) and often a [vector database](https://broadrouter.com/glossary/vector-database/).

A minimal grounded prompt:

```text
Answer using only the policy below. Quote the sentence that supports your answer.
If the policy does not answer the question, reply "Not in the policy."

<policy>Refunds are available within 14 days of purchase.</policy>

Question: Can I get a refund after three weeks?
```

A grounded reply says no and quotes the 14-day sentence. An ungrounded model might guess a 30-day policy that sounds normal.

For long inputs, Anthropic suggests a quote-first step: for documents over 20,000 tokens, have the model extract word-for-word quotes, then answer from those quotes only.

## Why it matters

-   **Fewer made-up facts.** Google lists reduced hallucinations as a core benefit. Grounding is the most direct fix for [hallucination](https://broadrouter.com/glossary/hallucination/) about your own data.
-   **Fresh information.** Model weights are frozen at training time. Grounded sources can change daily without retraining.
-   **Auditability.** A claim with a quote can be checked by a person or by code.
-   **Cost trade-off.** Evidence is input tokens. Retrieving five passages is cheaper than sending a whole manual, but may miss the passage that matters. Very long prompts also risk [lost-in-the-middle](https://broadrouter.com/glossary/lost-in-the-middle/) recall.

## On BroadNet Inference

BroadNet’s docs do not list an embeddings endpoint, a search tool or a citations feature, so retrieval runs in your code. What the API gives you is room for evidence: a 1,048,576-token [context window](https://broadrouter.com/glossary/context-window/) on DeepSeek V4.1 Flash and GLM 5.3, 262,144 on Qwen3.8 27B, and image input on the models whose docs entry says images or vision. That makes “paste the whole document” a real option; [long context vs RAG](https://broadrouter.com/blog/long-context-vs-rag/) compares the cost of each, and the [invoice guide](https://broadrouter.com/guides/read-arabic-invoices-with-vision/) grounds extraction in a scanned image.

## Questions

### Is grounding the same as RAG?

RAG is one way to ground. It retrieves passages and adds them to the prompt. You can also ground by pasting a whole document, attaching an image, or adding live search or database results.

### Does grounding guarantee a correct answer?

No. The model can still misread or ignore the source. Ask for quotes or citations and check that each one exists in the source.

### How do I make an LLM answer only from my documents?

Supply the documents, tell the model to use only them, allow it to say the answer is not there, and require a quote for each claim.

## See also

-   [Hallucination](https://broadrouter.com/glossary/hallucination/) (term)
-   [RAG (retrieval-augmented generation)](https://broadrouter.com/glossary/rag/) (term)
-   [Embeddings](https://broadrouter.com/glossary/embeddings/) (term)
-   [Context window](https://broadrouter.com/glossary/context-window/) (term)
-   [Vector database](https://broadrouter.com/glossary/vector-database/) (term)
-   [Lost in the middle](https://broadrouter.com/glossary/lost-in-the-middle/) (term)
-   [Read Arabic invoices and receipts with a vision model](https://broadrouter.com/guides/read-arabic-invoices-with-vision/) (guide)
-   [Long context vs RAG: when 1M tokens replaces a vector DB](https://broadrouter.com/blog/long-context-vs-rag/) (article)
-   [Arabic RAG: normalisation, chunking and retrieval that works](https://broadrouter.com/blog/arabic-rag-search/) (article)

Try it on your real workload. New accounts start with $5 of credit for Gemma and transcription. DeepSeek, GLM and Qwen3.8 need a top-up.

[Get started](https://inference.broadnet.ai/account/?utm_source=broadrouter&utm_medium=referral&utm_campaign=glossary-grounding&utm_content=page-cta) ·

**Sources**

-   [Google Cloud, grounding overview (Vertex AI)](https://docs.cloud.google.com/vertex-ai/generative-ai/docs/grounding/overview)
-   [Lewis et al. (2020), Retrieval-Augmented Generation for Knowledge-Intensive NLP Tasks](https://arxiv.org/abs/2005.11401)
-   [Anthropic, reduce hallucinations (direct quotes and citations)](https://platform.claude.com/docs/en/test-and-evaluate/strengthen-guardrails/reduce-hallucinations)
-   [BroadNet Inference API reference, model IDs and context](https://inference.broadnet.ai/docs?utm_source=broadrouter&utm_medium=referral&utm_campaign=glossary-grounding&utm_content=sources#models)
