Summarize User Activity
user_activity_summarySummary KPIs for ONE end user's activity over a time window: trace count, LLM calls, error rate, failed vs errored traces, sessions, total/average cost, token usage, and latency and TTFT percentiles.
An "end user" here is the person your agents serve — the user.id your SDK
stamps via rius.user(...) / withUser(...) — not a Rius account. Use it when
someone arrives with a complaint and an identifier: "what did user u_8f2
experience this week" is one call, and the answer is a rollup rather than a
trace list you have to fold yourself.
Same read, same window and the same figures the Rius console's user page shows for that id, so a number you report and a number a human reads there are the same number. Field names match agent_traces_summary wherever they mean the same thing.
Read the Failed traces and Errored traces lines as the two different questions they are, and do not add them together or report one as "errors": a run whose ROOT span errored FAILED, while a run that errored somewhere and then recovered did not.
user_id: the end user's exact id, as list_agent_traces reports it in the
user_id column — read one off a listing rather than guessing. Matched
against any span of the trace, so a trace counts for this user if the user
scope was open anywhere inside it, not only at the root.
anonymous: summarise the traffic that carries NO end user instead. This is a
real subject, not an error case: it answers "what is happening to the runs
nobody attributed", and a high error rate there is worth knowing. It is the
console's ?user=anonymous. Pass either user_id or anonymous, not both.
workspace: optional workspace id, name, or org-name/workspace-name when the
same name occurs in two of your orgs (defaults to your default; use
list_workspaces to discover them).
hours: lookback window in hours (default 24), used for whichever of start/end
is not given.
start: optional absolute RFC3339 lower bound (e.g. "2026-08-01T00:00:00Z");
overrides the hours-derived value when given.
end: optional absolute RFC3339 upper bound; overrides the hours-derived value
when given.
filters: optional further {"field": ..., "op": ..., "values": [...]} clauses,
ANDed with the user scope — the same grammar and registry as
list_agent_traces. Call describe_search_catalog before guessing a key.
Example:
What did user u_8f2 experience in the last 24 hours?
{ "name": "user_activity_summary", "arguments": { "user_id": "u_8f2" } }How has that user's week been?
{
"name": "user_activity_summary",
"arguments": { "user_id": "u_8f2", "hours": 168 }
}How much of our traffic has no user attached, and is it failing?
{ "name": "user_activity_summary", "arguments": { "anonymous": true } }What did that user's gpt-4o runs cost?
{
"name": "user_activity_summary",
"arguments": {
"user_id": "u_8f2",
"filters": [{ "field": "model", "op": "eq", "values": ["gpt-4o"] }]
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| end | No | ||
| hours | No | ||
| start | No | ||
| filters | No | ||
| user_id | No | ||
| anonymous | No | ||
| workspace | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |