Skip to main content
Glama

Decode TOON back to JSON

demo_decode_toon
Read-onlyIdempotent

Parse TOON text into JSON and return a canonical serialization to verify lossless round-trip encoding against the original.

Instructions

Parses TOON text into a JSON value and returns it, together with a canonical serialisation for comparing against the original — the way to prove an encode_toon round trip is lossless. Use it on text this server produced or on a stored TOON document; to produce such text use encode_toon, and to compare formats rather than parse use compare_formats. ...

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
toonYesTOON-encoded text, one document per call, with its original indentation; tabs are treated as indent levels.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
decodedYesThe parsed value: a JSON document of any type.
round_tripYesThat value re-serialised as JSON, keys sorted.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv0.7.14

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 and non-destructive, so the safety profile is covered. The description adds real value beyond that by disclosing what is returned (JSON value plus a canonical serialisation) and the intended lossless round-trip purpose, though it omits error behaviour for malformed TOON.

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-loads the core action and the returned artifacts, then the routing guidance in a single dense second sentence. Every clause is functional, though the trailing ellipsis and slightly stacked clauses keep it from being maximally tight.

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 single-parameter, idempotent read tool with an output schema present, everything needed to select and call it correctly is covered: purpose, alternatives, and usage conditions. Return values are additionally explained even though the output schema would suffice.

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?

There is a single parameter with 100% schema description coverage, so the schema already documents the 'toon' input including indentation/tab handling. The description adds no parameter-level detail beyond the schema, which is the expected baseline when coverage is complete.

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 (parses) plus the resource (TOON text) and names the concrete return artifacts (JSON value and canonical serialisation). It explicitly distinguishes itself from encode_toon, so an agent can tell the tools apart without opening any schema.

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?

Gives explicit when-to-use context ('text this server produced or a stored TOON document') and routes to both relevant siblings: encode_toon for producing text and compare_formats for format comparison rather than parsing.

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