# File Search

The File Search tool lets the chatbot search within uploaded documents — retrieving specific information from PDFs, contracts, reports, and other files without you needing to manually locate the relevant section.

***

#### What It Does

When File Search is enabled and a file is attached to the chat, the model actively searches within the document to find and reference relevant sections when answering your prompt. For a full overview of how file uploads work and what formats are supported, see [Adding Context and Resources →](/chatbot/adding-context-and-resources.md)

Common use cases:

* Legal document and contract review
* Policy and compliance analysis
* Academic paper and research review
* Financial report analysis
* Locating specific clauses, figures, or sections in large documents

***

#### How to Enable It

Toggle **File Search** on in the Toolkit panel and attach your document to the chat. Reference the file in your prompt to direct the model's search.

**Example prompt:**

```
Search the uploaded contract and identify all clauses
related to payment terms and late fees.
```

{% hint style="info" %}
File Search is most effective on structured documents with clear sections, headings, or consistent formatting. Dense unstructured text may produce less precise retrieval.
{% endhint %}


---

# Agent Instructions: 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:

```
GET https://docs.qolaba.ai/chatbot/toolkit/file-search.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
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.
