TraceRoachTrace
On this page
What's traced
- Org runs: the agent's span, a generation for each model turn, and a span for each tool call.
- RoachClaw chats and model calls, including calls other tools make to the model server.
Each trace records tokens (with how many were reused from the cache), cost, latency, time to first token, speed and scores. Model calls an Org agent makes to RoachNet's own model server carry a traceparent, so they land in the agent's trace.
Org › Traces shows them on the Mac.
Where traces live
In ~/RoachNet/storage/state/traces, in files only your account can read. Secrets are scrubbed from inputs and outputs before anything is written, and old traces are pruned.
Settings › RoachClaw › Tracing sets how long traces are kept, whether inputs and outputs are captured (and how much of each), and whether model-server calls are traced.
Send traces to Langfuse or OpenTelemetry
Export is off until you set it up. In Settings › RoachClaw › Tracing, give it a Langfuse or OpenTelemetry collector endpoint and any headers it needs, then send a test span. You choose whether inputs and outputs go with the traces.
Header values, such as API keys, are stored and never sent back by the API; only their names are. Exported traces leave your Mac for the endpoint you set, and nowhere else.
From a script
Read access is enough to list traces. With a read token in $TOKEN:
curl -s "$ROACHNET/api/traces?limit=10" -H "authorization: Bearer $TOKEN"GET /api/traces filters by kind, status, agentId, issueId, sessionId, runId, tag, q, from, to and companyId. Add content=1 to include inputs and outputs. Find the port and token shows where $ROACHNET comes from.