Skip to content

Agent Trace Viewer

About Agent Trace Viewer

Visualize and debug AI agent execution traces. Supports LangChain runs, OpenAI Assistant steps, and generic JSON arrays with type/name/input/output fields. All processing happens client-side.

What This Tool Does

To inspect an AI agent trace or tool-call log step by step, paste the trace JSON into the Agent Trace Viewer. It auto-detects generic step arrays, LangChain run exports, and OpenAI Assistants step lists, then renders every LLM call and tool call on a timeline with inputs, outputs, duration, and token counts. Parsing runs entirely in your browser, so traces containing prompts or customer data never leave your device.

Use How to Use for execution steps and FAQ for constraints, policies, and edge cases.

Last updated:

This tool is provided as-is for convenience. Output should be verified before use in any production or critical context.

Agent Invocation

Best Path For Builders

Browser workflow

Runs instantly in the browser with private local processing and copy/export-ready output.

Browser Workflow

This tool is optimized for instant in-browser execution with local data handling. Run it here and copy/export the output directly.

/agent-trace-viewer/

For automation planning, fetch the canonical contract at /api/tool/agent-trace-viewer.json.

How to Use Agent Trace Viewer

  1. 1

    Paste or load your agent trace JSON

    Export trace JSON from your agent system. Paste into textarea or click 'Load Sample Trace' for example. Supports LangChain, OpenAI Assistants, or generic JSON arrays.

  2. 2

    Click 'Analyze Trace' to visualize

    Parser detects trace format automatically. Shows summary: total steps, token count, duration, error count. View as Timeline (visual bars) or Table (structured rows).

  3. 3

    Debug agent behavior

    Click any step to see full input/output, duration, token count. Look for tool failures, missing outputs, or loops. Filter by type (LLM, Tool, Error) to focus on issues.

  4. 4

    Search and filter steps

    Use text search to find specific tool calls or LLM outputs. Filter by step type. Measure efficiency: count steps, compare durations across runs.

Frequently Asked Questions

What is an agent trace?
An agent trace is a JSON log of every step an AI agent takes during execution: LLM calls, tool invocations, decisions, and errors. It's used for debugging and understanding agent behavior.
What trace formats are supported?
The viewer supports LangChain run format (with child_runs), OpenAI Agents SDK format (with steps and tool_calls), and generic JSON arrays containing step objects with type and input/output fields.
Can I debug LangChain agents with this tool?
Yes, paste LangChain's trace JSON to see a visual timeline of runs, child runs, and tool calls. Each step shows duration, token usage, and full input/output details.
Does this tool send my traces to a server?
No. All processing happens entirely in your browser. Your agent traces never leave your machine — nothing is sent to any server.
How is this different from Langfuse or AgentOps?
This is a quick paste-and-view tool with zero setup — no account, no backend, no SDK integration. For continuous production monitoring, use a full observability platform like Langfuse or AgentOps.

How do I inspect and debug an AI agent trace step by step?

Debugging an agent run means answering three questions: which steps ran, what each step received and returned, and where time and tokens went. The Agent Trace Viewer turns a raw trace log into a step-by-step timeline so you can answer all three without reading nested JSON by hand.

Step by step

  1. Paste the trace JSON. The viewer auto-detects the format — no configuration or schema mapping needed.
  2. Read the timeline view first. Each step is typed as an LLM call or a tool call, in execution order, so you can see the agent's decision loop at a glance.
  3. Expand any step to inspect its exact input and output payloads. This is where prompt bugs, malformed tool arguments, and truncated responses show up.
  4. Check per-step duration and token counts to find the slow or expensive steps in the run.
  5. Look for steps flagged as failed, then compare their input against the previous step's output — most agent failures are a mismatch between what one step produced and what the next step expected.
  6. Switch to the table view to scan long runs, sort steps, and compare many tool calls side by side.

Which trace formats does it accept?

Format Detected by Typical source
Generic step array Top-level JSON array of step objects Custom agent frameworks, hand-rolled logging
LangChain runs Object with a runs array LangChain / LangSmith run exports
OpenAI Assistants steps Object with a data array of run steps OpenAI Assistants run-steps API responses

Unrecognized structures produce an explicit format error rather than a partial render, so you know when a trace needs reshaping into one of the three shapes above.

Can I paste production traces safely?

Agent traces routinely contain system prompts, user messages, and tool credentials in argument payloads. This viewer parses and renders the trace entirely client-side — there is no upload, no storage, and no analytics on trace content. Closing the tab discards the data. Still, redact secrets before sharing screenshots of a rendered trace.