All Topics
All Topics
Technology
Technology
Design
Design
Programming
Programming
Science
Science
News
News
Gaming
Gaming
Entertainment
Entertainment
Business
Business
Finance
Finance
Sports
Sports
Health
Health
Food
Food
Travel
Travel
Art
Art
Music
Music
Books
Books
Education
Education
Politics
Politics
Personal
Personal
No algorithm. No AI slop. No ads. Just RSS. Pro-human. Indie writers. Real journalism. Open web. Chronological. Hand toasted.

TOON: Token-Oriented Object Notation - A Compact JSON Format for LLM Prompts

By

royosherove

7mo ago· 21 min readenCode

Summary

TOON (Token-Oriented Object Notation) is a new data format designed specifically for LLM prompts that provides a compact, human-readable encoding of JSON data. It combines YAML's indentation-based structure for nested objects with CSV-style tabular layout for uniform arrays, minimizing token usage while maintaining lossless JSON representation. The format is particularly optimized for uniform arrays of objects, achieving CSV-like compactness while adding explicit structure to help LLMs parse and validate data reliably. The article presents the specification, benchmarks, and a TypeScript SDK for this new data format.

Key quotes

· 4 pulled
Token-Oriented Object Notation is a compact, human-readable encoding of the JSON data model that minimizes tokens and makes structure easy for models to follow.
TOON combines YAML's indentation-based structure for nested objects with a CSV-style tabular layout for uniform arrays.
TOON's sweet spot is uniform arrays of objects (multiple fields per row, same structure across items), achieving CSV-like compactness while adding explicit structure that helps LLMs parse and validate data reliably.
It's intended for LLM input as a drop-in, lossless representation of your existing JSON.
Snippet from the RSS feed
🎒 Token-Oriented Object Notation (TOON) – Compact, human-readable, schema-aware JSON for LLM prompts. Spec, benchmarks, TypeScript SDK. - toon-format/toon

You might also wanna read