Skip to main content
Glama

parse_trace

Parse pasted stack traces from Python, Node, Java, Go, Rust, and .NET to mark the root cause, classify application vs library frames, and flag truncated input as partial.

Instructions

Parse a pasted stack trace / crash output and explain it.

Auto-detects Python (chained exceptions, ExceptionGroup, SyntaxError), Node/V8 (cause, AggregateError, async frames), Java/Kotlin (Caused by, suppressed, "... N more"), Go (panic, fatal error, goroutine dumps, race reports), Rust (panic + RUST_BACKTRACE) and .NET (inner exceptions). Returns the exception chain with the ROOT CAUSE marked, every frame classified as application vs library/stdlib/framework/runtime, the innermost application frame, and a fingerprint. Truncated or garbled input is parsed as far as possible and flagged PARTIAL with a reason.

Args: text: The raw trace, optionally surrounded by other log lines (max 5,000,000 characters). index: If the text contains several traces, which one (0-based). The report says how many. format: "report" (compact text, default) or "json" (full structure). full: Show every frame instead of collapsing runs of library frames. max_frames: Maximum frames listed for the root cause (default 25). redact: Remove secrets, emails, IPs and home-directory names from the output (default true).

Input Schema

NameRequiredDescriptionDefault
fullNo
textYes
indexNo
formatNoreport
redactNo
max_framesNo

Output Schema

NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.3/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations supplied, the description carries the full burden and does disclose substantial behavior: auto-detection rules, that the ROOT CAUSE is marked, that frames are classified as application vs library/stdlib/framework/runtime, that a fingerprint is computed, and that truncated or garbled input is parsed as far as possible and flagged PARTIAL with a reason. It stops short of stating that the tool is a pure, side-effect-free analysis of the supplied text (no execution, no external lookups), which would fully close the gap.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Front-loaded with purpose and output contract before the parameter list, which is the right order. Sentences are dense but purposeful; the parenthetical runtime examples and the Args block repeat some defaults already present in the schema, which is slightly redundant but aids scanning. Minor trimming is possible, but nothing is genuinely wasted.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a six-parameter parsing tool with an output schema, the description covers everything an agent needs: what it detects, what it returns (root cause, frame classification, innermost application frame, fingerprint), how it degrades on bad input, and the meaning of every argument. Return-value explanation is technically unnecessary given the output schema but adds useful orientation rather than harm.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, so the description must compensate and it does: an Args block defines every one of the six parameters. It gives the max input size for text (5,000,000 characters), explains index as 0-based with the report indicating how many traces exist, supplies the otherwise-missing value set for format ('report' vs 'json' — schema has no enum), clarifies full, and states max_frames default 25 and redact default true with what gets stripped.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description opens with a specific verb+resource: 'Parse a pasted stack trace / crash output and explain it.' It then enumerates exactly which languages/runtime formats are auto-detected (Python chained exceptions, Node/V8, Java/Kotlin, Go, Rust, .NET), which makes the scope concrete and distinguishes it from siblings like find_traces_in_file (file-based) or explain_exception (single exception).

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Usage is only implied: 'pasted' and 'optionally surrounded by other log lines' hint that this is for raw text blobs rather than files, which is what find_traces_in_file presumably handles, but no sibling is named. There is also no explicit guidance about when to prefer this over explain_exception or compare_traces, and the overlap with redact_trace (via the redact flag) is left unresolved.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.