Letting LLMs write a tiny DSL instead of JSON tool calls: is it worth it?

bye_ella · reddit · 2026-11-14

A Reddit discussion explores an agent design alternative: instead of step-by-step JSON tool calls, give the model a small DSL to write a full task program run by a validated interpreter. Pros: far fewer output tokens, no per-step round trips, grammar-constrained decoding even for small/quantized models, errors caught before execution. Open questions: models may reason worse in an unfamiliar DSL, and whole-program generation can't adapt to intermediate results. The poster asks for real production experience and whether to mix approaches.

Original post →

More from coding & agent

coding & agent channel →