Skip to main content
Glama

Alphabetical order sorter

hopi_alphabetical_order
Read-onlyIdempotent

Sort the lines of a block of text into alphabetical order. Blank lines are dropped. Uses natural en-GB ordering so numbers within lines sort sensibly. Can sort ascending (A to Z) or descending (Z to A), and can ignore case. Source: https://hopi.co.uk/alphabetical-order/

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
textYesThe text to sort, one item per line
directionNo'asc' for A to Z (default), 'desc' for Z to Aasc
caseInsensitiveNoIgnore letter case when sorting (default false)

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
linesYes
resultYes
summaryYes
directionYes
source_urlYesThe tool's page on hopi.co.uk (cite or open to check the figure)
caseInsensitiveYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • addedOutput schema / required
      Added value: +[
      +  "caseInsensitive",
      +  "direction",
      +  "lines",
      +  "result",
      +  "source_url",
      +  "summary"
      +]
  2. First observed

TDQS

A4.5/5.0
Behavior5/5

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

Beyond the readOnlyHint and idempotentHint annotations, the description reveals important behavioral traits: blank lines are dropped, natural en-GB ordering makes numbers sort sensibly, and both ascending/descending and case-insensitive modes are available. This gives the agent useful expectations that annotations alone do not provide.

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 tight and front-loaded: the core action appears first, followed by high-value behavioral details and options. The source URL is a minor but acceptable addition, and every sentence contributes useful information without redundancy.

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 simple sorting utility with a low parameter count and an output schema present, the description covers the inputs, key edge-case behavior, and available options. There is nothing essential missing for an agent to invoke the tool correctly.

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?

The input schema already provides 100% coverage with clear descriptions for text, direction, and caseInsensitive. The description mostly restates these options ('ascending', 'descending', 'ignore case') and adds the natural-ordering nuance, but it does not provide substantial new per-parameter meaning beyond the schema.

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 opens with a specific verb and resource: 'Sort the lines of a block of text into alphabetical order.' It clearly distinguishes this from the many sibling text utilities by specifying line-level alphabetical sorting, and it names the exact operation without ambiguity.

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 makes the use case clear: sorting lines of text alphabetically, with optional direction and case sensitivity. It does not explicitly name alternatives or when-not-to-use conditions, but among the sibling tools no direct sorting alternative exists, so the context is sufficient for an agent to select it correctly.

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.

Resources