> For the complete documentation index, see [llms.txt](https://docs.sprinthub.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.sprinthub.com/en/topics/artificial-intelligence/ai-agents/ai-agents-database.md).

# AI Agents - Database

## Database Settings

This Agent capability allows searching for information in files, spreadsheets, websites, and text entered directly, aiming to improve its performance in its actions and in conversation with the lead.

<figure><img src="https://684109703-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F9FzUKkagBNy5uQ7AtGNa%2Fuploads%2F2NXKgkXsNSJaYwlc7Kg3%2FGroup%2017.png?alt=media&amp;token=d736c872-619e-48e4-8e43-f26208556007" alt=""><figcaption></figcaption></figure>

### Q\&A Import Format

The spreadsheet must contain two columns: one for the questions and another for the respective answers. The question and answer pairs must be entered starting from the second row, since the first row will be ignored.

After adjusting your spreadsheet format, click the 'Import CSV' button if the file is CSV, or 'Import XLSX' if it is XLSX.

<figure><img src="https://684109703-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F9FzUKkagBNy5uQ7AtGNa%2Fuploads%2FiBiVquyhvg4A6QX2cUK0%2FGroup%2018.png?alt=media&amp;token=b2d99b02-3323-4e15-920b-7d5948d596e3" alt=""><figcaption></figcaption></figure>

<figure><img src="https://684109703-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F9FzUKkagBNy5uQ7AtGNa%2Fuploads%2F6SiI877AlotE7tJwJcV5%2Fimage.png?alt=media&amp;token=1a098a2b-3221-4d32-a4d1-7f215eb2494b" alt=""><figcaption><p><em>Question and answer spreadsheet format.</em></p></figcaption></figure>

### Website Extraction

To extract a website, it is first necessary to map it. To do this, you must provide the URL or route from which the mapping should be performed, either at the root or, for example, at **/produtos**, checking the option 'Extract only the URL above?'. Then simply click the 'Map' button.

<figure><img src="https://684109703-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F9FzUKkagBNy5uQ7AtGNa%2Fuploads%2F9yfXMG9Pv8z5DQQTTMO2%2F1.png?alt=media&amp;token=6e420b77-7ec2-40ef-97a1-a2e7b721f0e4" alt=""><figcaption></figcaption></figure>

### Selecting the Extraction Method

Extraction can be done either with SprintHub's native tool or via the Firecrawl platform. Currently, [Firecrawl offers a free plan with 500 credits](https://www.firecrawl.dev/pricing), allowing extraction of up to 500 pages. It is recommended for more precise extractions and for websites protected against crawling bots.

<figure><img src="https://684109703-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F9FzUKkagBNy5uQ7AtGNa%2Fuploads%2F9DYY3C7WIKl9vwLO5rIy%2Fimage.png?alt=media&amp;token=c92437c0-7211-43e3-92ad-ffe3a5bab2b4" alt=""><figcaption></figcaption></figure>

### Dynamic Extraction or Recurring Extraction

To keep the website data always up to date, it is possible to configure the 'Dynamic Extraction' option. In this mode, up to 20 pages from the extraction will be updated daily. To optimize the process, it is recommended to define a URL path that contains only the information that changes frequently. In addition, the 'Do not extract URLs containing' feature can be used to exclude certain paths or keywords from the extraction.

<figure><img src="https://684109703-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F9FzUKkagBNy5uQ7AtGNa%2Fuploads%2Fhs6sS7Kh6Yv5rTY0MHOt%2Fimage.png?alt=media&amp;token=d90ae294-2401-401e-ba22-aeb9887d4d6c" alt=""><figcaption></figcaption></figure>

### Link: How to Use Restriction by Tag/Class/ID

{% content-ref url="/pages/4a10fb09c6154a15fb2816611c91e9135a095d1f" %}
[AI Agents - How to Use Tag/Class/ID Restriction](https://docs.sprinthub.com/en/topics/artificial-intelligence/ai-agents/ai-agents-how-to-use-tag-class-id-restriction.md)
{% endcontent-ref %}

### Files

When importing files, they are automatically transcribed, and just like the website pages, it is possible to view and edit the text resulting from the extraction.

**Observation**: To extract files, you need to have a Gemini API key.

**Accepted file formats**: pdf, mpeg, mp3, wav, jpeg, mp4, mpg, avi, text/plain, csv, json, png (up to 50 MB per file).

<figure><img src="https://684109703-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F9FzUKkagBNy5uQ7AtGNa%2Fuploads%2FKuHg22wmkGBiVWpTu9DG%2Fimage.png?alt=media&amp;token=d9796af9-2394-4583-9573-f71407e8a00f" alt=""><figcaption></figcaption></figure>

<figure><img src="https://684109703-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F9FzUKkagBNy5uQ7AtGNa%2Fuploads%2F2LX2dDoE3GZTgLfWQEnt%2Fimage.png?alt=media&amp;token=6aeedac2-aefe-4e38-8c1e-771993406224" alt=""><figcaption><p><em>Edit File Screen (extracted).</em></p></figcaption></figure>

### Text

In the field below, information can be entered for the agent to consult during the conversation with the lead. This field should contain only informational data, without rules, orders, or behavioral restrictions (this should be provided in the tab **Contextualization**).

<figure><img src="https://684109703-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F9FzUKkagBNy5uQ7AtGNa%2Fuploads%2F1ZH2Uie86Yhhlvsk3vw4%2Fimage.png?alt=media&amp;token=8f4ba874-8ee0-42da-9416-3d5ae3505ece" alt=""><figcaption></figcaption></figure>
