Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.trymaitai.com/llms.txt

Use this file to discover all available pages before exploring further.

Every sampled production event produces a monitor_run with the verdict, the source event reference, the judge invocation reference, and a decorated trace of which conditions matched. The Portal surfaces these in three complementary views.

At-a-Glance

The top of the Monitor detail page shows a per-target rollup card for each attached target:
  • Sample count over the window
  • Pass / warning / error counts
  • Error rate
  • An error-rate sparkline (Robinhood-style — red line, no fill, brand error color)
  • Last-run timestamp
Use this to spot which target is misbehaving across a multi-target Monitor.

Activity chart

The Monitor Activity chart plots verdicts over time as a 100% stacked bar (pass / warning / error / failed) with absolute counts in the tooltip. Filters:
  • Targets — multi-select; defaults to all targets
  • Outcome — single-select; defaults to all outcomes
  • Bucket — hour / day depending on the time range
Hovering any bar shows the bucket window plus per-outcome % (count) breakdowns.

Runs

The Runs tab paginates monitor_run rows newest-first with filters by outcome, target, and time. Each row links to the underlying production event:
  • source_type=request → the chat completion request page
  • source_type=workflow → the workflow run page
  • source_type=agent → the agent session page
Drilling into a single run shows:
  • The verdict and matched outcome (error / warning / pass / failed)
  • The decorated resolution trace — the resolution AST with matched / actual annotations on each condition, so you can see exactly which clause fired
  • The runner output (when applicable)
  • The source event identifiers and the runner invocation identifiers
  • Runtime metadata (runner_duration_ms, error_message if the runner crashed)

“Is this Monitor healthy right now?”

For agents and dashboards, GET /monitors/{monitor_id}/metrics returns a single roll-up over a window: total sampled, pass/warning/error counts, rates, and the last-run timestamp. Add ?monitor_target_id=... for a per-target version. The reverse lookup GET /monitors/runs/by-source returns every monitor run that evaluated a given production event — useful for answering “what monitors fired on this request and what did they say?”.

Failed vs error

failed is reserved for runtime crashes (the runner itself blew up; we couldn’t compute a verdict). error is the normal “the resolution rule matched” case. They’re tracked separately so a noisy runner doesn’t silently inflate your error rate.