JDogo

Half the tokens.
Every value back.

The token-efficient data layer for LLM apps. Send models half the tokens, get exact numbers back, and read every byte in Java, Python or TypeScript.

pip install ./sdk/python
JSON121 tokens
[{"id":1001,"name":"Ada Lovelace","role":"admin","city":"London","active":true},
 {"id":1002,"name":"Grace Hopper","role":"editor","city":"New York","active":true},
 {"id":1003,"name":"Alan Turing","role":"viewer","city":"London","active":false},
 {"id":1004,"name":"Katherine Johnson","role":"editor","city":"Hampton","active":true},
 {"id":1005,"name":"Edsger Dijkstra","role":"viewer","city":"Austin","active":false}]
JDogo69 tokens, 43% fewer
@id+,name,role,city,active
1001,Ada Lovelace,admin,London,true
1,Grace Hopper,editor,New York,true
1,Alan Turing,viewer,London,false
1,Katherine Johnson,editor,Hampton,true
1,Edsger Dijkstra,viewer,Austin,false
Counted with the GPT-4 tokenizer (cl100k). id+ stores each id as the step from the row above.

Smallest prompt on 60 production payloads.

Tables, nested API responses, logs, time series and agent traces. Same data, every format, one tokenizer.

See every case

Checked on TOON's own data. We reproduce TOON's published counts token for token, and JDogo comes in 7.9% under TOON and under CSV. How

−53.0%tokens vs JSON
−30.3%tokens vs TOON
−29.0%gzipped vs JSON
200/200exact round trips

Put a number on it.

Your traffic, your model price. The reduction starts at the benchmark average; measure your own payload in the playground for an exact figure.

You save every month $5,300 $10,000 with JSON, $4,700 with JDogo. $63,600 a year.

Learn it in ten seconds.

One header line says what every column holds. Rows carry only what changes. No schema file, no build step.

@
Column names, written once.
id+
Whole numbers stored as the step from the row above.
sku^SKU-+
A shared prefix, lifted out, then the step.
status=open
Same in every row, so no cell at all.
~ ""
Null and empty string stay different.
Full format guide
Six orders180 tokens in JSON, 82 in JDogo
@id+,sku^SKU-+,status=open,city,qty,note
5001,8100,Cairo,3,~
1,7,Lima,12,fragile
1,7,Oslo,5,""
1,7,Cairo,5,fragile
1,7,Lima,40,"rush, cold chain"
1,7,Cairo,7,~

Decodes to the exact JSON it came from: same keys, same order, same values.

Stop asking models to count.

With ask(), the model never sees your rows. It reads a short schema card, writes a one-line query, and the SDK computes the exact answer locally.

  • Far smaller prompts on big tables
  • Model text is parsed, never executed
  • Falls back to rows when a question needs them
How ask() routes questions
You ask

How many London users are active?

Model writes count where city = "London" and active = true
SDK computes

1

Model writes the query150/150
Model reads the rows74/150

Counting and totals questions, three models, recorded runs.

Give your agents exact answers.

JDogo ships an MCP server. Claude Desktop, Cursor and any MCP client get eight tools: compress data, build prompts, summarise tables, and compute counts and totals locally instead of guessing.

Set up the MCP server
claude_desktop_config.jsonone entry
{
  "mcpServers": {
    "jdogo": {
      "command": "java",
      "args": ["-jar", "jdogo-cli-2.1.0.jar", "mcp", "start"]
    }
  }
}
  • jdogo_computeexact counts, sums, averages
  • jdogo_promptthe measured prompt layout
  • jdogo_schema_carda table in a few hundred tokens
  • jdogo_compress jdogo_decodelossless both ways
  • jdogo_tokensexact token counts
  • jdogo_diff jdogo_patchsend only what changed

Write in one language. Read in any.

Java, Python and TypeScript write the same format and decode each other's output exactly. Every pair is checked on every build.

Written byJava readsPython readsTypeScript reads
Java writes✓✓✓
Python writes✓✓✓
TypeScript writes✓✓✓

203 shared reference vectors and thousands of fuzzed values per build, plus a jdogo command in all three.

  • pandas
  • FastAPI
  • Flask
  • Express
  • Next.js
  • Vercel AI SDK
  • LangChain
  • Spring Boot
  • Spring AI
  • MCP
  • Jackson
  • llama.cpp grammars
import jdogo

text = jdogo.dumps(rows)          # JSON value in, JDogo text out
rows = jdogo.loads(text)          # exactly the same value back

prompt = jdogo.format_query_prompt("Who is in London?", rows)

Built to be trusted with production data.

Lossless, proven

200 of 200 test cases come back exactly, including 50-digit decimals, special floats and delimiter storms. TOON: 192. Avro: 161.

Hostile input, handled

Depth and size limits on by default. Every decoder is fuzzed with broken and malicious text and must fail cleanly.

No migration

Plain JSON is valid JDogo. Readers accept both, so you can switch one service at a time.

Where it pays off.

Big wins

  • Lists of records: API results, query rows, logs, events
  • RAG context and tool-call results sent to a model
  • Service-to-service payloads, smallest once gzipped

Keep JSON for

  • Payloads under about 100 tokens
  • Clients you can't add a JDogo reader to

Paste your JSON. See the cut.

Every format, real token counts, exact round-trip checks, in your browser.

Open the playground