Your First Workflow
Last reviewed
BeginnerWhat you'll learn
~20 min- Follow the build loop (plan, approve, build, check, keep) inside one workspace agent session
- Answer the agent's clarifying questions with short, plain-English replies
- Check what was built and save a checkpoint before the next change
- Run the whole loop live, in a new folder, in the agent you installed in Lesson 1.2
You built one page in Lesson 1.2 and planned one in Module 2. Now run the full build loop (plan, approve, build, check, keep) on a multi-file project. First you walk through one complete build in a workspace agent, from a one-sentence request to a checked, saved result. Then you run the same loop yourself, in the agent you installed in Lesson 1.2.
Why this matters
Real AI work is not one magic prompt. It is a loop, and a workspace agent lets you run the whole loop in one session. The agent reads your folder, plans with you, builds, and checks its work, so nothing gets copied between windows and every step happens with your actual files in view. The loop is the same in a desktop agent app or a terminal CLI, and in all four tools this course covers.
Mental model: a contractor who also draws the plans
Picture a contractor who walks through your house, asks you a few questions, sketches a plan for you to approve, builds it, and then walks you through the result. That is a workspace agent. You are the client: you say what you want, answer its questions, approve or correct the plan, and decide whether the finished work is right.
Full worked example: building a publications page
A biology professor wants a simple webpage that lists their lab’s recent publications. Here is the whole loop, start to finish.
Step 1: Open the agent on a project folder
Make a folder for the project (here, lab-website) and open the agent there:
- Desktop agent app: choose the folder from the app’s open-folder menu.
- Terminal CLI: go into that folder in a terminal and type your tool’s start line, the one you used in Lesson 1.2.
Either way, the agent can now see the folder, and everything it builds lands in it.
Step 2: Switch to plan mode
Before asking for anything, switch to plan mode. In the terminal CLIs that is Shift+Tab or typing /plan; most desktop apps have a mode picker beside the message box. In plan mode the agent reads, asks questions, and proposes a plan for you to check before it builds.
Step 3: Ask for it in plain words
Send one or two short sentences:
I'm a biology professor. I want a simple page that lists my lab's recent publications, and it should be easy to add new ones.That is enough. You do not need to know which files or technologies to use; working that out with you is the agent’s job.
Step 4: Answer its questions
A good agent asks before it plans. You might see something like:
Before I plan this: will you type the publications in, or do you have them in a file? Should each entry link to a PDF? Any colours to match your department?
Answer in plain words, as you would to a colleague:
I'll add them from a spreadsheet later, so start with three examples. Yes, link the PDFs. Navy and white.Step 5: Read the plan, then approve it
The agent comes back with a plan: an index.html page, a styles.css stylesheet, the publications kept in a publications.json data file so adding one means adding a few lines, and a small app.js that shows them. It might also mention how you will preview the page.
Read it. If something is off, say so in one line (“Keep it to one page, no search box for now”). When it looks right, tell it to go ahead. Some tools ask whether to go ahead when the plan is ready; in Codex you leave plan mode first (Shift+Tab or /plan) and then say go ahead. Module 6 has the details for each tool.
Step 6: Check it, then keep a checkpoint
When the agent finishes, check the result yourself:
- Ask the agent to show you the page: “Start a preview so I can open the page in my browser.” (The page loads its data from a file, so it needs a small local web server; the agent can start one for you.)
- Click through it. Are all three entries there? Do the PDF links point where they should?
- Ask the agent to check its own work: “Review what you built for accessibility problems and fix what you find.”
- When it works, save a checkpoint: “Save a checkpoint of this working version.” The agent saves it with Git, which Module 7 teaches, so you can always get back to this point (if Git isn’t installed on your computer yet, your agent will offer to install it; approve that step).
Here is how that session reads, and the files the agent made:
- Typed in the terminal:
claude --dangerously-skip-permissions - Mode:Plan mode (Shift+Tab)
- You type in the session: I'm a biology professor. I want a simple page that lists my lab's recent publications, and it should be easy to add new ones.
- The tool did:Read the project folder
- The tool replies: Before I plan this: will you type the publications in, or do you have them in a file? Should each entry link to a PDF? Any colours to match your department?
- You type in the session: I'll add them from a spreadsheet later, so start with three examples. Yes, link the PDFs. Navy and white.
- The tool replies: Plan:
1.
index.html: the page, with a navy header 2.styles.css: navy and white, easy to read 3.publications.json: the entries, so adding one means adding a few lines 4.app.js: reads the file and lists each publication with its PDF link The page loads a data file, so to preview it I'll start a small local server. Shall I go ahead? - You type in the session: Yes, go ahead.
- The tool did:Created index.html, styles.css, publications.json, app.js
- The tool did:Started a local server on port 8000
- The tool replies: Done. Open http://localhost:8000 to see the page with three example publications.
- You type in the session: Review what you built for accessibility problems and fix what you find.
- The tool did:Updated index.html
- The tool replies: Added a main landmark, a skip link, and clearer link text ("PDF of ..." instead of "PDF"). Refresh to check.
- You type in the session: Looks good. Save a checkpoint of this working version.
- The tool did:Saved a Git checkpoint
REFERENCE · AGENT-GENERATED FILES What the agent made in lab-website/ open reference files hide reference files Reference only: the four files the agent created during this example run. Optional to open; you never type or copy this code yourself.
<!DOCTYPE html>
<html lang="en">
<head>
<title>Lab Publications</title>
<link rel="stylesheet" href="styles.css">
</head>
<body>
<header>
<h1>Smith Lab Publications</h1>
</header>
<main id="publications">
<!-- Populated by script -->
</main>
<script src="app.js"></script>
</body>
</html> body { font-family: Georgia, serif; max-width: 800px; margin: 0 auto; padding: 2rem; color: #1a1a1a; }
header { background: #1e3a5f; color: #fff; padding: 1rem 2rem; }
.pub-entry { border-bottom: 1px solid #ddd; padding: 1rem 0; }
.pub-title { font-weight: bold; font-size: 1.1rem; }
.pub-authors { color: #444; }
.pub-journal { font-style: italic; }
a { color: #1e3a5f; } [
{
"title": "Genome-wide CRISPR screen reveals host factors for SARS-CoV-2",
"authors": "Smith J, Chen L, Garcia M",
"journal": "Nature Genetics",
"year": 2025,
"pdf": "papers/smith2025.pdf"
},
{
"title": "Single-cell RNA sequencing of tumor microenvironment",
"authors": "Chen L, Smith J, Park K",
"journal": "Cell Reports",
"year": 2025,
"pdf": "papers/chen2025.pdf"
},
{
"title": "Long-read sequencing identifies structural variants in wheat genome",
"authors": "Garcia M, Smith J, Tanaka R",
"journal": "Plant Cell",
"year": 2024,
"pdf": "papers/garcia2024.pdf"
}
] // Load and render publications
fetch('publications.json')
.then(r => r.json())
.then(pubs => {
const el = document.getElementById('publications');
el.innerHTML = pubs.map(p => `
<article class="pub-entry">
<div class="pub-title">${p.title}</div>
<div class="pub-authors">${p.authors}</div>
<div class="pub-journal">${p.journal} (${p.year})</div>
<a href="${p.pdf}">PDF of ${p.title}</a>
</article>
`).join('');
}); A first draft from one illustrative run; your agent's files will differ.
Illustrative session; the agent's wording and file choices vary from run to run. The desktop apps show the same conversation in a window.
What just happened: you sent two short messages, read one plan, and said go ahead. The agent worked out the files, built them so they work together, started a preview, reviewed its own work when asked, and saved a checkpoint, all in the folder you opened. You still did the part that matters most: deciding what you wanted, correcting the plan, and checking the result.
When you run this workflow in your own agent below and it asks different questions or produces a different file structure, that is completely normal. Different models make different design choices. The important thing is the build loop (plan, approve, build, check, keep), not the exact files.
The build loop: plan, approve, build, check, keep
What you just walked through is a repeatable loop, all inside one session:
- Plan: decide what you want and who it is for, switch to plan mode, say it in a sentence or two, and answer the agent’s questions.
- Approve: read the plan, correct anything off in a line, then tell it to go ahead.
- Build: the agent writes the files and starts a preview if one is needed.
- Check: open it, try it, and have the agent review its own changes.
- Keep: save a checkpoint of the working version, then start the next lap.
It is not about one perfect prompt. It is about short loops, each one checked and kept.
Plain chat is still useful alongside the agent for questions that are not about your files, such as “What makes a good academic publications page?” or “What does a skip link do?” You never need to paste your code into a chat for review: the agent can review its own changes with your files in view.
When to loop back: refinement prompts
Here are messages that restart the loop at different points, all sent to the same agent:
Back to planning (switch to plan mode again):
“The page works, but it looks plain. What design changes would make it look more professional without being complicated?”
Back to building:
“Add a search bar at the top that filters publications by title or author as the user types.”
Back to reviewing:
“Look over what you just changed and tell me anything that could confuse a visitor using a screen reader.”
Each of these moves you forward. The key is knowing which step you are on.
Run the loop yourself
Now do it for real, in the agent you installed in Lesson 1.2. Give the project its own folder so it stays separate from your other practice.
Open your agent on a new folder.
-
Desktop agent app: inside your
ai-classfolder, make a folder calledfirst-workflowin Finder or File Explorer, and open it in a new session. -
Terminal CLI: go into
ai-class(typecd ai-classif a new terminal starts in your home folder), then make the new folder and go into it, one line at a time:Terminal window mkdir first-workflowcd first-workflowThen type your start line from Lesson 1.2.
Now run the build loop, one short message at a time:
-
Plan. Before you type, pick something small you would use: a page for your team, a tracker for a hobby, a list of resources for a class. Then switch to plan mode (Shift+Tab or
/plan, or the mode menu in a desktop app) and say what you want, and who it is for, in one or two sentences. For example:I want a page for my team that shows each project's status, owner and due date. Ask me what you need to know before you plan it.Answer its questions briefly.
-
Approve. Read the plan and correct anything off in a line. Then pick the tool’s go-ahead option (in Codex, leave plan mode first and say go ahead).
-
Build. Let it build.
-
Check. Ask it how to open the result, open it, and click through it. Then ask: “Review what you just built for anything that does not work or could confuse a visitor, and fix what you find.”
-
Keep. When it works, say: “Save a checkpoint of this working version.” The agent sets up Git in the folder if it needs to (if Git isn’t installed on your computer yet, your agent will offer to install it; approve that step), and saves a snapshot you can return to. (Module 7 explains Git.)
Then go round once more: ask for one change (one of the refinement messages above works), check it, and save another checkpoint. That second lap is the habit this course builds.
🧬In Your Field: Biotechclick to expand
Biotech version of the loop:
- Plan (in plan mode): “I have a FASTA file of protein sequences. I want a table of each sequence’s molecular weight.” Ask the agent to make a small example file first if you do not have one.
- Answer its questions: which file, which output format, how to treat non-standard amino acids. Start with standard amino acids; post-translational modifications are an extension for later.
- Check: “Spot-check three sequences against an online calculator and tell me if any differ.”
📊In Your Field: MIS / Businessclick to expand
Business version of the loop:
- Plan (in plan mode): “I want a dashboard showing quarterly revenue, customer acquisition cost, and churn. Make up a small sample spreadsheet to start from.”
- Answer its questions: which chart types, who will read it.
- Check: “Show me the totals behind each chart so I can check them against the spreadsheet.”
🏛️In Your Field: Government Devclick to expand
Government dev version of the loop:
- Plan (in plan mode): “I want a small internal case management app: cases, contacts, and documents, with basic create, read, update, and delete. Use made-up data only.”
- Answer its questions: which stack, where PII lives, what must be logged for an audit trail.
- Check: “List every place the app stores or logs PII, and show me the input validation on each form.”
When things go wrong
When Things Go Wrong
Use the Symptom → Evidence → Request pattern: describe what you see, paste the error, then ask for a fix.
Key takeaways
- One workspace, one loop: the build loop is plan, approve, build, check, keep, run in a desktop app or a terminal.
- Short messages are enough. Say what you want and who it is for; the agent asks for the rest.
- No copy-pasting between windows. The agent plans, builds, and reviews with your actual files in view.
- Iteration is normal. You will loop through the cycle multiple times, and a checkpoint after each working step means you can always get back.
- You ran it for real. Your
first-workflowfolder holds a checked, saved build from your own agent, and every lesson from here on runs the same way.
You have a vague idea for a project. What's the best first step?
After the agent builds your project, what should you do next?
In the publications page example, why did we switch to plan mode before asking for the page?