Lesson 1.1. Anatomy of an AI-Built Project

"Can you review it? About 15 hours."

A colleague built a full WordPress + WooCommerce site with an AI agent: shop, member area, single sign-on to an external LMS, a SCORM course builder, CI, staging. Launch is in six weeks. The request is short: "I need a real specialist to look at structure, security and quality. List first, don't fix anything yet."

You clone the repo. Five items at the root. Hundreds of commits from the last two weeks, almost all co-authored by an AI. Where do you start?

Goal

In 10 minutes you will:

  • recognise the typical layout of an agent-built repo;
  • know which files to read first and which to skip;
  • map the repo in five commands without opening the code.

Key concepts

The paper trail

An agent cannot remember between sessions, so a well-run AI project writes everything down. That is good news for a reviewer.

flowchart LR
  A["Agent instructions<br/>CLAUDE.md"] --> D["Docs<br/>architecture · brief · ADR"]
  D --> C["Code<br/>plugins · theme · tests"]
  C --> G["Git history<br/>slices · co-authors"]
  A --> G
ArtefactWhat it tells the reviewer
Agent instructions (CLAUDE.md)rules, stack, what must never happen
Architecture / findingsintended design, known risks
Build brief / session promptshow work was split into slices
ADRs / decisionswhy things are the way they are
Git historywhat was actually done, in what order

Typical layout

TEXT
CLAUDE.md                  agent rules, read first
bitbucket-pipelines.yml    CI
docs/                      architecture, brief, requirements
site/wp-content/           only custom code: theme, plugins, mu-plugins
site/tests/                unit, e2e, a11y
site/bin/                  deploy and test scripts

Third-party plugins are usually not in the repo. Remember that: it comes back in Module 6.

Read order

  1. Agent instructions file.
  2. The README of the code folder.
  3. Architecture doc: headings only.
  4. Git log: shape, not details.

Code comes last.

Code / commands

BASH
ls -la                                  # top level
cat CLAUDE.md | head -40                # agent rules
find . -name '*.md' -not -path '*/node_modules/*' | head -30
git log --oneline | wc -l               # how many commits
git log --format='%an%n%(trailers:key=Co-Authored-By,valueonly)' | sort | uniq -c | sort -rn

Common mistakes

SymptomCauseFix
Two hours in, still reading one pluginstarted from the coderead the instructions and docs first
"Where are WooCommerce and the forms?"expected third-party plugins in the repothey are installed on the server; note it
Reviewing a superseded draftdid not check which docs are currentthe instructions file says what is superseded

Practice

  1. List the top level.
  2. Count commits.
  3. Count commits with an AI co-author.
  4. List all Markdown docs.

Interview Questions

The agent writes down rules, decisions and known risks because it has no memory between sessions. They tell you where to look and what was intended.

Third-party plugins and their versions: they are installed on the server, so the repo alone does not describe the running site.

Save your progress

Sign in or create a free account to mark lessons as completed and continue the whole course. You will come back to this lesson.