Skip to main content
Glama

log_analyzer

Read-onlyIdempotent

Analyze a log file. POST raw log text (or an upload_id from the create_upload tool, up to 5MB) and get: level breakdown + time range, error clusters (messages normalized so variable ids/numbers collapse into one signature, with counts + first/last seen + a sample), a timeline, detected anomalies (error spikes, retry storms, new error signatures, log gaps/outages, level-ratio shifts) with evidence, and templated recommendations. Handles JSON-lines and plain formats (ISO8601/syslog/CLF/epoch timestamps). Deterministic, single-pass, no LLM.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "log_analyzer"
  }
}

Input Schema

NameRequiredDescriptionDefault
textNoRaw log content (up to 1M chars).
top_nNoTop clusters to return (1-50, default 10).
formatNoDefault "auto" (detected). json = one JSON object per line.
upload_idNoAlternative: a log file uploaded via the create_upload tool.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed5 schema fields changed
    • addedInput schema / properties / format / description
      Added value: +"Default \"auto\" (detected). json = one JSON object per line."
    • addedInput schema / properties / top_n / maximum
      Added value: +50
    • addedInput schema / properties / top_n / minimum
      Added value: +1
    • changedInput schema / properties / top_n / type
      Previous value: -"number"New value: +"integer"
    • changedInput schema / properties / upload_id / description
      Previous value: -"Alternative: a log file uploaded via the uploads tool."New value: +"Alternative: a log file uploaded via the create_upload tool."
  2. First observed

TDQS

A4.4/5.0
Behavior4/5

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

Annotations already declare readOnly, idempotent, non-destructive, closed-world, so the safety profile is covered; the description adds real value with 'Deterministic, single-pass, no LLM', supported input formats, and size limits. It does not discuss cost, latency, or behavior on malformed input, which keeps it from a 5.

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 a one-line purpose followed by a compact, colon-delimited enumeration of outputs; nearly every clause carries information the agent needs. It is dense but not padded, though the parenthetical about message normalization is long enough to slow scanning.

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?

There is no output schema, so the description carries the full burden of describing returns, and it does so thoroughly across every result section including cluster fields and anomaly evidence. For a stateless analysis tool with four fully documented parameters, nothing an agent needs to call it correctly is missing.

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

Parameters4/5

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

Schema coverage is 100%, so a 3 is the baseline, but the description adds meaning beyond the schema: the accepted timestamp formats (ISO8601/syslog/CLF/epoch) clarify what 'auto' detection handles, and the 5MB note contextualizes upload_id. It never mentions top_n or the text-vs-upload_id precedence beyond 'Alternative', and the 5MB figure sits slightly oddly against the schema's 1M-char limit.

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+resource ('Analyze a log file') and then enumerates the exact outputs: level breakdown, error clusters with normalization, timeline, anomaly classes, and recommendations. This is clearly distinguishable from siblings like log_audit_creator or regex_lint, and an agent can tell what it produces without opening the schema.

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?

Gives a concrete entry path ('POST raw log text (or an upload_id from the create_upload tool)'), which routes the agent to the correct sibling for large inputs. It does not state exclusions or when a different analysis tool (e.g. log_audit_creator) would be preferable, so it stops short of full when/when-not guidance.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.