Skip to main content
Glama

truncate

Cuts text to a specified maximum length and appends a one-character ellipsis when shortened.

Instructions

Truncate text to at most max characters, appending a single-character ellipsis when it must be cut. [conductor: verified pure command]

Input Schema

NameRequiredDescriptionDefault
maxYes
textYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.4.1

TDQS

A3.7/5.0
Behavior3/5

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

With no annotations, the description must carry the behavioral load. It does disclose the ellipsis-appending behavior and states the command is pure (no side effects), but it leaves the key edge case ambiguous: whether the ellipsis counts toward `max` (result could be max+1 chars) and what happens at max=0.

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?

A single front-loaded sentence stating the core contract, with no wasted filler. The trailing '[conductor: verified pure command]' tag adds useful safety context (it supports purity), though it is meta-noise rather than natural description.

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?

For a two-parameter pure text transform with no output schema, this is nearly sufficient: the operation, the cut condition, and the appended character are all stated. Only the interaction between `max` and the ellipsis remains underspecified.

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 0%, so the description must compensate. It clarifies that `max` is a character budget and that `text` is what gets cut, but it does not resolve whether the appended ellipsis is inclusive of that budget — the one semantic detail that matters.

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 ('Truncate text') plus the exact output contract ('at most `max` characters, appending a single-character ellipsis'). No sibling tool in the list performs truncation, so the agent can distinguish it immediately.

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 by the verb; there is no explicit when-to-use or when-not guidance. In practice no sibling offers an alternative truncation behavior, so the missing guidance is low-risk but still absent.

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