> For the complete documentation index, see [llms.txt](https://docs.flopsar.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.flopsar.com/user-guide/observing-and-diagnosing/ai-assistant.md).

# AI Assistant

The AI Assistant turns recorded performance data into a structured diagnosis. It does not guess from the conversation alone: when tools are enabled, the model asks the Flopsar server for the same analytics, call trees, and live agent facts you can see in the Workstation — always within **your** permissions and banned-application list.

An administrator must enable the assistant and choose a provider first. They also decide whether the model may query extra data, read recorded method arguments, or run live JVM queries. Settings: [AI Assistant](https://docs.flopsar.com/administrator-guide/ai-assistant.md). What can leave your infrastructure: [AI Assistant](https://docs.flopsar.com/security/ai-assistant.md).

You need the **Use AI assistant** permission and **View data**. Captured method arguments are sent to the model only if you also have **View parameters** and the administrator has turned **Allow call parameters** on. Live heap histograms, thread dumps, and similar queries require **Query agents** and **Allow live agent queries**.

<figure><img src="https://1957839935-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FQzShZISPoFZ9zIHUdjNB%2Fuploads%2Fgit-blob-f62890b2088a1d0c466f2662ae48b35cfaf5ffa3%2Fai_assistant_workspace.png?alt=media" alt="Analytics → AI Assistant with an empty conversation: Ask about any application, time range or bottleneck, the input field Ask about latency, errors, hotspots, call parameters…, and the Answer level selector"><figcaption><p>The free-form workspace before the first question.</p></figcaption></figure>

## Two ways to open it

### Free-form workspace

**Analytics → AI Assistant** is an open conversation. Nothing from a specific view is preloaded. Ask about any application, time range, or bottleneck you are allowed to see; the assistant fetches what it needs with tools. If the administrator has turned **Let the assistant query data** off, this workspace has nothing to fetch and cannot answer from telemetry.

Use **New conversation** to start over. **Export conversation PDF** downloads the current thread, including charts the assistant rendered.

### Grounded in the current view

From [Data Analysis](https://docs.flopsar.com/user-guide/observing-and-diagnosing/data-analysis.md), use **AI Analysis** after you have run a search. From a [method execution tree](https://docs.flopsar.com/user-guide/observing-and-diagnosing/method-execution-tree.md), open the **AI Assistant** tab. The aggregated call tree has the same tab. In those modes the assistant starts from the application, time range, and filters of the view you were looking at, even if tools are off.

## What the assistant can do

When tools are on, the model can:

* Summarize latency percentiles, error counts, and hotspots for an application and time range.
* Read the latency heatmap (time × duration), then drill into hotspots or an aggregated call tree.
* Find individual recorded calls and open their execution stacks.
* Look up class, method, and thread names so filters match what agents actually reported.
* Query a live instance (command line, JVM properties, packages, heap histogram, thread dump, agent logs, system metrics, detected Java errors) — only if live agent queries are allowed for you.
* List applications, profiles, plugins, data masks, and license status — still limited by your role.
* Read the [investigations](https://docs.flopsar.com/user-guide/observing-and-diagnosing/investigation.md) you may open: their findings, their evidence list, and summaries of the items. *Available since Flopsar 7.2.*
* Render findings, Mermaid diagrams, and charts in the conversation.

The assistant never sees applications on your banned list. It cannot change profiles, tokens, users, or server configuration.

{% hint style="warning" %}
If the provider is a public API, analytics aggregates — including class and method names — leave your infrastructure. Do not ask the administrator to enable **Allow call parameters** or **Allow live agent queries** unless that is acceptable for your environment. Heap histograms and thread dumps can pause a live JVM. See [AI Assistant](https://docs.flopsar.com/security/ai-assistant.md).
{% endhint %}

## Asking about an investigation

Ask about a case by its name, for example *What do we already know about INC-2381?* or *Does E3 show the same slowdown as today?* The assistant finds the investigation among those you may open, reads its findings and its evidence list, and then reads the items it needs. It refers to them as `[E3]`, the way the findings do, and keeps what investigators wrote apart from what agents recorded. *Available since Flopsar 7.2.*

You need **View parameters**, the permission that opens investigations, and the administrator must leave **Let the assistant query data** on. The assistant reads only the investigations you could open yourself: your own, those shared with you, and public ones. It skips the items of applications your role excludes and says how many it skipped. An investigation that the **Owner** role only lists for deletion stays closed to the assistant as well.

What the assistant gets from a copy is the same as what the [PDF report](https://docs.flopsar.com/user-guide/observing-and-diagnosing/investigation/report.md) shows:

| Item               | The assistant gets                                                                                                                                            |
| ------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| A call             | The root method, its duration and CPU time, the slowest path, the exceptions and business errors on the way, and the `call_id`                                |
| An analysis        | The period, the filters without their values, the percentile bands, the calls and exceptions over time, the instances, and the exceptions and business errors |
| An exception       | The class, the count, the methods that threw it, and the frames of the stack trace without the message                                                        |
| A thread dump      | When it was taken, and the number of threads in each state                                                                                                    |
| A Key-Value series | The key, the period, and the lowest, highest and last value with a few points over time for each instance                                                     |
| A correlation      | The parameter name, the period, and the calls that carried the value, without the value itself                                                                |
| An entry           | Its text                                                                                                                                                      |
| A file             | Its name, type and size; never its content                                                                                                                    |

Parameter values, exception messages and the stacks of a thread dump are never sent. The text people typed (findings, titles, notes and entries) goes through the [Data Masking](https://docs.flopsar.com/user-guide/setting-up-monitoring/data-masking.md) patterns before it is sent, as recorded parameters are when the agent records them.

The copies outlive the recorded data. To look deeper, the assistant queries the period, the application or the method that an item names. While a kept call is still in storage, it can also open the call again with its `call_id`. The assistant cannot change an investigation or add evidence to it; you do that in the **Investigation** view.

Every item the assistant reads is recorded in the audit trail as `evidence_view` with the reason `read by the AI assistant`, besides the `ai_query` record of the tool call.

## Expertise and language

Each conversation can use Simple, Medium, or Advanced answer level, or **Server default**. The administrator sets that default under **Administration → AI Assistant**; your last explicit choice is remembered in this browser. Class, method, and exception names are never translated, even when the answer language is not English.
