Skip to main content
Glama

container_autopsy

Diagnose why a Docker container died by collecting exit code, OOM state, restart count, uptime, and logs. Get a markdown report with the cause and exact fix.

Instructions

Diagnose WHY a Docker container died, not just THAT it died. Collects exit code, OOM state, restart count, uptime and last log lines, then returns a markdown autopsy report with the cause of death and the exact fix. Works on running containers too.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
tailNoNumber of log lines to collect (default 40).
containerYesContainer name or id to autopsy.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.0.0

TDQS

A4.2/5.0
Behavior4/5

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

With no annotations provided, the description carries the full burden of behavioral disclosure. It states what data is collected (exit code, OOM state, restart count, uptime, last log lines) and what is returned (a markdown autopsy report with cause and fix), making the tool's read-only, diagnostic nature strongly implied. It does not explicitly rule out side effects or mention permissions, but the described behavior is transparent enough for safe invocation.

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?

The description is two sentences with no wasted words. The core purpose is front-loaded ('Diagnose WHY... not just THAT...'), followed by a compact list of collected data and the output format. Every sentence earns its place.

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?

There is no output schema, so the description compensates by explaining the return value: a markdown autopsy report with cause of death and exact fix. It also covers inputs implicitly through the listed collected data and mentions the running-container case. Minor gaps like failure modes or Docker daemon prerequisites prevent a perfect score, but the tool is well-specified for typical use.

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 description coverage is 100%, so the schema already documents both parameters. The description mentions 'last log lines' which maps to the tail parameter, but it adds no new detail about parameters beyond what the schema provides. Thus the baseline of 3 is appropriate.

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 ('Diagnose') with a concrete resource ('a Docker container') and clearly scopes the purpose: determining WHY it died rather than merely that it died. It also differentiates from the sibling container_obituary by emphasizing cause analysis and the exact fix, not just recording the death.

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

Usage Guidelines4/5

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

The description gives clear context for when to use the tool: when a container died and you need the cause and fix, not just a death notification. It also notes it works on running containers, broadening applicability, but it does not explicitly name alternatives or state when not to use this tool.

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

Deploy Server

Other Tools