← ClaudeAtlas

toonlisted

Token-Oriented Object Notation (TOON) format for LLM-optimized data encoding. Converts JSON to compact, human-readable format that minimizes tokens (~40% reduction) while improving LLM comprehension accuracy.
hackermanishackerman/claude-skills-vault · ★ 2 · Data & Documents · score 74
Install: claude install-skill hackermanishackerman/claude-skills-vault
# TOON Format Guide ## Overview TOON (Token-Oriented Object Notation) is a compact encoding of JSON designed for LLM input. Combines YAML-style indentation w/ CSV-style tables for uniform arrays. **Key benefits:** - ~40% fewer tokens vs JSON - 73.9% accuracy vs 69.7% for JSON in retrieval tasks - Explicit length declarations for validation - Lossless JSON round-trips ## Syntax ### Objects (YAML-style indentation) ```toon user: name: John age: 30 address: city: NYC zip: 10001 ``` ### Uniform Arrays (Tabular) ```toon users[3]{id,name,email}: 1,John,john@ex.com 2,Jane,jane@ex.com 3,Bob,bob@ex.com ``` - `[N]` = array length (req for validation) - `{fields}` = column schema (declared once) ### Scalar Arrays ```toon tags[4]: api,rest,json,toon ``` ### Non-uniform Arrays (Nested) ```toon items: - id: 1 type: book meta: pages: 200 - id: 2 type: video meta: duration: 3600 ``` ## Conversion Rules ### JSON to TOON 1. **Objects** => indented key-value pairs 2. **Uniform arrays** => tabular `[N]{fields}:` format 3. **Mixed/nested arrays** => `-` list notation 4. **Scalars** => quote only when containing `,` or special chars ### Examples **JSON:** ```json {"orders":[{"id":1,"item":"Book","qty":2,"price":29.99},{"id":2,"item":"Pen","qty":10,"price":1.99}]} ``` **TOON:** ```toon orders[2]{id,item,qty,price}: 1,Book,2,29.99 2,Pen,10,1.99 ``` **Neste