All posts

How I Build Trust with a Coding Agent

I used Claude to build a job-tracking extension, focusing on how to keep AI-generated code maintainable, testable, and aligned with the product I wanted to build.

I’d like to stay organised, especially when I’m looking for a new role. Before AI, I kept track of the roles I’d applied for in spreadsheets, which was slow. Then I started using AI agents to speed things up, but I still had to prompt the agent every time. So I asked myself: what if I had a tool that recorded a role automatically whenever I clicked Apply or Save?

Why I built it

I looked online and found plenty of good Chrome extensions, but they often required a paid subscription or an account, or they did much more than I needed.

So I decided to build my own Chrome extension for this purpose. I started by giving Claude a clear specification and goal, and an hour later, I had a working prototype that looked like a finished product and solved the problem I had.

My next thought was, what if others could benefit from it too? But the prototype wasn’t ready to go public because the code was a mess.

From Prototype to Production

This time, I started with an empty project, kept the setup minimal, and added a few guardrails. Then I defined a multi-step workflow for the agent, gave it access to the browser, and used the prototype as context.

The workflow looked something like this:

  1. Plan the implementation. (I gave the agent the starting point.)
  2. Write tests before implementing the changes.
  3. Verify the work.
  4. Wait for my review and feedback.
  5. Repeat.

I decided to build the production version incrementally, starting with the smaller, critical pieces and building up until everything came together.

During reviews, whenever possible, I’d turn my feedback into a lint rule, an instruction in AGENTS.md, or a memory the agent could reuse in future iterations. That way, neither of us had to repeat the same mistakes. I gave feedback during the first few rounds, and after that, most iterations were good to go. My goal was to get out of the agent’s way and let it work like a trusted colleague.

For the feedback loop, while end-to-end tests are a great way for the agent to verify its work, they take time to write and run. For this project, I decided to have the agent test its work directly in the browser instead of spending time writing and maintaining end-to-end tests.

Since I asked the agent to follow TDD, it generated a lot of tests with each iteration. In my experience, agents can produce good test coverage without necessarily testing the right things, or write tests that don’t add much value.

To address this, I asked the agent to run mutation testing after implementation to check the quality of its tests and adjust them where needed. I didn’t set up a tool like Stryker, instead trusting the agent to find a suitable approach. However, I still reviewed what it did to make sure it was on the right approach.

The outcome

I know this is just a small project, and what worked here might not apply to larger projects, but I still learned a lot from building it and had fun along the way.

Tools like Claude are getting better every day. Compared to a few months ago, I find it easier to trust them, as long as I clearly define the goal and put guardrails in place to keep them focused on building a good product for users.

For me, prototyping and building features quickly is also a good way to figure out what works and what doesn’t, get a clearer idea of the final product, and decide whether it’s worth investing more time in.

This was a fun project to build, and it also made job hunting a little easier for me. It’s available for free on the Chrome Web Store, and the source code is available on GitHub.

All posts