bre.ai · 2026 · building with a coding agent

Building bre.ai with a coding agent

What I learned about trusting an agent with my codebase
commits in its first eight weeks
908
of those co-authored by the agent
898
standing rules in the agent's rules file
106

At a glance

My role
Designer and the only person directing the agent. I set what to build, wrote the rules it works under, and decided when a change was really done.
Timeframe
The app since 2025. This repo since July 25, 2026, and still going.
Tools
Claude Code as the coding agent, a rules file it reads at the start of every session, a static audit and about 145 test files, and Gemini inside the app itself.
The one thing
I designed the guardrails that let me trust a coding agent with a codebase I can't fully read myself.
Why

I'm the developer on the other side of the agent

bre.ai is the app I built to run my own life. It holds my tasks, my habits, my people, my plans for the weekend, and a coach on the left that can act on all of it. It runs on my Mac, and I reach it from my phone too. It's about 137,000 lines across 500 source files.

I'm a product designer, not an engineer. I didn't write those lines by hand. I directed a coding agent, Claude Code, and it wrote them. In the first eight weeks of this repo there were 908 commits, and 898 of them were co-authored by the agent.

So for months I've been the person on the other side of the prompt. I describe what I want, the agent plans it, edits a dozen files, runs something, and tells me it's done. Then I open the app and find out whether that's true.

That gap is the whole job. The agent is fast and usually right, and I can't read every diff. What I can do is decide what it's allowed to touch, what it has to prove, and what it can never do. I didn't plan to become a trust designer for my own tools. It just turned out to be the only way the app kept working.

A coding agent is only as useful as the reasons I have to believe it.
Trust

The week my tasks started moving on their own

On October 19 I asked the agent to clean up my task list. It did what looked right: it went into the store file and removed the finished tasks by hand. The next time the app synced, 27 of them came back as open, pulled from an older copy of my data.

Two days later it went the other way. "Plan Connecticut trip" and six other open tasks were just gone. I hadn't deleted anything.

The agent found the root cause, and it wasn't one bad edit. Unchecking a task wrote an empty value to the store, which deleted the record or left it marked complete. Then the cleanup dropped every complete record. Each step was reasonable on its own, and together they quietly lost my data.

That one shook me more than any crash. A crash I notice. A task that disappears just means I forget to do it.

So I gave tasks one door. They now change only through one script, with add, set, complete, reopen and delete. The script refuses to drop a record by id. And the server checks every write and puts back any task record a write leaves out. The agent can still be wrong, but it can't make my data disappear on the way.

When an agent touches data, give it one door, and make the door refuse to lose things.
Contract

The rules file is the contract we both sign

Every session, the agent reads one file before it does anything: CLAUDE.md, my version of an AGENTS.md. It has about 106 standing rules now. Almost every one of them is there because something went wrong, and the rule says so, with the date and my own words.

A few of them, in short:

  • Deploy only a change I asked to go live. Never merge to master, never send my data to a service I didn't choose. Work on a branch.
  • Tasks change only through the one script. Never hand-edit the store.
  • Undo is per entry. Every change goes through one function that saves a field-level patch, never a restore of a whole snapshot, because that wipes later changes.
  • Never take the focus of my real Chrome or touch my clipboard. It can open a tab in the background and fill a form or type a draft for me, then it stops before send, pay or submit.
  • A redesign keeps every feature in that surface's parity list. Walk the feature IDs before publishing.
  • Check your own UI change in a browser before saying done, in a background tab.

The part I'm proudest of is the format. A rule like "never restore whole-state snapshots" means nothing to a new session. "This wiped my later changes" does. The incident is what keeps the agent from arguing its way around the rule.

It also means the file learns. When I correct the agent, the correction goes into the file in the same turn, so I only have to say it once.

A rule with its reason attached survives a fresh session. A rule without one gets reasoned away.
Checks

If it burned me twice, it becomes a check

Rules only work if someone reads them at the right moment. For the mistakes I kept hitting, I stopped relying on that.

On October 24 I couldn't untick something I'd tapped by accident on my Today list. The only control that could undo it lived in page memory, so it vanished on reload. It was the third time that same shape had reached me in four days, each time fixed where it was found.

So I had the agent build an audit that reads the whole app and reports the failures I've actually been burned by, with file and line. Five of them block a change outright: a record held only in page memory behind a control, a do with no undo, a UTC day instead of my day, browser storage as the only home for my data, and a failure I never see. Before the agent hands me anything, it runs the audit.

The bre.ai coach has its own honesty check that has to pass before anyone says a chat change is done. It fails if the tests don't run at all, because a broken config once printed nothing and looked like a pass. And the gap was real: one test file in the app had a syntax error and never ran once.

A class of bug I've named twice isn't a judgement call anymore. It's a check.
Autonomy

What the agent does alone, what it asks, what it never does

I sort everything the agent might do by what happens if it's wrong.

Alone, it can work on a branch: edit code, run the tests and the audit, fix basic things like broken links or a dead path, and tell me in one line what it changed.

It has to ask before it deletes my data permanently or spends money. Those don't come back.

It never deploys a change I didn't ask to go live, never merges to master, never sends my data to a service I didn't choose, never commits secrets, and never takes the focus of my real browser. That last one came from September 29, when it clicked in my Chrome while I was dictating and cut me off mid-sentence.

I designed the coach inside bre.ai the same way. Small things in my own day, like checking off a habit or moving a task, it just does, with an undo right where it happened. Bigger things, like a new plan for my week, it proposes and waits. Anything that reaches someone I know is drafted for me to send myself. That one has no exceptions. The only messages that go out for me are errands, like a note to a customer service desk or a seller.

Moving a task and messaging a friend aren't the same kind of action, and the approval model shouldn't pretend they are.

The line between acting and asking should follow the consequence, not the effort.
Next

What I'd bring to Android Studio's Agent Mode

Gemini Agent Mode in Android Studio is solving the problem I've been living with, at a much bigger scale. It plans multi-step changes, shows the tools it uses, lets you approve or reject each change or auto-approve, reads rules files like AGENTS.md, connects to MCP servers, and checks its own build. I haven't built for Android, so these are patterns from my side of the agent, mapped to features it already has.

  • Plan view with risk on it. Show each step of the plan with what it touches, and flag the ones that are hard to take back, like deleting a file or rewriting data, before anything runs.
  • Approval that follows consequence. Asking about every edit trains people to click yes without reading. Let small reversible edits auto-approve, and save the stop for the risky steps.
  • Proof before "done". A passing build is the start. "Done" should say what ran, and what didn't get verified, in plain words.
  • Rules files that learn from corrections. When I reject a change and say why, offer to write that into AGENTS.md with the reason attached.
  • Checkpoints per change. Let me roll back one step without losing the good work around it.
  • Respect for my environment. The agent shouldn't take focus, touch the clipboard or reach outside the project without asking.
I want developers to trust the agent because it shows its work, not because they've stopped checking.
Receipts

Every time it broke, and what it became

What happened What it cost me The rule or check it became
Sep 26: the start of my day was written to only one of the two files that need it The Timer stayed on yesterday Sleep and wake go in through one command that writes both, never a hand edit
Sep 27 and 28: design rounds rebuilt screens from scratch and silently dropped features (cadence, edit, the priority toggle, reorder, the new task form; later the calendar's double-booked flags and nearby list) Features I'd already approved went missing, and I had to find each one Every surface has a parity list of feature IDs, and the agent walks it before publishing a round
Sep 29: the agent clicked in my real Chrome while I was using my computer It stole focus and cut off my dictation mid-sentence Never take the focus of my real Chrome or write to my clipboard; work in background tabs and stop before any send, pay or submit
Oct 10: told to create a task at high priority, the bre.ai coach said "High" and saved Medium, every day for two weeks Two weeks of tasks at the wrong priority while the chat told me otherwise One priority reader for every path, the coach reads the saved row back before answering, and tests use my real sentences
Oct 19 and 21: a cleanup removed finished tasks by hand, 27 came back from an old copy, then 7 open tasks vanished Tasks I'd finished reappeared, and tasks I still needed were gone Tasks change only through one script that refuses to drop a record, and the server puts back any record a write leaves out
Oct 24: the only control to untick an item lived in page memory, the third time that shape reached me An accidental tap became a dead end A static audit with five blocking classes, run before every handoff