← all exhibits

EXH-04sample entry — swap with a real artifact

Ledgerline

A budgeting CLI with a full-screen TUI — double-entry ledger in plain text files, rendered like a Bloomberg terminal for one.

  • cli
  • tui
  • rust
A text-user-interface table with muted rows and one amber highlighted row
Model
Claude (Fable 5)
Iterations
5
Time to ship
14h
Shipped
Feb 8, 2026

The prompt · verbatim

Build a terminal budgeting app in Rust with ratatui. Data model: plain-text double-entry ledger files (a subset of the beancount format — parse only transactions, accounts, and balances; reject everything else with a line-numbered error).

TUI LAYOUT: three panes. Left: account tree with running balances. Center: transaction register for the selected account. Bottom: a 12-month sparkline of net flow. Keyboard only — hjkl navigation, / to filter, a to add a transaction via a modal form.

THE ONE RULE THAT MATTERS: the ledger file is the source of truth. The app never holds state the file doesn't; every edit is a file append, and the file must remain hand-editable and diffable. If the app crashes, the data is exactly as valid as before launch.

ERRORS: a malformed ledger line shows the filename, line number, and a caret under the offending token — compiler-quality errors, not "parse failed".

QUALITY BAR: cold start under 50ms on a 10,000-transaction file. Ship with a demo ledger so `ledgerline demo` works with zero setup.

Why it works

  • One architectural invariant, stated as law. “The file is the source of truth” answered dozens of design questions (undo, sync, crash recovery) before they were asked.
  • Compiler-quality errors were requested by analogy — “filename, line number, caret” — which is far more transferable than “good error messages”.
  • ledgerline demo is onboarding as a feature. A reviewer can experience the tool in ten seconds, which is what a portfolio artifact needs most.