DEV Community

Discussion on: TOON vs JSON: A Modern Data Format Showdown

Collapse
 
btullbmc profile image
btullBMC

It loosk like a CSV.
Why not just use a CSV?

Collapse
 
sreeni5018 profile image
Seenivasa Ramadurai

Hi There ,
The idea is to reduce the tokens ... so if we use CSV format then comma counted as the token too. And for LLM we can pass any suitable format with optimized tokens .

Thanks
Sreeni

Collapse
 
xwero profile image
david duymelinck

TOON has commas too, the only difference with tabular data is that TOON's header line has more characters.

TOON: users[3]{id,name,role,email}:
CSV: id,name,role,email

What happens when the data has a comma in it does it keep the quotes to prevent the data comma to be seen as a new column?

Thread Thread
 
j333t profile image
Jeet Shah

Signed in just to like.
Still don't know the benifit!

Thread Thread
 
sreeni5018 profile image
Seenivasa Ramadurai

Hi Jeet, Think about AI agents: they connect to external systems using tools or MCP servers, and their responses typically come back in JSON, not CSV.

Another important point enterprises have invested heavily in REST‑based microservices, and these also return JSON. Because of that, converting JSON into TOON format makes sense.

If your API happens to return CSV instead, that’s fine too you can still use it. I don’t see any issues with that approach.

Hope this helps