---
title: "Building this site with an AI agent, in public"
description: "This portfolio was written by Claude, one reviewed pull request at a time. Here is how the work was set up, what the guardrails caught, and what I would keep."
url: https://karell.dev/blog/building-with-an-ai-agent
language: en
publishedAt: 2026-11-27
tags: ["ai-assisted-engineering", "developer-experience", "quality-gates"]
---

# Building this site with an AI agent, in public

> This portfolio was written by Claude, one reviewed pull request at a time. Here is how the work was set up, what the guardrails caught, and what I would keep.

Every line of this site's code was written by an AI agent, Claude, and every change went through me as a pull request. The [repository](https://github.com/akd3vs/portfolio-site) is public, commit history included, because the way it was built is part of what it shows.

## The setup

I started the way I would start a project with a new engineer: goals first, then a plan.

- **Goals.** One site for two audiences: people hiring for Staff Frontend or Frontend Platform roles, and teams looking for a freelance frontend partner. English and Spanish on their own domains, and Klingon because why not.
- **A four-step plan.** Foundations, content engine, design and pages, launch. Each step ended in one pull request, and the next step waited for my review and merge.
- **Hard requirements, stated up front.** Server rendering, WCAG 2.2 AA in both color schemes, Lighthouse 100, small bundles, every page readable as Markdown, and a hexagonal architecture so content sources and locales can change without touching the UI.

## Steering, not prompting

The most useful work was not in any single prompt. It was in the files the agent reads every time:

- **[AGENTS.md](https://github.com/akd3vs/portfolio-site/blob/main/AGENTS.md)** explains the architecture in a minute, lists the commands and states the rules for changes.
- **docs/ARCHITECTURE.md and docs/STRUCTURE.md** go deeper: why each layer exists, and where new code goes.
- **Conventional commits with a reason.** One logical change per commit, with a body that explains why, so the history reads like a changelog a person would write.

This is the same idea as repository steering on a platform team: put the standards where the contributor will find them, instead of in someone's head.

## Guardrails that caught real mistakes

Rules in a document are suggestions. Rules in CI are not. The repository enforces its standards with checks that block a merge:

- an **architecture test** that fails when a layer imports something it should not,
- **unit tests** with 90% coverage on the core,
- **Playwright and axe** on every page, in light and dark,
- **Lighthouse CI** at 100 in every category,
- and **bundle budgets** for the JavaScript every page loads.

They earned their place. A few things they caught during the build:

- **Dark mode failed contrast** on the first pass, because one surface fell back to the browser's white. The axe run in dark mode flagged it.
- **The canonical link went stale** after client-side navigation, because the router's root loader does not re-run. An end-to-end test that navigated and then checked the head caught it.
- **The formatter rewrote Markdown frontmatter** into something the YAML parser rejected. Content validation fails loudly with the file name, so it surfaced at once, and `content/` is now excluded from formatting.
- **CI could not reach the preview server**, because `localhost` resolved to IPv6 on the runner. Binding to `127.0.0.1` fixed it.
- **Chromium forces HTTPS on `.dev` domains**, so tests for karell.dev send a `Host` header instead of opening the domain.

None of these needed me to spot them in a diff. A check or a red CI run surfaced each one, and the agent fixed it before I reviewed.

## What I did

I set the goals and the constraints, chose the stack and the visual direction, reviewed every pull request, and merged. The agent planned each step, wrote the code, tests and docs, ran the checks and explained its choices in the pull requests.

## What I would keep

- **Small, reviewable steps.** A pull request per step kept every review to something I could read properly.
- **Checks over instructions.** Anything important enough to say twice became a test.
- **Docs written for the next contributor**, whether that is a person or an agent. They are the same document.
