First Kitchen · Lesson 04 of 10

The Kitchen Notebook

Lesson 4 of First Kitchen: stop repeating yourself. CLAUDE.md is a plain-text notebook your agent reads at the start of every session — your taste, your rules, your project's law. Write four lines once, and every future session starts already knowing you.

By now you've said "keep it one file" at least twice, and told two different sessions about your warm-bakery color taste. Annoying, right? Every new session, the agent shows up like a talented cook on their first day — skilled, but knowing nothing about your kitchen.

Professional kitchens solve this with a notebook by the pass: house rules, standards, the chef's taste, written once. Your agent has the same thing, and it's the highest-leverage file in this whole course: CLAUDE.md.

What you'll plate today

A project that remembers you. You'll write house rules once, restart the agent, and watch a brand-new session follow them without being told.

Ingredients

  • Your first-kitchen folder
  • About 25 minutes

Cook

1. Understand the trick (it's almost stupid)

CLAUDE.md is a plain text file in your folder. When Claude Code starts a session there, it reads that file first, automatically. That's the entire mechanism. No settings, no magic — a note on the counter that every shift reads before cooking.

2. Dictate your house rules

Open the kitchen and order:

Create a CLAUDE.md file for this project with these house rules:

- I'm a beginner. Before any change, tell me in one plain sentence
  what you're about to do.
- This site stays a single index.html file. Never split it.
- My design taste: [your Lesson 2 answer — e.g. "warm, like a bakery,
  one bold accent color"]. Keep new things consistent with it.
- After every change, remind me to refresh the browser.

Then explain back to me, in two lines, when this file gets read
and why it matters.

Read its two-line explanation — you should hear back roughly what section 1 just told you.

3. Prove it works (the fun part)

Rules only count if a stranger follows them. Get a stranger: type /exit, then start fresh with claude — a new session, blank memory, first day on the job. Now order something small with zero context:

Add a section to the page for books I'm reading.

Watch closely. It should announce the change in one sentence first (rule 1), keep everything in index.html (rule 2), style it warm (rule 3), and tell you to refresh (rule 4). Nobody told this session anything — the notebook did.

4. Add one rule of your own

You don't edit the file by hand (you can, but why start now):

Add one more rule to CLAUDE.md: [yours — e.g. "never use the word
'delve' anywhere on my page" or "always answer me in Korean"].

From now on, every time you correct the agent twice for the same thing, that's not an annoyance — that's a rule announcing itself. Send it to the notebook.

When it burns

  • The new session ignored a rule — usually the rule is buried in too much text. Keep the notebook short and blunt; ten sharp rules beat forty polite ones. Ask: "Read CLAUDE.md again and tell me which rule applies to what you just did."
  • You changed CLAUDE.md mid-session and nothing happened — it's read at session start. /exit, claude, new shift reads the new notebook.
  • The agent wrote a huge fancy CLAUDE.md by itself — trim it: "Cut CLAUDE.md down to only the rules I actually gave you." A bloated notebook is clutter the agent reads every session — keep it lean.

Order up

□ CLAUDE.md exists and contains YOUR rules, in plain words
□ A fresh session followed the rules without being told
□ You added at least one rule of your own invention
□ You know the reflex: corrected it twice? → notebook

This file is why next month's sessions will feel like working with someone who's known you for a year. (When you're ready for the deep end of this idea, we cooked a whole recipe on it: Karpathy's kitchen notes.)

Next up — Lesson 05: Save Points. Lesson 3's rescue relied on the agent's short memory. Time to install real, permanent save points — so nothing you do to this project is ever unrecoverable again.

Stuck on a step? Question box below.

Stuck at a step?

Ask right here — no account needed. If a step lost you, that's a hole in the lesson, not in you: answers get folded back into the text so the next cook sails through.

Hungry for more?

New recipes land in your inbox as they leave the kitchen. No spam, unsubscribe anytime.