Skip to main content
Glama

detect_failures

Detect LLM quality failures by matching failure patterns and zero feedback scores in traces, separating them from code exceptions.

Instructions

Detect LLM output failures using pattern matching and feedback scores.

Finds traces where output contains failure signals ('unable to', 'I can't', 'error occurred', etc.) OR where feedback score = 0.

This catches LLM quality failures, NOT Python exceptions. Use find_exceptions for code errors.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
tagsNo
projectNo
end_dateNo
group_byNo
start_dateNo
time_rangeNo
max_examplesNo
include_examplesNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Behavior4/5

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

With no annotations provided, the description carries the burden of behavioral disclosure. It transparently states the detection mechanism (pattern matching on specific failure signals), the inclusion of feedback score = 0 occurrences, and the exclusion of Python exceptions. This gives meaningful behavioral context beyond a simple one-liner.

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?

Three focused sentences, front-loaded with the main purpose. The follow-up sentence clarifies the detection criteria, and the final sentence provides the key alternative. Concise and free of filler.

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

Completeness4/5

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

Despite the 0% schema parameter coverage and lack of annotations, the description effectively frames the tool's purpose, detection logic, and boundary with find_exceptions. An output schema exists, so return values need not be described. It misses some contextual details like how to constrain by time or project, but overall is sufficiently complete for a detection tool.

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

Parameters1/5

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

Schema description coverage is 0% for all 8 parameters, yet the description adds no parameter-specific semantics. It mentions 'feedback score' conceptually but doesn't explain how parameters like tags, project, date ranges, group_by, or max_examples affect behavior. The description fails to compensate for the lack of schema descriptions.

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 uses a specific verb ('detect') with a clear resource ('LLM output failures') and explains the method (pattern matching and feedback scores). It explicitly distinguishes itself from find_exceptions by clarifying it catches quality failures, not Python exceptions.

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?

Provides explicit when-not guidance: 'This catches LLM quality failures, NOT Python exceptions.' Directly names the alternative tool: 'Use find_exceptions for code errors.' This clearly tells the agent when to choose this tool over a sibling.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/DrishtantKaushal/LangfuseMCP'

If you have feedback or need assistance with the MCP directory API, please join our Discord server