> For the complete documentation index, see [llms.txt](https://help.theaffiliateplatform.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://help.theaffiliateplatform.com/ai-agents/ai-assistant.md).

# AI Assistant

The **AI Assistant** is an AI chat inside the TAP BackOffice. The chat answers questions about the product and about your data.

TAP includes two AI agents in the Back Office: the **Product Expert**, which answers questions about how TAP works, and the **Data Analyst**, which answers questions about your own data.&#x20;

## Open the AI Assistant

Click the AI button at the bottom right of the Back Office (its tooltip says **Ask AI Assistant**). The **AI workspace** opens over the page you are on.

<figure><img src="https://2789002490-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fkbip9hFgRFwIv4mXJPnz%2Fuploads%2FmPuebqSSXBUEMxmD9qOF%2Fimage.png?alt=media&amp;token=c00105ed-8550-456e-8e4d-a8c6d4c41905" alt=""><figcaption><p>AI Assistant button</p></figcaption></figure>

## What you can ask <a href="#who-can-use-the-agents" id="who-can-use-the-agents"></a>

* **Product questions:** how a feature works and how to set it up. Questions related to affiliate accounts, deals, commission calculations, postback configurations, APIs and more. The answers come from the TAP help center, with links to the sources.
* **Data questions:** dimensional and aggregated data about your affiliates, players, visits, campaigns, deals and more. The assistant reads your label's data warehouse, shows tables and charts.

The AI Assistant can't create, edit or approve anything in the BackOffice. Ask the assistant to show you the steps and make the change.

{% hint style="success" %}
Write in your own language: the assistant answers in the language of your question.
{% endhint %}

## How to use it

1. Click **New chat**, or pick one of the examples under **What do you want to know?**.
2. Type your question in the box (**Ask about the product or your data…**) and press Enter.
3. Wait for the answer. You see what the assistant is doing while it works. Click above an answer to see the steps it took. Hover over the tokens counter below an answer to get details on the tokens usage.
4. Ask follow-up questions in the same chat. The assistant remembers the chat.
5. Rate the answer with the thumbs up or down. Our AI team reads this feedback.

### The workspace <a href="#the-workspace" id="the-workspace"></a>

* **The chat list** on the left: search your chats and messages, start a **New chat**, and open earlier chats. Pin, rename or delete a chat from its menu.

<figure><img src="https://2789002490-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fkbip9hFgRFwIv4mXJPnz%2Fuploads%2FxXFFmCXwDrB1DOMQTwes%2Fimage.png?alt=media&amp;token=d85a87e6-92b3-4c2f-8ad3-d3010a97e77e" alt=""><figcaption><p>AI workspace: Chat list</p></figcaption></figure>

* **Actions of this chat** (the three dots on the right): Copy a link to the chat, **export chat to PDF**

<figure><img src="https://2789002490-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fkbip9hFgRFwIv4mXJPnz%2Fuploads%2FQ3xRK7pIBjerjuZwyaAs%2Fimage.png?alt=media&amp;token=a5220e75-4d58-4f42-b9f9-90546ad77a1b" alt=""><figcaption><p>AI workspace: Actions of this chat</p></figcaption></figure>

* **+** in the question box: **Attach a picture or CSV** (a CSV up to 5 MB, 100,000 rows and 50 columns)<br>

  <figure><img src="https://2789002490-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fkbip9hFgRFwIv4mXJPnz%2Fuploads%2FCjUuV5O4dNtOabrr1sH0%2Fimage.png?alt=media&amp;token=b53cda08-c02d-4930-b9c4-cf26573b7244" alt=""><figcaption><p>AI workspace: Question box attchments</p></figcaption></figure>

* The **model picker** sits next to the send button.<br>

  <figure><img src="https://2789002490-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fkbip9hFgRFwIv4mXJPnz%2Fuploads%2F3WIxyMXUDSS3L1GIw0Zg%2Fimage.png?alt=media&amp;token=24664895-bff8-417c-bea3-80d1d33bfb81" alt=""><figcaption><p>AI workspace: Model picker</p></figcaption></figure>

  <br>

* **Tokens used** at the top shows how much of your organization's monthly AI tokens is used.<br>

  <figure><img src="https://2789002490-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fkbip9hFgRFwIv4mXJPnz%2Fuploads%2FWhGKqvkt4LaGfRtk9JZ2%2Fimage.png?alt=media&amp;token=2cd58fd3-b23f-46d9-8bd9-149e190d298d" alt=""><figcaption><p>AI workspace: Tokens used</p></figcaption></figure>

### Tips for good answers:

1. **Be specific.** Instead of "Tell me about pixels", ask "How do I set up a S2S pixel for registration event?"
2. **One topic at a time.** Ask about one feature per question.
3. **Use follow-ups** to refine or expand an answer.

## What you see in each answer <a href="#what-you-see-in-each-answer" id="what-you-see-in-each-answer"></a>

* The help articles used to build the answer
* Thumbs up / thumbs down feedback; our AI engineers review it to improve the agent
* Token usage (click or hover the coin icon under the answer) and the agent's live reasoning steps<br>

## Who can use the AI Assistant

<table><thead><tr><th width="206.5">Role</th><th width="263.3333740234375">Product Questions</th><th>Data Questions</th></tr></thead><tbody><tr><td>Affiliate Admin</td><td>Yes</td><td>Yes</td></tr><tr><td>Affiliate Manager </td><td>Yes</td><td>No</td></tr><tr><td>Affiliate Admin, Limited</td><td>Yes</td><td>No</td></tr><tr><td>Affiliates</td><td><em>AI Assistant is not available for affiliates</em> </td><td><em>AI Assistant is not available for affiliates</em> </td></tr></tbody></table>

## Token limit <a href="#token-limit" id="token-limit"></a>

AI usage is limited to **10,000,000 tokens per organization/home label per month**, shared by all users and all agents in your setup. This covers the daily needs of most organizations. If you need more, contact your Success Manager. \
Monthly available tokens and token consumption details for your organization are available in the top right corner of the opened chat.\
\
**What is a home label?** Your home label is the label your BackOffice account belongs to. All your AI usage is counted there, even when you work in another label you have access to. Switching labels does not change where your usage is counted.

{% hint style="info" %}
**What is a token?** Tokens are the small units of text an AI model processes: words, word parts, numbers or punctuation. Every question uses input tokens (your question and instructions) and output tokens (the answer or generated query). The agents also use tokens when they read your data warehouse.
{% endhint %}

## Product Questions <a href="#tips-for-better-answers" id="tips-for-better-answers"></a>

You can ask questions about how a feature works and how to set it. Questions related to affiliate account settings, deals, commission calculations, postback configurations, APIs and more. The answers come from the TAP help center, with links to the sources.

### Example questions <a href="#example-questions" id="example-questions"></a>

* **Feature discovery:** "What commission types are available in TAP?"
* **Configuration:** "How do I configure a pixel for an affiliate?"
* **Best practices:** "How do I make an affiliate earn 150 EUR CPA only for players registered from Spain and Mexico, while getting 50 EUR CPA for traffic from other countries?"
* **Troubleshooting (theory):** "Why might an affiliate not see their tracking links?"
* **API usage:** "How do I get a list of affiliates over the API?"

<figure><img src="https://2789002490-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fkbip9hFgRFwIv4mXJPnz%2Fuploads%2F9GSLNfikNwBJmX8xgTJo%2Fimage.png?alt=media&amp;token=77398d10-1585-4324-abda-d40e7fc20ea0" alt=""><figcaption></figcaption></figure>

## Data Questions <a href="#tips-for-better-answers" id="tips-for-better-answers"></a>

You can ask questions about the affiliates' and player's dimensional and aggregated data, as well as data related too visits, campaigns, deals and more. The AI assistant is using the same dataset as the one available to you in the [Smartico Data Warehouse](https://help.smartico.ai/welcome/technical-guides/smartico-data-warehouse). You can refer to the documentation to understand the dataset, its columns, and their semantics. \
The AI Assistant

To see the charts and full table, click on

<figure><img src="https://2789002490-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fkbip9hFgRFwIv4mXJPnz%2Fuploads%2Fs52GMw4vAlDVTYOwsNvk%2Fimage.png?alt=media&amp;token=ec6d2a4e-d0f4-4d4b-bb5c-39246bca5e18" alt=""><figcaption></figcaption></figure>

{% hint style="info" %}
Note that the available data depends on your system integration and usage. If your integration doesn't provide 'chargebacks' as part of data transfer to TAP, then you won't be able to analyze the data based on this value.
{% endhint %}

### Example questions <a href="#example-questions" id="example-questions"></a>

* How many registrations did each affiliate bring last month, and what share reached a first deposit?
* How many deposits were brought in September 2026 by the 10 worst performing affiliates (per number of new acquistions/registrations during 2026)?
* How much was generated in sub-affiliate commission for affiliate JohnDoe123 by their sub-affiliate network in October 2025?
* How much CPA and how much RevShare did we pay by brand last month?
* List affiliates that have more than one active deal and the deal types they have
* How much did we pay each affiliate in the last 6 months, by month?
* How many new affiliates joined each month this year, and how many of them have at least one registration?

### Tables, charts and CSV export <a href="#tables-charts-and-csv-export" id="tables-charts-and-csv-export"></a>

* The in-chat table shows up to **1,000 rows**, with summary statistics (minimum, maximum, average, distinct counts).
* **Export to CSV** downloads the full result, up to **500,000 rows**. Internal numeric IDs are replaced with readable names in the export.
* For summaries, trends and comparisons of up to 50 categories, the agent draws an interactive chart (bar, line, area or pie). For detailed listings and single-record lookups, it shows a table.

## Query safety <a href="#query-safety" id="query-safety"></a>

* Queries run only against your own isolated DWH dataset.
* All queries are **read-only**. Inserts, updates, deletes and drops are blocked before they run.
* For queries that scan a lot of historical data, the agent does a dry run first and may ask you to confirm.

## FAQ <a href="#faq" id="faq"></a>

**Q: Why did the assistant say it couldn't find documentation?**&#x20;

A: The topic can't be found in the TAP Help Center or your wording didn't match it. Try TAP terms or name the feature.<br>

**Q: Can the AI assistant change a deal, payment or affiliate?**&#x20;

A: No. It only reads help pages and your data.<br>

**Q: Why can't I ask data questions?**&#x20;

A: Data questions need the Affiliate Admin role and the data feature enabled on your account. Contact your admin to enable it.<br>

**Q: Can other clients see my data through the assistant?**&#x20;

A: No. Each label's data is kept separate, and queries on other labels are rejected.<br>

**Q: Can I see the query behind a result?**&#x20;

A: The result is saved with the chat. Ask the assistant to explain how it calculated the figure.<br>

**Q: Can I use it on another label?**

A: Yes. A chat belongs to the label you are on. Switch the label in the Back Office, and the assistant works with that label's data.<br>

**Q: Where can I see how many AI tokens my query consumed?**

A: Hover over or click the coin icon at the bottom of any assistant message to view the token breakdown, including input, thinking, and output tokens.


---

# 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 by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://help.theaffiliateplatform.com/ai-agents/ai-assistant.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

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.
