Skip to main content
Glama

get_failure

Read-only

Retrieve the traceback and code for a failed forecast run or failed comparison candidate so you can diagnose errors and inspect what broke.

Instructions

Return the traceback and the code of a failed run (the details.failure_id of an error) or of a failed candidate of a comparison. The id of an object that did not fail is invalid_argument; for the script of a run that worked, use get_code.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "object_id": "<object_id>"
    },
    "name": "get_failure"
  }
}

Input Schema

NameRequiredDescriptionDefault
candidateNoName of the failed candidate, required with the id of a comparison; null with a `failure_id`.
object_idYes`details.failure_id` of an error, or the id of a comparison whose candidate failed.

Output Schema

NameRequiredDescriptionDefault
idYes
textYes
filesNo
candidateNo
text_truncatedNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv0.1.1
    • changedInput schema / properties / candidate / description
      Previous value: -"Name of the failed candidate of a comparison."New value: +"Name of the failed candidate, required with the id of a comparison; null with a `failure_id`."
  2. First observedv0.1.0

TDQS

A4.5/5.0
Behavior4/5

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

Annotations already declare readOnlyHint=true, destructiveHint=false, and openWorldHint=false, so safety is covered. The description adds genuinely new behavior: an object id that did not fail yields an invalid_argument error, which tells the agent how failures will surface. It stops short of describing permission or size limits on the returned traceback, so it is not a full 5.

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

Conciseness5/5

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

Two sentences, front-loaded with the return value, then the exclusion and the sibling pointer. No filler words and nothing that could be dropped without losing routing information.

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 two-parameter read-only tool with full schema coverage, an output schema, and annotations, the description supplies the remaining pieces an agent needs: what is returned, when it applies, the error condition for non-failed ids, and the successful-run alternative. Nothing material is missing.

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

Parameters3/5

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

Schema coverage is 100%, so both object_id and candidate are already documented in the schema, including 'required with the id of a comparison; null with a failure_id.' The description restates that object_id is a details.failure_id or a comparison id rather than adding format or edge-case guidance beyond the structured fields. This is the expected baseline 3 when the schema does the heavy lifting.

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?

States a specific verb and resource: 'Return the traceback and the code of a failed run ... or of a failed candidate of a comparison.' It also explicitly distinguishes itself from the sibling get_code, which handles scripts of successful runs, so an agent can separate the two without opening either schema.

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

Usage Guidelines5/5

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

Covers when to use (failed run, failed candidate of a comparison), when not to use ('the id of an object that did not fail is invalid_argument'), and the correct alternative ('for the script of a run that worked, use get_code'). All three routing decisions are spelled out.

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