---
title: "Five constraints that stop my site becoming slop"
description: "In order to make this website easy to maintain and write for, I need to use the power of AI, but with great power comes great responsibility."
url: https://www.sammullins.co.uk/articles/constraints-stop-slop/
date: 2026-12-01
updated: 2026-12-01
authorship: Sam + AI
---

# Five constraints that stop my site becoming slop

In order to make this website easy to maintain and write for, I need to use the power of AI, but with great power comes great responsibility.

Despite putting a large amount of engineering time into the platform my old site ran on ([xStatic](/software/xstatic-for-umbraco/)), I never found the time to get round to writing the articles. It was just too arduous to use my PC only, write the content by hand, and build each Umbraco page component by component. I didn't even consider upgrading through 10 Umbraco versions!

So when I rebuilt this site, I took an agent-first approach, where everything is streamlined for quick copywriting from many devices. I moved to Markdown files on [Astro](https://astro.build/), which I can split across my computer and my laptop, and reach from my phone through my agent development environments. But leaving all of the decisions to the agent would only give me an inconsistent, poor project that reads like it was written by a robot, not by me. What keeps that out is a constraint at each stage, from the first build to the moment a page goes live.

## 1. Build: a spec and tests before any page

Without them, an agent copies what's in front of it, mistakes and all.

My first attempt had no spec. I asked early Gemini 3 models for a 1:1 port of the old UIkit styles, component by component, so the agent kept the old site's structure when really it needed building from the ground up. It was just hard work: about a tenth of the content made it across, and the build produced five pages. A port has no spec beyond "make it like this", and that's exactly the brief that turns into slop, especially on older models. The second attempt, with [Claude Opus 5.5](https://www.anthropic.com/claude) and a spec-first process, brought the majority of the site across in pretty much one shot.

### What the spec looked like

Before any code was written, I directed the model to grill me about what the site was for, one question at a time. The answers became [a decisions record](https://github.com/Mulliman/sammullins.co.uk/blob/main/_docs/decisions.md), and from that it built a task graph as files in the repo: [one ticket per file](https://github.com/Mulliman/sammullins.co.uk/tree/main/_tasks), each listing the tickets it depends on, so everything was done in the order it needed to be. All of it went in the repo's first commit, before the scaffold. The agents worked ticket by ticket from there, picking up only those whose dependencies were done.

### The spec, turned into checks

A spec only helps while the agents follow it, so the rules that mattered became checks they can't argue with. `pnpm verify` runs them all on my machine, in the same order as CI, and I don't push until it passes.

- **Types**: TypeScript on its strictest settings, and a [Zod](https://zod.dev/) schema for every page.
- **Tests**: Unit tests fail on a hard-coded colour, a fixed pixel gap, or docs that no longer match the code.
- **Supply chain**: pnpm won't install a package version [less than a week old](https://pnpm.io/settings#minimumreleaseage), and `pnpm audit` blocks known high-severity holes.

## 2. Draft: a voice guide before any prose

Without one, a model writes like every other model.

### Rules from what I'd actually written

I didn't want a model writing for me; I wanted the words to still sound like me. So I took my old articles and had it distil them into a skill. Its guide is a list of rules that every writing skill loads before it touches a draft, and some of them read like this:

```markdown
- Plain and specific. Name the tool, library, version or platform, and say what it was used for.
- Say what broke or was harder than expected. Be honest about limits.
- Light, dry humour: at most one wry aside per piece. No jokes in code, steps or warnings.
- Never invent numbers, versions, dates, benchmarks or links. Put a placeholder in square brackets and ask Sam.
```

An excerpt of _docs/voice.md. Full file: https://github.com/Mulliman/sammullins.co.uk/blob/main/_docs/voice.md?plain=1

### Ideas come from me, and get questioned

I dictate the idea, and the model asks questions until it knows what the piece is about. It drafts with [the guide](https://github.com/Mulliman/sammullins.co.uk/blob/main/_docs/voice.md) loaded, Claude Opus and Gemini review the drafts overnight, and a fact-check lists every claim and what backs it. If it doesn't know a version or a date, it leaves a gap and asks me.

## 3. Design: blocks before layout

Without them, every page an agent writes comes out looking a bit different.

If you just let the agents build the HTML however they want, each page could look very different. So every page here is a list of blocks, and each of the 24 block types has a schema ([Zod](https://zod.dev/)) very similar to how I'd create sites in Umbraco and Sitecore. The build fails if anyone, human or agent, writes a page the site can't render. This band starts like this in the article's file:

```yaml
- type: "section"
  surface: "muted"
  blocks:
    - type: "intro"
      number: 3
      heading: "Design: blocks before layout"
    - type: "prose"
      markdown: "If you just let the agents build the HTML…"
```

An excerpt of constraints-stop-slop.md. Full file: https://github.com/Mulliman/sammullins.co.uk/blob/main/src/content/articles/constraints-stop-slop.md?plain=1

### The trade-off

Articles are quick to lay out and still look like one site, and every colour lives in one folder, so [the calendar](/aidvent/) is one new block and a Christmas theme. The cost is that an agent can only use the blocks that exist. Anything new is a code change first, and laying articles out in bands like this one broke the reading time until the code caught up.

## 4. Verify: the pages, not just the code

Without it, an agent can quietly make the site worse and still say it's done.

- **Accessibility**: [axe](https://github.com/dequelabs/axe-core) checks every page against WCAG 2.2 AA.
- **Speed**: [Lighthouse](https://developer.chrome.com/docs/lighthouse/overview) scores five representative pages: at least 95 for performance, 100 for accessibility, and the main content painted within 2 seconds.
- **Valid pages**: Every page is checked for valid HTML, and every internal link has to resolve.

### Cheap to add, so add them all

The code can pass every test and the pages can still be worse, so these run on the built site, the same files that go live. With agents doing the work it's so quick I don't have to choose between creating a GitHub action or going to the pub quiz. The accessibility and old-URL tests went in on the first day and Lighthouse on the second, each one a ticket an agent picked up. The repo is [public](https://github.com/Mulliman/sammullins.co.uk), so all of it is there to read.

### What it caught on the first run

The first time Lighthouse ran, the original home page failed. It scored 89 to 94 for performance against a budget of 95, because the hero photo and its blurred backdrop were being decoded on the main thread just as the page first painted. Nothing looked wrong, and every test passed. The agent switched the images to decode in the background and shrank the backdrop to a 160px file, since it's blurred anyway, and the home page then scored 97 to 99.

## 5. Publish: a person merges, and the label says who wrote it

Without it, agent output goes live unread, and AI words pass as mine.

### Nothing goes live without me

Certain code changes can merge automatically once every check is green, but anything touching content, hosting or the rules the agents follow waits for my approval. Until I give it, the merge check stays red, and the agents aren't allowed to give it for me. This article waited like every other.

### Every page says who wrote it

If an agent helped with the words, the page says "Sam + AI", in the footer and in the **Agent view**, which every page has a button for at the bottom. This piece is one of them, and you can check:

The Agent view shows the Markdown twin every page has, which a language model would rather read than HTML, and an [llms.txt](/llms.txt) file lists them all for any AI tool that asks.

The whole site is public: the code, the decisions record, the tickets and the skills the agents use.
