TraceMetis structures raw agent traces into hierarchical goals and evidence cards for human review and auditing.
Claude Code · Codex · Cursor · WorkBuddy · Antigravity · Pi
English · 简体中文
Interactive demo · Install · User study · How it compares · Why we built it
What it makes · Verified runs · Quickstart · Models & dials · How it works · Architecture
npx tracemetis web --open
TraceMetis-showcase-en.mp4
You can play with TraceMetis in our online interactive demo.
中文版
TraceMetis-showcase-zh.mp4
Full Demo
TraceMetis-promo-en.mp4
中文版
TraceMetis-promo-zh.mp4
How It Works
TraceMetis-deck-en.mp4
中文版
TraceMetis-deck-zh.mp4
Point TraceMetis at any agent session on your computer—or follow one across hours or days while it is still running:
- "The final
Proposal.mdreads cleanly—what silent compromises or failed attempts happened along the way?" - "Where did Codex abandon its first approach, and what concrete error forced the pivot?"
- "Did the run honor every rule in
BRIEF.mdandSKILL.md, or quietly skip a verification stage?" - "I am picking up a 400-step session on a remote SSH box—what is done, what failed, and what is still open?"
TraceMetis coalesces low-level events into numbered actions, reconstructs the missing means–end goal hierarchy batch by batch under deterministic structural invariants, synthesizes 30-second evidence cards, and exports one self-contained .html file you can open from disk with zero network requests.
Requires Node.js 24+.
npm install -g tracemetis
tracemetis web --openOr run it once without installing:
npx tracemetis web --openweb starts the local loopback workbench on 127.0.0.1 and opens it in your browser.
Copy the prompt below into WorkBuddy, Claude Code, Codex or another agent. It installs Node.js 24 or makes it the default if needed, then installs and opens TraceMetis.
Prompt for your agent
Please install TraceMetis (https://www.npmjs.com/package/tracemetis) on this machine and open its local web workbench. TraceMetis requires Node.js 24 or newer.
1. Run `node -v` and `which -a node` (on Windows: `where node`) to see the current Node.js version and every node on PATH.
2. If node is missing, or the default is older than v24:
- If a version manager is installed (nvm, fnm, volta, asdf, mise, or n), use it to install Node.js 24 and make it the default, e.g. `nvm install 24 && nvm alias default 24`, `fnm install 24 && fnm default 24`, or `volta install node@24`.
- Otherwise install Node.js 24 the standard way for this OS (Homebrew on macOS, the official installer or winget on Windows, the distro's package manager or NodeSource on Linux), or install nvm first and use it.
- If Node.js 24 is already installed but is not the default, make it the default: update the version manager's default, or fix PATH order in the shell profile so it comes before the older node.
- Do not uninstall other Node.js versions.
3. Open a new shell (or source the shell profile) and confirm `node -v` prints v24 or later.
4. Run `npm install -g tracemetis`. If it fails with EACCES, do not use sudo; use the version manager's Node.js or set a user-owned npm prefix instead.
5. Confirm `tracemetis --version` works.
6. Start the workbench with `tracemetis web --open`. It keeps running and opens the browser at a 127.0.0.1 address; run it in the background or a separate terminal.
When done, tell me the Node.js version now in use, anything you changed in my environment, and the workbench URL.
tracemetis upgradereplaces a global installation with the latest npm release (stoptracemetis webfirst);tracemetis upgrade --checkonly reports whether there is one.npx tracemetis@latestalways runs the latest release.- Once a day, a command run in a terminal also asks npm for the latest version number in a background process, without waiting for the answer, and the next command prints one line when a newer release exists. The check sends nothing about your sessions; set
TRACEMETIS_NO_UPDATE_CHECK=1to turn it off.
Needs npm 11+; every workspace package builds locally with no private registry access.
git clone https://github.com/tencent/tracemetis.git
cd tracemetis
npm ci
npm run web -- --openIn a source checkout, npm start -- stands in for tracemetis in every command below (npm start -- analyze …), and npm run web builds the workspace before it starts the workbench.
Out of the box, TraceMetis uses your existing Claude Code, Codex, Cursor, Pi, CodeBuddy, or Antigravity login—no config file or separate API key is required to run your first analysis.
Claude Code and Codex: zero-config native authentication
TraceMetis reads sessions from ~/.claude/projects and ~/.codex/sessions (plus ~/.codex/archived_sessions), honoring CLAUDE_CONFIG_DIR and CODEX_HOME; each agent's tile on Home, or its pencil under Agents to scan in Settings, changes those folders. When running model stages, it reuses your native Claude (~/.claude/settings.json) or Codex login directly without copying credentials or redirecting native config directories.
For Codex model calls via AnyAgent, keep codex on your PATH.
Cursor: workspace recovery, subagents, and transcript rewrites
Cursor agent transcripts (~/.cursor/projects/<workspace>/agent-transcripts/) record user prompts, assistant turns, and tool calls without tool outputs or wall-clock event timestamps. TraceMetis recovers the workspace from the project folder, reads chat titles read-only from Cursor's local state.vscdb, times user turns from harness stamps, and strips duplicated parent history from subagents/ side chats so each subagent shows only its own work.
Cursor occasionally deduplicates lines or moves turn-end markers in place; TraceMetis's snapshot sync absorbs incidental rewrites without breaking incremental --resume.
WorkBuddy and CodeBuddy
WorkBuddy conversations in ~/.workbuddy/projects/<project>/<id>.jsonl (or WORKBUDDY_CONFIG_DIR) are scanned automatically. TraceMetis extracts the prompt inside <user_query>, keeps harness reminders and compaction summaries as context, and marks tool calls with nonzero exit codes or errors as failed. Subagent logs under <id>/subagents/ can be imported individually by path.
For model execution on CodeBuddy (--agent codebuddy), TraceMetis runs the bundled @tencent-ai/agent-sdk against your local CODEBUDDY_CONFIG_DIR login in an isolated text-only session.
Antigravity: app, CLI and IDE conversations, and the agy engine
TraceMetis reads the conversations of the Antigravity app, CLI and IDE from ~/.gemini/<app>/brain/<conversation>/.system_generated/logs/transcript_full.jsonl (<app> is antigravity, antigravity-cli or antigravity-ide), and their titles, workspaces and parent conversations read-only from each app's conversation_summaries.db. It takes the request from <USER_REQUEST>, keeps the app's metadata and reminders as context, pairs each tool call with the step that returns its output (including tools sent to the background), marks failed tools and nonzero exit codes, and keeps the steps a rewind left behind as a turn of their own. Subagents and forks are conversations of their own: a subagent's task is its first request, and its messages back appear in its parent as reports.
For model execution on Antigravity (--agent antigravity), keep the Antigravity CLI (agy) on your PATH (its installer puts it in ~/.local/bin) and sign in once by running agy. Each turn runs agy headless with a workspace agent that carries TraceMetis's instructions and no tools, and continues its conversation by ID. Antigravity model names carry their reasoning effort (gemini-3.8-flash-medium); set --effort only with a model named without one (gemini-3.8-flash). Antigravity serves its models through its own sign-in, so providers do not apply.
Pi: session logs
TraceMetis reads Pi sessions from ~/.pi/agent/sessions/<cwd>/<timestamp>_<id>.jsonl, following PI_CODING_AGENT_DIR and PI_CODING_AGENT_SESSION_DIR, and titles them by the name set with /name. It pairs each tool call with its result, turns ! shell commands into bash calls, keeps compaction and branch summaries as context, and strips image bytes. TraceMetis's own Pi sessions are kept in memory, so they never appear among the logs.
SSH remote hosts: inspect runs on another machine with zero remote install
Choose Scan an SSH host in the web app or pass --ssh <host> on the CLI to list any host from ~/.ssh/config (Include directives supported). The remote machine needs only a POSIX shell, standard file utilities, and key/agent authentication (ControlMaster connections are shared automatically).
TraceMetis copies remote logs into ~/.tracemetis/remote/<host>/ and converts them locally; later scans transfer only appended bytes after verifying the prefix is unchanged. Nothing on the remote host is modified.
Custom gateways and API keys (Anthropic, OpenAI, LiteLLM, OpenRouter)
Prefer a team gateway or a specific provider instead of a native agent login? Add providers visually in Settings (tracemetis web) or from the CLI:
tracemetis config provider.team.protocol litellm
tracemetis config provider.team.baseURL https://gateway.example.org
tracemetis config provider.team.apiKeyEnv TEAM_MODEL_KEY
tracemetis config agent.provider team
tracemetis config agent.model claude-opus-5.5To store a literal key with 0600 owner-only permissions instead of an environment variable, pipe it over stdin so it stays out of shell history:
printf '%s' "$TEAM_KEY" | tracemetis config set --stdin provider.team.apiKeySee config.example.json for every supported top-level field.
In a blind pairwise study, 14 people who use agents daily judged goal trees that six LLMs reconstructed from their own sessions (474 votes on 142 sessions of 100–968 actions). 78.7% of the trees made a run easier to understand than its transcript. The model matters: GPT-6.1 Sol, Gemini 4 Carbon, and Claude Opus 5.5 form a top cluster, preferred over the other three about 73% of the time.
Trees with more goals and a deeper hierarchy helped most; a tree in which one goal holds a long flat list of actions helped least.
Read the paper for the study design, the statistics, the reliability checks, and more on what makes a goal tree helpful.
| Call & span timelines Langfuse · LangSmith · claude-devtools |
One-shot prose summaries/recap · session summarizers |
Self-reported agent trees Atlas · MUSE · Graph of Trace |
TraceMetis | |
|---|---|---|---|---|
| Unmodified logs | Yes (local) or requires SDK spans | Yes | No — modifies agent prompt or MCP tools | Yes — reads existing local or SSH .jsonl files |
| Primary unit | Individual LLM calls, spans, and tokens | One fluent prose block | One turn or agent-declared stage | Goals, attempts, rounds, and constraints |
| Interleaved subtasks | Split apart by timestamp ordering | Flattened or omitted | Depends on agent self-discipline | Merged by means–end purpose across time gaps |
| Failed pivots & caveats | Buried in flat error logs | Often dropped for fluent prose | Unverified self-reporting | First-class attempt nodes, incidents & caveats |
| Evidence & verification | Raw payloads (~87% of trace tokens) | Severs links to raw actions | Trusts the observed agent | 15-op edit algebra + code gate + 1-click #action links |
| Deliverable | Hosted dashboard or live dev server | Markdown blurb | Custom research UI | Local workbench + 1 offline .html (default-src 'none') |
The downsides are real. Reconstructing intent uses an LLM at roughly 1.5 minutes per batch with a frontier model—a 750-action, 3-day trajectory (27 batches, 9 subtree consolidations) takes ~39 minutes of wall-clock time and ~US$11 in API spend when running a frontier model across every stage. That makes TraceMetis built for asynchronous milestone check-ins and post-run auditing, not sub-second streaming during interactive pair programming. Summary fidelity is also bounded by what the harness logs (omitted GUI screenshots or redacted tool outputs cannot be recovered), and high-stakes decisions should always verify claims via the linked raw #action indices.
Agent comprehensibility does not improve automatically as base models grow stronger. More capable agents run longer, interleave more subtasks, and optimize for completion under friction via silent process compromises: narrowing a literature check to whichever secondary index was not blocked by a sandbox, configuring an "external" reviewer that calls the same model family as the author, passing a single test case while bypassing broader suite failures, or quietly relaxing a user constraint after an intermediate error.
Inspecting the raw execution trace rarely catches these compromises, because raw traces were built as an append-only context buffer for the model (~87% raw tool payloads), not an audit artifact for humans. Reading breaks down along two dimensions:
- The expression barrier. Trace entries rely on context-bound shorthand (
Check config,Write main text), while model progress notes pack concrete actions into dense nominalized prose—writing "Parameter validation across the training pipeline identified a script-level learning-rate override requiring configuration alignment" when what actually happened is "train.py overrides the learning rate in config.yaml with a hardcoded default." - The structural barrier. Linear logs record only two extremes—hundreds of low-level operations at uniform visual weight, and one final output—with no middle goal layer. Worse, real runs interleave work across time: an agent hits an API block at
#14, spends 25 steps on unrelated setup during cooldown, and finishes the search at#40. Timestamp timelines slice one effort into scattered fragments.
A 12-action toy run read three ways. TraceMetis recovers the third reading from unmodified agent logs.
TraceMetis reconstructs that missing middle layer from activity theory and hierarchical task analysis, and pairs every node with self-contained (Name, Result) labels:
| Context-bound trace shorthand | TraceMetis self-contained Name · factual Result |
|---|---|
Write the text |
Write the initial research proposal · round-0 draft written |
Run the review |
Round 2 external review · 7.25, needs revision |
Search |
Search from a terminal outside the sandbox · results logged |
Test |
Get lexer snapshot tests running · one case passes, suite fails |
Structure follows intent, not screen balance. Goal B nests inside goal A if and only if the agent carried out B in order to achieve A. Routine operations stay inside their goal; normal completions stay unbadged so failed attempts, partial outcomes, and methodological caveats jump out in under 30 seconds.
One browser bundle powers the local web app (tracemetis web), the live viewer attached during tracemetis analyze, and the standalone file written by tracemetis export.
| Surface | What it shows | How you use it |
|---|---|---|
| Means–end goal canvas | Nested goal containers (border weight steps down with depth); gray arrows strictly for sibling precedence; uniform encoding of parts, attempts, and iterative rounds; top bar for session constraints; dashed band for off-main-line side work | Degree-of-Interest (DOI) auto-folding (24–150 block budget) opens branches by action volume, branching, and exception density. Press 0–3, e, a to change depth, f to focus a subtree, / to search, or drag to pan |
| 30-second evidence cards | Question-driven side cards (what problem it addressed → what the agent did → outcome & caveats → recorded incidents → traceable #action links), with inline plain-language glosses for repo-local terms |
Synthesized in three isolated turns (questions → evidence card → salience layout) with tools disabled so formatting never invents facts. Generate for all blocks, selected IDs (--details g3), or on demand |
| Live diffs & batch timeline | Every committed batch (22–34 actions) is a frame: new boxes rise in green, updated conclusions flash blue, relocated subtrees slide, and retired nodes fade out in red |
Follow an active session across milestones, or scrub and replay completed runs at 0.5×–8× (←, →, Space). Selecting any goal highlights its exact action positions along the timeline |
| Zero-network HTML export | Complete goal hierarchy, 30-second cards, action inspector, rebuilt file excerpts, and delta-encoded timeline frames in one .html file |
Opens straight from file:// under default-src 'none' and remembers the reader's light/dark toggle |
TraceMetis has been stress-tested across coding and research trajectories spanning 127 to 750 actions and multi-day resumptions:
| Trajectory | Scale | What TraceMetis recovers |
|---|---|---|
| Proposal Refinement | 128 actions · 27 goals · 1 constraint · 100% anchored |
Merges a sandbox-blocked search (#13–16) and an external-terminal retry (#40–47) across a 25-step cooldown gap; captures a 5-round review loop (6.40 → 8.00 < 9.0 target); collects 12 budget checks into one $50/day top constraint; flags a same-model reviewer caveat. |
| Ghostty titlebar bugfix Public Amp trace (Hashimoto, 2025) |
127 actions · 2 user roots |
Separates tactical method switches (4 sequential layout attempts under root 1—revising batch 2's compiled fix to failed when batch 3's user prompt redirects to a top accessory view) from task redefinition (root 2's bottom window overlay). |
| Multi-module engineering | 476 actions · 12+ batches |
Defeats incremental inertia: once 13 flat child goals accumulate across 11 batches like a raw changelog, debt-triggered consolidation regroups 12 of them into 4 phase-level goals in a single tool-free call. |
| 3-day LLM-compiler study | 750 actions · 123 goals (depth 7) · 27 batches · 9 consolidations (0 rollbacks) |
Distinguishes 2 true task roots from 16 mid-run human nudges and quota resumptions; keeps per-batch prompts at 15k–30k chars instead of ~129k; relocates day-1 benchmark prep out of day-3 evaluation; surfaces the negative finding (no model route beat Clang on total cost) on the root card. |
tracemetis web --open- Click Scan this computer on Home. TraceMetis shows the exact directories it will read before scanning; conversion into normalized events and coalesced actions uses zero model calls and zero uploads. (Prefer one file? Use Add session manually with path completion.)
- Click any session row to inspect its numbered actions, coalesced tool calls (e.g.,
Read ×3), and failed commands before spending a single token. - Select one or more sessions and choose Analyze (post-run) or Watch live (ongoing). Pick English or Chinese, confirm per-stage models, and inspect each batch as it commits.
# Minimal — uses your existing Claude/Codex login and defaults
tracemetis analyze codex /path/to/rollout.jsonl --out /tmp/my-run
# With governing task specs (SKILL.md, briefs) to ground domain terms & flag skipped stages
tracemetis analyze claude-code ~/.claude/projects/<project>/<session>.jsonl \
--material BRIEF.md \
--material SKILL.md \
--out /tmp/proposal-runWhile analyze runs, it prints a local URL so you can watch the tree grow in your browser (--no-web disables this). When finished, open /tmp/proposal-run/session.html. Interrupted runs resume cleanly from the last committed batch or card:
tracemetis analyze codex /path/to/rollout.jsonl --out /tmp/my-run --resume# Poll an active log; press Ctrl+C anytime to pause without losing progress
tracemetis analyze codex /path/to/rollout.jsonl --out /tmp/live-run --watch
# Once the agent finishes, settle pending placements and write detail cards
tracemetis analyze codex /path/to/rollout.jsonl --out /tmp/live-run --resume --finish
# Or let `tracemetis web` auto-continue a session whenever ≥22 new actions arrive
tracemetis sessions follow <session-id>
# Scan or import logs over SSH (incremental byte-append sync, zero remote install)
tracemetis sessions scan --ssh devbox
tracemetis sessions import --ssh devbox '~/projects/run/session.jsonl'tracemetis export /tmp/proposal-run --out /tmp/proposal-share.html --title "Proposal Pipeline Audit"
tracemetis sessions list --json
tracemetis trajectory claude-code session.jsonl # deterministic action extraction (0 tokens)Log normalization and action coalescing are purely deterministic. Model inference is split into four explicit stages, so you can pair a frontier reasoning model for structural edits with a fast model for naming and cards:
| Stage | Responsibility | Default effort |
|---|---|---|
label |
Emit a single tool-free call of constrained local ops per batch (22–34 actions), plus user-turn root routing and up to 2 in-session invariant repair turns |
high (low on user-turn routing) |
organize |
Restructure quiet subtrees that cross structural debt thresholds in one scoped, rollback-safe call | high |
name |
Write self-contained verb–object names and one-line results for new/relocated nodes, verifying verbatim numerical grounding against NAMES.md |
low (medium on fixes) |
present |
Synthesize three-turn question-driven evidence cards (questions → card → layout) |
Configured / native default |
Each stage resolves its agent (claude · codex · pi · cursor · codebuddy · antigravity), provider, model, and effort (low · medium · high) from: stage flags (--label-model, --present-agent, …) → shared flags (--agent, --provider, --model, --effort) → saved stages.<stage>.* → saved agent.* in ~/.tracemetis/config.json.
| Dial | Options | What it controls |
|---|---|---|
| Language | --language en | zh (tracemetis config language zh) |
Language of self-contained goal titles, one-line results, and 30-second cards (en by default). |
| Detail cards | only when asked (default) · --details all · --details g3 --details c1 · --resume --details-only --details g3 |
Start with names and conclusions only for fast structural oversight, synthesize cards everywhere (tracemetis config details all), or generate cards for specific blocks; a card request writes only those cards. Cards are written concurrency.details at a time (2 by default). |
| Reference materials | --material BRIEF.md --material SKILL.md (repeatable) |
Frozen into inputs/materials/ as weak priors—enabling skipped-stage detection (skipped) and domain-term glossing while observed actions still govern. |
| Frontier & batching | --batch-min 22 --batch-max 34 · --compact-window 36 · --no-reorg |
Natural discourse batch sizing, active-frontier folding window (0 keeps the whole tree unfolded), and debt-triggered consolidation. |
| Budgets | budgets.goals.* · budgets.presentation.* |
Hard caps per invocation on calls (40 / 400), input tokens (4M / 6M), output tokens (400k / 500k), and repair rounds (--rounds / 1). A run that spends one stops and says which limit it hit; resuming starts a fresh budget while reusing accepted work. |
Forward planners decompose goals prospectively before acting; TraceMetis reconstructs intent retrospectively from observed actions, treating agent checklists and skill specs strictly as weak priors (observed actions win whenever behavior diverges). Letting an LLM rewrite tree JSON directly across dozens of batches corrupts IDs, drops action indices, and stalls in flat lists. TraceMetis decouples semantic inference from state management:
- Active-frontier folding (
15k–30kchars across 750 actions). Goals touched within the last36actions expand in full alongside their ancestors; quiet subtrees collapse to a single summary line, and dormant roots archive after60actions once a newer root exists. If the agent revisits old work,reopenrestores full detail on the next batch, while a compactbriefmemo preserves session-wide context. - 15-operation local edit algebra. Each batch emits one tool-free JSON edit list across four categories—node/membership (
add,set,label,merge,delete), structured attributes (push,drop,moveonrequires,incidents,skipped,evidence), precedence/epistemic state (order,unorder,uncertain,resolve,change), and context (reopen,brief). Untouched branches remain strictly invariant by construction. - Hard deterministic invariants. Before any batch commits, code verifies that every referenced ID exists, 100% of batch actions are anchored, parent pointers form an acyclic user-rooted forest, and no empty shell goals exist—returning diagnostics in the same conversation for up to
2repair rounds. - Deferred placement (
pending) & debt-triggered consolidation. Ambiguous early actions attach tentatively with apendingmarker stating what later evidence will settle them (auto-settling at40actions). When an inactive subtree (≥ 22actions,≥ 4descendants) crosses structural debt thresholds such as≥ 6flat children, deterministic code—not the LLM—triggers a scoped consolidation pass and rolls back atomically if any out-of-scope node is touched.
| Failure mode | What goes wrong without guardrails | Countermeasure in TraceMetis |
|---|---|---|
| Temporal chunking | Fixed action windows become nodes; resumed work appears twice | Means–end merging across time gaps + reopen on folded goals |
| Chain degeneration | Deep single-child wrappers add nesting without adding meaning | Non-triviality criterion + automatic single-child wrapper flattening |
| Level mismatch | Routine probes (format:check, quota checks) sit beside major phases |
Five operational goal criteria + non-goal fields (requires, incidents, externalized constraints) |
| Opaque naming | Bare verbs (Check) or path-laden shorthand (Write main text) |
Decoupled (Name, Result) fields, path ban, and verbatim number verification |
| Incremental inertia | Model notes flat siblings need grouping in reasoning, but leaves them flat | Program-triggered quiet-subtree consolidation with scoped atomic rollback |
See docs/incremental-analysis.md for checkpoint layout, byte-prefix verification, and recovery semantics.
Modular TypeScript monorepo with explicit composition and zero runtime service-locator magic. Package boundaries in tooling/boundaries.js are enforced by both ESLint and npm test.
tracemetis/
├── packages/
│ ├── contracts/ # Zero-dependency data & wire-format types (TraceEvent, Action, GoalSnapshot)
│ ├── core/ # Stage graph, 15-op incremental edit algebra, invariant checks & ports
│ ├── plugin-sdk/ # Six extension contracts (source, model, stage, check, exporter, store)
│ ├── runtime/ # Copy-on-write registries and explicit composition boundaries
│ └── cli/ # The `tracemetis` executable, workbench host, and bundled goal standards
├── plugins/
│ ├── trajectory/ # Claude Code, Codex, Cursor, WorkBuddy, Antigravity & Pi normalization, file facts
│ ├── anyagent/ # Unified session runtime across Claude, Codex, Pi, Cursor, CodeBuddy & Antigravity
│ ├── model-anyagent/ # Multi-stage AnyAgent model provider with repair-turn continuation
│ ├── model-cli/ # Standalone process-per-call CLI engine for Claude & Codex
│ ├── local-store/ # Content-addressed artifacts and atomic revision-checked checkpoints
│ ├── presentation/ # Verbatim-checked display bridge and 3-turn 30-second card synthesis
│ ├── web/ # Loopback web workbench, DOI goal-tree canvas, and offline HTML exporter
│ └── template/ # Compile-checked starter template for authoring new plugins
├── docs/
│ ├── architecture.md # Data boundaries, stage graph, and node identity invariants
│ ├── incremental-analysis.md
│ └── plugins.md # Authoring guide for custom sources, checks, and exporters
├── tests/ # Deterministic boundary, codec, workbench, SSH, and SDK fixture tests
└── tooling/ # Workspace dependency rules and locale catalog compiler
Dependency direction is strictly one-way:
contracts ← core ← plugin-sdk ← runtime ← cli
↖───────────────┘
plugins → core + plugin-sdk
viewer → contracts (bundled without Node APIs)
Every tracemetis analyze run writes an auditable, resumable directory:
| Artifact | Contents |
|---|---|
session.html |
Self-contained offline viewer: nested goal canvas, 30-second cards, action inspector, and batch timeline |
session.events.jsonl, session.actions.jsonl |
Normalized source events and coalesced sequential actions (with log-rebuilt file facts) |
session.goals.json, session.goals.check.json, session.goals.md |
Verified goal tree, hard/soft invariant check report, and 100% action attribution report |
session.goals.display.json, session.presentation.json |
Self-contained (Name, Result) pairs and three-turn evidence cards |
inputs/ |
Frozen byte copies of the raw transcript, --material specs, and goal standards |
goals/, presentation/ |
Per-batch edit ops, repair turns, consolidation passes, and per-node card transcripts |
analysis.manifest.json, analysis.state.json, analysis.report.json |
Input/model hashes, live progress cursor, and final SHA-256 artifact digests |
tracemetis webbinds strictly to127.0.0.1, rejects foreignHost/Originheaders, reads no agent folders before explicit scan consent, and never exposes stored API keys to the browser.- Every committed batch anchors 100% of its actions to an acyclic user-rooted forest with zero dangling IDs or empty shell goals, keeping untouched branches strictly invariant.
- Unmodified goal nodes preserve both their IDs and their
(Name, Result)labels across incremental batches,--watchcheck-ins, and--resume. - Every numerical figure in a generated box title or one-line result appears verbatim in that goal's supporting evidence, and every exported
session.htmlopens offline underdefault-src 'none'. npm run checkpasses formatting, ESLint, workspace boundary checks, TypeScript project references, and the full test suite offline without paid model credentials.
If any of these fail, that's a bug worth filing.
Drawing on Leont'ev's three-tier activity model (activity → goal → operation), Hierarchical Task Analysis, and human event-segmentation research, a trace candidate earns a tree node only when it satisfies five operational criteria: a completable result state, single completion, behavioral evidence, an independent outcome, and non-triviality relative to its parent. Operations, requirements (requires), standing rules (constraints), unexecuted skill stages (skipped), and one-off errors (incidents) stay in structured fields rather than cluttering the hierarchy; sibling parts, failed attempts, and iterative rounds share one uniform schema of node status plus reasoned precedence edges. On screen, orthogonal channels prevent visual interference: spatial containment carries means–end hierarchy, subtle gray arrows carry explicit precedence, and high-saturation color belongs strictly to exceptions and shortfalls—designed so an overseer who never watched the run can grasp any block's objective, outcome, and caveats in ~30 seconds.
- Sub-second live streaming while pair-programming → at ~1.5 min per batch with a frontier model, watch the terminal or IDE harness directly; use TraceMetis for milestone check-ins, handoffs, and post-run audits.
- Short 10-step bug fixes → read the raw transcript; there is no intermediate hierarchy worth reconstructing.
- Fleet-wide telemetry across thousands of production traces (p99 latency, token billing, alerting) → Langfuse, LangSmith, or OpenTelemetry.
- GUI-heavy runs whose logs omit screenshots, DOM state, or redacted tool outputs → reconstruction cannot recover evidence the harness never wrote to disk.
npm ci
npm run build
npm run check # format:check + lint + typecheck + test
npm pack --workspace tracemetis --dry-run --ignore-scriptsStart with CONTRIBUTING.md, docs/architecture.md, and docs/plugins.md. Keep domain logic free of Node and UI dependencies, preserve raw event provenance through every stage, and keep deterministic software tests separate from live model evaluations.
MIT. The icons and brand marks in the web app and exported pages keep their own licenses; see THIRD_PARTY_NOTICES.
If you use TraceMetis in your research, please cite the paper:
@misc{zhang2026tracemetisagentcomprehensibility,
title={TraceMetis: Towards Agent Comprehensibility},
author={Zhao Zhang and Chao Peng and Peijie Dong and Laiheng Song and Guoqing Wang and Hande Dong and Qiang Lin and Yingfei Xiong},
year={2026},
eprint={2612.05953},
archivePrefix={arXiv},
primaryClass={cs.AI},
url={https://arxiv.org/abs/2612.05953},
}