(How we work)All articles

One line in, a reviewed feature out

How we add features to our own bookkeeping app: a small software factory of AI agents does the work, and a person keeps the last word.

The software factory

A feature starts as a single line in a backlog, for example “SIE import in the UI. The parser exists, but only scripts use it.” From there it goes through the same steps every time. Each step is an agent with one job, and each one writes its result to its own file.

A flow chart. An item from the backlog becomes a spec, then a build on its own branch. Four reviews run in parallel: security, UX, UI and code. If they ask for changes the work goes back to the build, at most two rounds. If all pass, an approver either merges to main or escalates to a person. A person also takes over when the round limit is reached, and can approve the merge or send the work back for rework.
The loop: agents build, review and decide if the change can be merged directly or if a human needs to have a look at it first.

The reviewers read the same code from four directions, and the round is only done when all four have answered. Four independent opinions are worth more than one opinion repeated four times.

The factory board, a dark dashboard with columns for Spec, Build, Review, Approve, Needs human and Merged. The audit trail job is in Review, and ten jobs are in the Merged column.
The factory board. Every job is a card that moves from left to right, and the agent is now running 4 different types of reviews.
  1. Stage: every stage

    Agent: /factorythe orchestrator, a skill

    No model Writes: board.json, git merge
  2. Stage: spec

    Agent: spec-writer

    Model: opus Writes: spec.md
  3. Stage: build

    Agent: builder

    Model: opus Writes: code on factory/<job-id> + build.md
  4. Stage: review

    Agent: reviewer-security

    Model: opus Writes: round-N/review-security.md
  5. Stage: review

    Agent: reviewer-uxreviewer-uireviewer-code

    Model: sonnet Writes: round-N/review-<ux|ui|code>.md
  6. Stage: approve

    Agent: approver

    Model: opus Writes: decision.md
The stage is the stage field in board.json. All job files live in factory/jobs/<job-id>/.

The app, in brief

Bokjox is a web-based bookkeeping app for Swedish limited companies. You upload receipts and invoices and an AI suggests the postings. You can also book by hand, read the ledger, the income statement and the balance sheet, and send customer invoices as PDF or email, with reminders.

The top of Bokjox's overview page in Swedish: a dark teal menu on the left, four coloured summary cards for result so far, unpaid invoices, items to review and the next VAT deadline, and the start of two charts. A red stamp reads TEST DATA.
The overview page

Bookkeeping is a good place to learn how to build with AI, because it is unforgiving. A wrong number is not a layout glitch. So the question was never whether AI could write the code. It was how to keep a person in charge of the result.

What it looks like

The latest feature was an audit trail with period locking: a change log, and a way to freeze a month once its VAT return has been filed. The whole job started from one line:

Audit trail and period locking. Corrections exist, but there's no change log or lock.

Experience and AI, in that order.

All four reviews passed, with a few minor remarks. The security reviewer pointed out that an error message was carried in the page address and shown as written, so a crafted link could show any text as if the app had said it. We asked for it to be fixed. The builder replaced the text with a short code that the server turns back into a message, and the reviewers went round once more. Nothing dramatic, which is exactly the point.

Where a person steps in

The decision step can merge on its own, but it is told to stop at certain things: a change to the database schema, or to the code that posts a voucher. This feature touched both, so it waited for us. A person read the result, approved it and applied the database migration by hand, after taking a backup.

The agents do

  • write the spec and the acceptance criteria
  • build it and write the tests
  • review it for security, UX, UI and code
  • keep a written trail of every step

A person owns

  • what goes in the backlog
  • anything that touches the real data
  • the migration, and the backup before it
  • the final yes

The agents never touch the database that holds the real books. Database changes are written as files and applied by a person.

The short version

  • One line is enough. A spec agent fills in the rest.
  • Many eyes. Four reviewers, each looking for something different.
  • A limit. Two rounds, then a person.
  • A paper trail. Every spec, review and decision is a file in the repo.
  • A human gate. Anything that can hurt the data waits for a person.

So far the loop has handled several jobs, from SIE export and an annual report in PDF to the audit trail above. It is one way of working, and certainly not the only one.

(Your turn)Curious how this could work for your product?

Tell us what you want to build.

hello@digitalavenue.se

A few lines is plenty. We will ask the rest.

All articles