> ## Documentation Index
> Fetch the complete documentation index at: https://docs.switchagents.ai/llms.txt
> Use this file to discover all available pages before exploring further.

> ## Agent Instructions
> These docs moved from docs.flintai.dev to docs.switchagents.ai. Use docs.switchagents.ai for every link and request.
> To search these docs from an AI tool, connect the MCP server at https://docs.switchagents.ai/mcp. The page index is at https://docs.switchagents.ai/llms.txt.
> The source code for these products is public on GitHub. Switch Rooms: https://github.com/sandbox-quantum/switch. Switch Trust CLI: https://github.com/sandbox-quantum/switch-trust-cli. Switch Trust CodeScan action: https://github.com/sandbox-quantum/switch-trust-codescan-action. Switch Trust MCP server: https://github.com/sandbox-quantum/switch-trust-mcp. Switch Trust Python SDK: https://github.com/sandbox-quantum/switch-trust-sdk-py. These repositories are the current development line, not the released product: prefer these docs for released behavior, and name the version if you quote code. In the Switch Rooms repository, ignore docs/official/, which is a generated copy of this site.

# Agents

> Browse every agent Switch Trust found and open its full record

**The Agents page is your inventory of agents.** Everything Switch Trust finds in your code, plus every agent you connect through the SDK, lands here as one row you can open, sort, and search.

## The Agents list

Select **Agents** in the left navigation to open the list. Two cards sit above the table:

* **Total AI spend** - What all your agents together have cost this month against your overall cap, with the amount left
* **Spending cap summary** - How many agents with a cap are **Below cap**, **Near cap**, or **Over cap**, and how many have no cap set

The top bar also shows how many of your agents are **managed** (see [Managed agents](#managed-agents)).

Each row in the table is one agent. By default the table shows:

| Column | What it tells you |
| - | - |
| **Name** | The agent's name, and the fastest way to search the list |
| **Sessions (MTD)** | How many runtime sessions it has recorded month to date |
| **Cap usage (MTD)** | How much of its monthly cap it has used, or **No cap** |
| **Cost (MTD)** | What the agent has cost month to date |
| **\$/session (MTD)** | Its average cost per session, month to date |
| **Evaluation health** | How the agent scored under evaluation, where higher is better. Its **Evaluations** tab has the detail |
| **Highest severity** | The most serious open issue against the agent |
| **Issues** | How many distinct issues it carries |

Select the column control to show more, including **Description**, **Type**, **Library**, **Manufacturer**, **Supplier**, **Last seen**, and **Created at**. An agent with nothing outstanding shows a dash under **Highest severity** and **Issues**.

Cost figures are calculated from the per-token prices on [Model pricing](https://docs.switchagents.ai/switch-trust/cost/model-pricing.md), where you can set your own negotiated rates.

> [!TIP]
>
> Search the list by name to jump straight to a specific agent, and sort any column to line agents up by cost, severity, or when they were last seen.

**Highest severity** and **Issues** show which agents need attention first. To triage the findings from there, see [Discovery results](https://docs.switchagents.ai/switch-trust/discovery/results.md).

## Add agents

Select **Add agents** to choose how a new agent gets into your workspace:

* **Discover agents** - Connect a repository or cloud account and let a scan find the agents in your code. For more information, see [Discover your agents](https://docs.switchagents.ai/switch-trust/getting-started/discover.md).
* **Monitor & protect agents** - Install the SDK so the agent reports live sessions and runs behind guardrails. For more information, see [Monitor and protect](https://docs.switchagents.ai/switch-trust/getting-started/runtime.md).
* **Evaluate agents** - Add an agent for evaluation the same way you add one for monitoring, then configure the endpoint where Switch Trust reaches it. Switch Trust runs continuous red-team and quality assessment against it from there. For more information, see [Evaluations](#evaluations). You can also evaluate an agent from the command line with the source-available [Switch Trust CLI](https://docs.switchagents.ai/switch-trust-cli.md).

## Explore an agent

Select any agent to open it. The agent opens on its **Overview** tab, with **Improvements**, **Sessions**, **Issues**, **Assets**, and **Evaluations** beside it.

### Overview

The **Overview** tab gathers the agent's cost, its connections, and its profile in one place. The agent's name and description appear at the top, and a check icon beside the name marks a managed agent (see [Managed agents](#managed-agents)).

Cost cards report what the agent is spending:

* **Cost by month**, across a **Month**, **Quarter**, or **YTD** window
* **\$ per session**
* **Burn rate**, the current run rate
* **Monthly cap**, the agent's monthly spending budget, with **Set a cap** when none is set. See [Spending and caps](https://docs.switchagents.ai/switch-trust/cost/spending-and-caps.md)

Until the agent reports through the SDK, the cost cards prompt you to install it.

A **connections graph** shows the models, tools, MCP servers, and sub-agents the agent calls. Beside it, a **Connections & data sources** card lists how the agent is connected:

* **Code scanning** - The scan that discovered it
* **Evaluations** - Select **Set up evaluations** to connect it for evaluation (see [Evaluations](#evaluations))
* **Monitor & protect** - Select **Install SDK** to capture sessions and enforce guardrails

An **Issues** card reports what discovery found: the total, with Critical and High called out above a severity bar, so one Critical issue is easy to tell apart from a long tail of low-severity ones. For more information, see [Discovery results](https://docs.switchagents.ai/switch-trust/discovery/results.md).

The **Details** card is the agent's full profile. Fields that don't apply show a dash:

* **Name** and **Agent ID**
* **Library**, **Supplier**, and **Manufacturer**, for where it comes from
* **Locations**, the files it was found in
* **Description**, **Instructions**, and **Context**, for how it was briefed
* **Type**
* **Models**, **Tools**, **MCP servers**, and **Sub-agents**, for what it calls
* **Input guardrails** and **Output guardrails**, the protection attached to it
* **Last seen** and **Created**

### Improvements

The **Improvements** tab lists optimizations for the agent, to help you cut its spend. It shows what's driving waste and what to change to reduce it. Each optimization is based on how the agent has actually been used, not how it was built, so it reflects the sessions Switch Trust has recorded rather than everything the agent could do. This matters when you read a finding. A tool the agent rarely used in its recorded sessions gets flagged as unused, which doesn't mean it's unnecessary.

Switch ROI, a Switch Trust capability, analyzes the agent's recorded interactions automatically and re-runs the analysis as new sessions arrive, so the tab stays current. It shows the latest result for each optimization, with the date it was last analyzed.

Each optimization lists a confidence level, a short finding, and, for most optimizations, the estimated savings over a month. Expand a row to open its detail panel, which shows the full recommendation, the estimated 30-day savings, the confidence level, and a **Data analyzed** breakdown of the signals behind it.

Confidence is **High**, **Medium**, or **Low**, set by how much recorded data backs the finding rather than by the size of the saving. A small number of sessions produces *Low* confidence. An estimate projected from thin data can look large even while confidence stays *Low*. Weigh the confidence before acting on the number.

The tab reports these optimizations.

#### Model optimizations

Whether a cheaper model could do the agent's work for a comparable result.

**For example:** an agent runs every request on a top-tier model, but most of its sessions are simple extraction or classification that a smaller model handles at close to the same quality for a fraction of the cost.

The detail panel lists the models in use. When the agent is already on an appropriate tier, it recommends no change and estimates no saving.

#### Tool bloat

Tools the agent offers on every call but rarely invokes. Unused definitions add input tokens to every request.

**For example:** an MCP server exposes a dozen tools, but the agent only ever calls two. The other ten ship with every request as input tokens. That rounds to a fraction of a cent across a few sessions and becomes real money across tens of thousands.

The detail panel shows which tools were defined and which were used, and the tokens you could save by removing the unused ones.

#### Verbosity

Whether responses are longer than they need to be. This is the only optimization that answers with a plain Yes or No rather than a savings estimate.

**For example:** an agent wraps every answer in a boilerplate preamble and sign-off. The extra output tokens cost money on every call without adding information.

The detail panel reports the output-token distribution, including mean, median, and upper-percentile output tokens, and output spend as a share of total spend. It shows the verdict as **Candidate for verbosity optimization: Yes** or **No**.

#### Context cache waste

How much repeated context is re-read at full input price instead of the cheaper cache-read price.

**For example:** a support agent answers against a large knowledge base. If it re-reads the whole base on every question, each call pays full input price for the same context. Caching that context means later calls read it at the cheaper cache-read rate.

The detail panel shows the cache hit rate, cache invalidation events, the estimated cache waste cost, and how many sessions ran with a low cache rate or unbounded history. Switch Trust flags when caching is likely to help, but cannot tell you exactly what to cache.

#### Retry and loop waste

Wasted work repeated within a single session, reported per session rather than across sessions.

**For example:** within one session the agent calls the same tool with the same arguments several times, or a prompt is resubmitted almost unchanged. That repetition usually means a step is not succeeding on the first attempt, and each retry is billed.

The detail panel breaks out repeated tool use and duplicate prompts separately, each with the sessions affected, the occurrences, and the cost. Duplicate prompts are matched both exactly and by fuzzy near-match.

Switch Trust recommends each change, and you decide whether to make it. It doesn't change the agent or stop any spend, and there is no fixed marker on a finding. To confirm a change worked, apply it and watch the agent's later results.

### Sessions

Until the agent reports through the SDK, the **Sessions** tab shows **Set up agent monitoring**: install the SDK, generate an API token, select a guardrail policy, and add the environment variables and code. Sessions appear here once the agent starts processing requests. For more information, see [Monitor and protect](https://docs.switchagents.ai/switch-trust/getting-started/runtime.md).

### Issues

The **Issues** tab lists the findings open against this one agent, with **Assets analyzed**, **Severity**, and **Occurrences**. Select a finding to open its panel, then read the full record down to the line of code that triggered it. For more information, see [Discovery results](https://docs.switchagents.ai/switch-trust/discovery/results.md).

### Assets

The **Assets** tab shows the dependencies this agent uses, grouped into **Models**, **MCP Servers**, and **Tools**, each a searchable table, next to a connections graph. Select any asset to open its detail panel. For more information, see [Assets](https://docs.switchagents.ai/switch-trust/inventory/assets.md).

### Evaluations

The **Evaluations** tab runs continuous red-team and quality assessment against the agent: Switch Trust attacks it and scores how well it holds up.

Before the agent is connected, the tab shows **Connect this agent**. Set the **Agent type**, which is **Generic HTTP** by default, enter the **Endpoint** where the agent accepts requests, choose an **Authentication** method, and add any **Headers** it needs. Switch Trust supplies the attacker and judge models, so no provider key is needed. Select **Test connection** to confirm Switch Trust can reach the agent, then select **Save changes**.

Once connected, select **Assign evaluations** to choose which evaluations run against the agent and how often, such as weekly. The tab then fills in with:

* **Overall evaluation health** - The agent's current score, with the change since the last run
* **Frameworks & coverage** - The frameworks the assigned evaluations map to, such as **OWASP LLM Top 10**, and the specific risks each one covers
* **Overall health trend** - How the score has moved across runs

Below the cards, a table lists each assigned evaluation with its **Score**, **Trend**, **Status**, and **Last run**. An evaluation that hasn't run yet shows a dash until its first run completes. Open the options menu on any row to **Run now**, rather than waiting for the schedule, or to **Remove** the evaluation from the agent.

To change how Switch Trust reaches the agent, or to stop evaluating it, use **Connection settings**.

## Managed agents

An agent is **managed** once it has evaluations, session monitoring, or both. A managed agent reports live activity and runs behind the guardrails you set for it, so its record fills in with runtime data that a discovered-only agent doesn't have.

## Next steps

> [card] [Assets](https://docs.switchagents.ai/switch-trust/inventory/assets.md)
>
> Browse the models, MCP servers, and tools your agents depend on

> [card] [Discovery results](https://docs.switchagents.ai/switch-trust/discovery/results.md)
>
> Triage findings, confirm they're real, and know when they're resolved
