# Give your agent knowledge

> Add documents such as policies and FAQs in Agents > Context, then turn them on for the agent in its Conversation tab.

Source: https://useline.io/help/ai-agents/agent-knowledge  
Section: AI agents  
Last updated: 2026-11-05  
Roles: Owner, Admin

Your agent answers from the documents in your library. You add documents in **Agents** > **Context**. Then you select which documents each agent can use.

## Before you start

- You need the **Owner** or **Admin** role to add or change library items. Every member can view them.

## The library

The **Library** group in the **Agents** menu holds content that all your agents share:

| Page | What it holds |
|------|---------------|
| **Guidance** | Company rules that every agent follows, such as tone of voice. |
| **Context** | Documents: policies, FAQs, price lists and other written content. |
| **Properties** | Details that agents capture in a conversation, such as an order number or a postcode. |
| **Goals** | What a good outcome looks like for a type of conversation. |
| **Procedures** | Step-by-step instructions for one kind of request. |
| **Tools** | The tools that agents are allowed to use. |

## Add a document

1. Open **Agents** > **Context**.
2. Select **New document**.
3. In **Title**, type a name, for example "Refund policy".
4. In **Label — when should an agent use this?**, tell the agent when to open the document. For example: "Use when the customer asks about refunds or returns."
5. In **Content**, paste or type the text.
6. Optional: in **Website source (optional)**, type the address of a page on your website.
7. In **Prompt inclusion**, select **Fetched on demand (recommended)** or **Always in the prompt**.
8. In **Audience**, select **All agents** or **Selected agents**. If you select **Selected agents**, select each agent.
9. Select **Save**.

Write the label for the agent, not for people. The agent reads the label to decide if the document is relevant.

## Choose between the two inclusion settings

| Setting | What happens |
|---------|--------------|
| **Fetched on demand (recommended)** | The agent reads the label. It opens the full text only when the label matches the question. Use this for long documents. |
| **Always in the prompt** | The agent gets the full text in every conversation. Use this only for short facts. |

## Update a document from your website

If a document has a website source, you can copy the page text again.

1. Open **Agents** > **Context**.
2. Open the menu on the document.
3. Select **Sync from website**.

Line replaces the document content with the text from the page.

## Turn knowledge on or off for one agent

1. Open **Agents**, then select **Manage agent** on the agent.
2. Open the **Conversation** tab.
3. In the **Knowledge** card, turn each document on or off.
4. Select **Save draft**, then **Publish**.

The **Knowledge** card also has two switches:

- **Customer details** loads the contact's name, numbers and open cases when a conversation starts.
- **Recent cases** adds the status and channel of the customer's five most recent cases. It never adds the messages.

## When changes apply

- A change to a document's text applies to live agents at once.
- A change to which documents an agent uses applies only after you publish the agent.

## Common problems

**The agent does not use a document.** Make sure that the document is turned on in the agent's **Knowledge** card, and that the agent is published. Then make the label more specific. The agent opens a document only when the question matches it.

**The agent says it does not know.** The agent uses only the parts of a document that match the words of the question. If no words match, the search returns nothing. Add the missing fact to a document, in the words that customers use.

**I cannot see New document.** You need the **Owner** or **Admin** role.

## Related articles

- [Create an agent](https://useline.io/help/ai-agents/create-an-agent.md): In Agents, select Create agent, give it a name and an optional template, set it up, then publish it and add it to a workflow.
- [Test your agent before it goes live](https://useline.io/help/ai-agents/test-your-agent.md): Use the agent's Test tab to chat with the draft on each channel. Nothing is sent or changed. Then check live runs in Activity.
- [Use the Line Assistant for your team](https://useline.io/help/ai-agents/workspace-assistant.md): Line Assistant works for your team, not your customers. Message it in team chat, email it or text it to update knowledge, draft workflows and review your account.
- [How AI agents work in Line](https://useline.io/help/ai-agents/how-agents-work.md): An agent answers calls, texts, WhatsApp, Web Chat and email for you. It replies only when a workflow has an Agent step that names it.
