Skip to main content
An agent is a named actor responsible for a call (agentName). The Agents view rolls every trace up by agent, no matter which workflow it ran in, so you can answer “how is my retriever doing overall?” Set agentName on a call’s integration to fill this view.

Agents list

A card per agent over the selected range: span count (with the LLM-span subset), tokens, p95 latency, and cost, with an error badge when any of its spans failed. A toggle switches between cards and a compact table.

Agent detail

Opening an agent shows:
  • Stat cards: spans, error rate, p95 latency, and total cost.
  • Spans & errors and Latency: trend charts over the selected range.
  • Cost breakdown: a donut of cost per pricing dimension.
  • Prompt versions: the system prompts this agent has run with, grouped into versions (see below).
  • Trace flow: a graph of the agent’s most recent trace, with its steps and tool calls. Click through to the full trace.
  • Recent traces: the agent’s latest runs with spans, tokens, duration, and cost. Click a row to open the trace.

Prompt versions

Foglamp reads prompt versions off your runs — there is nothing to declare. When the SDK records a system prompt (on by default, see recordSystemPrompt), a background job groups the distinct prompts an agent has run with into versions:
  • Slots: content that changes between runs (a user’s name, a retrieved snippet, a date) is folded into the version’s template as a {…} line, so a personalized prompt is still one version.
  • Edits: when the prompt text changes and the new text keeps being used for later runs, a new version opens. A one-off variation does not.
Each version shows when it was first seen, how many runs used it and its share of all runs, and how many distinct prompt texts fold into it. Select a version to read its template beside the list or diff it against the previous version. To see the runs behind a version, use the Prompt version filter on the traces page; the v3 chip next to a trace’s system prompt links back here. The template reads as a document: headings, lists, and paragraphs are laid out, and values the versioning replaced ({date}, {id}, {n}, …) show as quiet tokens. Each slot is a varies per run chip; hover it to see the text runs actually put there, with how many runs carried each value. An estimated token count sits above the template. Use Raw to see the exact template text instead. Versions are inferred, so they can be re-grouped as more runs land — for example, a new prompt held with the current version until it has run a few times becomes its own version once it has.
Agents and workflows are independent views. An agent’s totals cover every workflow it took part in; a workflow groups whichever agents ran together in one process. Set both agentName and workflowName to get both views.