Agent skill · writing content · aradotso
toon-format
Expert skill for Token-Oriented Object Notation (TOON) — compact, schema-aware JSON encoding for LLM prompts that reduces tokens by ~40%.
Why this skill is useful
Provides a specialized encoding method for LLM prompts that reduces token usage significantly, which the AI wouldn't generate on its own.
What it needs
Requires @toon-format/toon installed locally. About 7k tokens when loaded. Last updated 2026-07-09. 70 stars on the source repository.
What this skill does
Token-Oriented Object Notation (TOON) Skill by ara.so — Daily 2026 Skills collection. TOON is a compact, human-readable encoding of the JSON data model that minimizes tokens for LLM input. It combines YAML-style indentation for nested objects with CSV-style tabular layout for uniform arrays, achieving ~40% token reduction while maintaining or improving LLM comprehension accuracy. Installation CLI Core API encode / stringify decode / parse Encoding options Format Overview Primitive scalars TOON encodes scalars the same way as YAML — unquoted when unambiguous: Nested objects (YAML-style indentation) Flat arrays (scalar items) Square brackets declare the array length, values are comma-separated: Uniform object arrays (tabular format) Curly braces declare the field headers; each subsequent indented line is a row: Quoting rules Values containing commas, colons, or newlines are quoted: Mixed nesting Using TOON with LLMs Direct prompt injection Anthropic / Claude Token count comparison utility Common Patterns Batch API calls with TOON RAG / retrieval context injection Streaming encode for large datasets Schema-aware encoding (TypeScript) Express middleware for TOON content-type When to Use TOON vs JSON Scenario Recommendation --- --- Uniform arrays of objects ✅ TOON (biggest savings) Deeply nested / non-uniform ⚠️ Benchmark both; JSON-compact may win Pure flat tabular data Consider CSV (smaller) or TOON (structured) Latency-critical (local models) Benchmark TTFT + tokens/sec Programmatic API calls Keep JSON; encode to TOON only for LLM input Semi-uniform (~40–60% tabular) Benchmark; savings diminish Troubleshooting Values with commas parse incorrectly Wrap them in double quotes in your TOON string, or ensure encode() handles it automatically: Round-trip type loss (numbers vs strings) TOON uses unquoted values for numbers and booleans. …
How to use it
Reference it in AdaL, Claude Code, Cursor or any coding agent — nothing to install:
@skills aradotso/toon-format