> For the complete documentation index, see [llms.txt](https://docs.uptiq.ai/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.uptiq.ai/core-concepts/knowledge-and-context.md).

# Knowledge & Context

A model knows what it was trained on. It does not know your credit policy, your product catalogue, or what your customer asked for last Tuesday. **Knowledge** is how you give an agent something to read that the model was never trained on.

The mechanism is retrieval: rather than putting everything in front of the model, the agent searches your material for the parts relevant to *this* request and pulls only those into context.

## Why retrieval instead of just uploading everything

Context is finite. A model can only hold so much at once, and filling it with material that isn't relevant to the current question makes answers worse, not better — the signal is still in there, but so is everything else.

Retrieval solves both problems: your knowledge can be far larger than any context window, and what reaches the model is the part that matters. The cost is that retrieval has to actually find the right material, which is why how you chunk, embed, and query is worth understanding rather than accepting by default.

* [**Learn How RAG Works**](/core-concepts/learn-how-rag-works.md) — the full picture: how retrieval-augmented generation works and why each stage exists.

## Getting knowledge into an agent

Two steps, and they're separate on purpose.

1. [**RAG Knowledge Pipeline**](/agent-builder/build/rag-knowledge-pipeline.md) — configure how material is ingested, chunked, and indexed. This is the orchestration layer, and it runs whether or not any particular agent uses the result.
2. [**Attaching Knowledge to an Agent**](/agent-builder/build/attaching-knowledge-to-an-agent.md) — point a specific agent at a knowledge container so its planner can query it.

Separating them means one body of knowledge can serve many agents, and an agent can draw on more than one.

## Knowledge is not memory

Easy to conflate, different in an important way.

* **Knowledge** is what you give the agent to read — deliberate, curated, the same for everyone.
* [**Memory**](/core-concepts/memory-and-learning.md) is what the agent carries forward from its own experience — accumulated, per-user or per-agent, and gated by approval where it changes behavior.

An agent answering "what is our maximum LTV?" is using knowledge. An agent remembering that *you* always ask about commercial rather than retail is using memory.

## How the agent reaches it

At runtime, the planner uses a knowledge-query skill to search attached knowledge — one of the platform-supplied skills every agent starts with. That means retrieval is subject to the same rule as everything else the agent does: if the skill isn't attached, the knowledge can't be reached, however well the pipeline is configured. See [Skills & Tools](/core-concepts/skills-and-tools.md).

## Where this is configured

* [RAG Knowledge Pipeline](/agent-builder/build/rag-knowledge-pipeline.md) — ingestion and indexing
* [Attaching Knowledge to an Agent](/agent-builder/build/attaching-knowledge-to-an-agent.md) — pointing an agent at a container
* [Data Skills (RAG)](/platform-resources/skill-library/data-skills-rag.md) — RAG Query, Vector Search, and Ruleset skills


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.uptiq.ai/core-concepts/knowledge-and-context.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
