Lesson 03 · Part 3 35 min

Planning with Claude Code

Define a persona, map your tools, design the process, and build the instruction file that ties your entire workflow together.

Watch on YouTube

In this series

Where we are

You've picked a task, defined what "done" looks like, and built your context library. Now it's time to start talking to Claude Code. But not to produce output yet. You're still planning.

This part is about building the context.md file, the instruction set that tells Claude how to use everything you've prepared. By the end, you'll have a persona, a tool map, and a step-by-step process, all stored in one document that survives across sessions.

The context.md file

The first thing to do with a populated context library is point Claude at it and ask it to create a context.md file. Your prompt should include three things: where to look (the folder system), what you're trying to achieve (the goal and definition of good), and a design direction (recognisable references like "McKinsey clarity meets Apple design").

Claude will explore the folders, pull out brand colours, typography, and key information, and write a structured context.md in your instructions folder. This takes about 30 seconds.

Key Insight

The context.md is not a one-time setup. It's a working document that grows throughout the planning phase. Every decision you make, persona, tools, process, gets added to it. By the end, it contains everything Claude needs to produce output without you having to repeat yourself.

Managing your context window

One of the most common frustrations with Claude Code is running out of daily tokens. Most people hit their limit not because they're doing too much, but because they're wasting context without realising it. After creating the context.md, I cleared the conversation. Here's why.

Claude Code has a short-term memory called the context window. It comes preloaded with system instructions and configurations. Every prompt you send, every response Claude gives, every file it reads, fills it up. The part that catches people out: every new prompt carries the entire context window with it. So the fuller your window gets, the more tokens each interaction costs.

Core strategy

The name of the game when building on a shoestring is preserving your context window.

Two commands help you manage this:

Key Insight

Every decision you make during planning should be saved into your context.md. That way, when you /clear the conversation, nothing is lost. The context.md is your persistent memory. The conversation is temporary.

Defining a persona

With a fresh context window, the next question to explore in plan mode is: "What persona should my agent adopt?"

A good persona shapes both how Claude organises information and how it presents it. The trick is to combine two recognisable archetypes: one for structure, one for design. In the demo, I landed on "the ruthless clarity of a McKinsey engagement manager meets the visual precision of a senior Apple design lead."

Structure archetype How it thinks

McKinsey engagement manager, investigative journalist, academic researcher.

Design archetype How it presents

Senior Apple designer, editorial art director, data visualisation specialist.

Keep the persona clear but not over-detailed. It sets the tone, not the specifics. You want Claude to know how to think and present, not every detail of the task. Those belong in your instructions.

What doesn't work

These are common persona mistakes that either waste context or produce generic output:

Mapping your tools

Next, I asked Claude: "What tools are available to enhance my workflow?" The answer falls into two categories.

Internal tools Python libraries that run locally: Playwright (screenshots), Plotly (charts), CairoSVG (vector graphics), Pillow (image manipulation)
External tools Services connected via MCP: Slack, Gmail, GitHub, Vercel. Mapped for future use, not needed for this demo

The best practice: map everything, install only what you need. I had Claude create a separate tool-map.md with the full catalogue, then added only the relevant tools to context.md. Nothing gets installed until it's actually needed for a specific output.

Key Insight

Having the full tool map means you can come back to it when a future project needs something different. The context.md only references what's relevant right now.

Designing the process sequence

This is where you describe, in your own words, the step-by-step process your workflow should follow. It doesn't need to be polished. I dictated mine using voice-to-text and it came out rough, but Claude is excellent at turning messy thinking into structured plans.

The key is to give Claude your raw mental model and then ask: "Is this the right way of thinking about it, or would you add other bits to make it airtight?"

Claude agreed with the core sequence but suggested an addition I hadn't considered: a storyboard checkpoint to verify narrative flow before moving into design. The screenshot verification step was my instruction, not Claude's. Here is the final sequence we landed on:

Read and synthesise Combine all input into one coherent source
Enrich with research Optional step to fill gaps with external data
Break into sections Each section gets one clear message
Storyboard check If it doesn't flow when read aloud, restructure
Create HTML template Following persona and brand system
Populate the template Adapt layout per section type
Verify via screenshots Take screenshots, read them, fix issues, repeat twice

Step 4 is Claude's addition. The storyboard check catches structural problems before you invest time in design. The double screenshot verification in step 7 was an instruction I gave Claude, because it won't self-check its own output unless you explicitly tell it to.

Key Insight

You bring the raw thinking. Claude structures it and adds the quality control layers. The result is a process better than either of you would have designed alone.

Why HTML is the secret weapon

Large language models are trained on vast amounts of code and text. They are dramatically better at generating HTML than PDF or PowerPoint. PDF and PowerPoint are pixel-based coordinate systems designed for human users working in visual editors. HTML is a code description of layout, which is exactly what LLMs are good at.

Input Your content

Raw text, data, and brand assets from your context library.

Intermediate HTML

Claude generates styled, structured HTML as the working format.

Output PDF

A screenshot tool or Python PDF converter turns the HTML into a polished, print-ready document.

HTML has other advantages. The same file can be styled as an A4 document, a square carousel slide, or a horizontal presentation, just by changing dimensions. It's easy to edit, supports animations, and one CSS change updates the entire document.

Choosing the right model

Claude Code gives you access to different models, each with clear trade-offs between capability and token cost.

Opus Most capable. Use for planning, where quality of thinking matters most
Sonnet Balanced. Use for general execution and iteration
Haiku Fastest, cheapest. Use for quick surgical edits

On a £18/month subscription, you can't afford to use the most capable model for every prompt. The smart play is matching model capability to task complexity: heavy models for planning, lighter models for execution where the instructions do the heavy lifting.

What's next

You now have a context.md file with your brand system, agent persona, tool map, and a step-by-step process with quality checkpoints. You haven't produced a single output yet, and that's by design.

In Part 4, you'll hit go. You'll see the first draft, learn how to give structured feedback, and iterate to a polished output. Then in Part 5, you'll prove the whole system is reusable by running a completely different topic through the same four building blocks.

Ask me a question

About this lesson or anything AI-related

Ask me on LinkedIn Send me a message directly

Download PDF

Enter your details to download