FLSoft Academy

MODULE 1 · GETTING STARTED / 25 MIN Free NOVEMBER 2026 EDITION · CLAUDE CODE 2.1.318

Your first task: the agent loop

Give Claude a real change to make, watch the gather → act → verify loop, learn the permission modes, and undo anything with checkpoints.

Updated 5 November 2026 · Reviewed 5 November 2026

What you’ll be able to do

Give Claude Code a small change, follow what it’s doing at each step, pick the right permission mode, and undo anything with a checkpoint.

The loop

Every task, big or small, runs the same loop:

  1. Gather context. Read files, search for symbols, look at git history.
  2. Act. Edit files, run commands.
  3. Verify. Run tests or the build, read the output.
  4. Repeat until done, then summarise what changed.

You don’t have to micromanage the loop, but you should be able to see it. That’s how you build trust in the tool.

Permission modes: who approves each action

Press Shift+Tab to cycle through modes. The status line shows the current one.

ModeStatus lineWhat runs without asking
Manual⏸ manual mode onReads only. Everything else asks you
Accept edits⏵⏵ accept edits onReads, file edits and basic file commands in your project
Plan⏸ plan mode onRead-only exploration, then a plan for you to approve (lesson 2.3)
Auto⏵⏵ auto mode onMost actions. A classifier reviews each one in the background and blocks risky ones, such as force-pushes, curl | bash or production deploys

In current versions, auto mode is the default for new interactive sessions. It’s fast and safe for everyday work, but it hides the loop’s decisions from you. For this lesson, switch to Manual so you see every approval.

Set up a practice repo

mkdir loop-practice && cd loop-practice
git init
npm init -y
claude

Press Shift+Tab until you see manual mode on.

Exercise: build a small feature with tests

Paste this prompt:

Create a small plain-JavaScript Node module `slugify.js` exporting slugify(text):
lowercase, trim, replace any run of non-alphanumerics with a single "-", strip
leading/trailing "-". Add tests using node:test in slugify.test.js covering at
least 5 cases including unicode accents ("Crème Brûlée" -> "creme-brulee").
Add an npm "test" script and run the tests until they pass.

Watch for these moments:

  • The plan. Claude often lists what it’s about to do. Read it.
  • Edit approvals. When Claude wants to create or change a file, you’ll see the content or a diff. Approve it.
  • Command approvals. When it wants to run npm test, choose Yes, and don’t ask again to save a permission rule for that command.
  • Self-correction. If the accent case fails, Claude will usually see the failure, fix the code (for example with normalize('NFD')) and run the tests again.

Now switch to auto mode and ask for one more change: “Add a maxLength option that truncates on a word boundary, with tests.” Notice how few prompts you get.

Steering: the controls you’ll use daily

ActionHow
Interrupt the current stepEsc
Open the rewind menu (restore code and/or conversation)Esc Esc on an empty prompt, or /rewind
New line without sendingShift+Enter, or Ctrl+J in any terminal
Run a shell command yourselfStart with !, e.g. !npm test. Claude sees the output and responds to it
Point Claude at a fileType @ and pick the file
See the full detail of each tool callCtrl+O

Try it: while Claude is working, press Esc, then type “Also handle empty strings by returning an empty string.” It picks the task up again with your correction.

Checkpoints: undo without fear

Claude Code saves a checkpoint of your files before every prompt. Open the rewind menu (Esc Esc), pick a prompt, then choose:

  • Restore code and conversation: go back completely
  • Restore code: keep the conversation, undo the file changes
  • Restore conversation: keep the files, rewind the chat
  • Summarize from here / up to here: compress part of the history to free context

Try it: ask Claude to “rename slugify to toSlug everywhere”, then rewind to before that prompt and choose Restore code.

Checkpoints don’t track files changed only by shell commands (for example rm or a code generator). They’re for quick, in-session undo. Git is still your real history.

Reviewing the result

Before you accept that a task is finished, check it yourself:

!git status
!git diff
!npm test

Or run /diff to review all changes in the working tree. You’re the reviewer: Claude is fast, but you decide what gets committed.

Verify it worked

  • slugify.js and slugify.test.js exist and npm test passes
  • You worked in Manual mode, then in auto mode, and noticed the difference
  • You interrupted Claude at least once and redirected it
  • You restored code from a checkpoint with the rewind menu

Next: working across a longer session: slash commands, resuming work, and managing context.

Knowledge check

4 QUESTIONS · PASS MARK 80%
1. A new interactive session shows `⏵⏵ auto mode on`. What does that mean?
2. Claude is heading in the wrong direction halfway through a task. What is the best move?
3. Claude's last two edits broke the build. What's the fastest safe way back?
4. Why does it matter that Claude can run tests itself?

Tip: select the text that's wrong before clicking, and it's quoted in your report.

Report a problem

Lesson: Your first task: the agent loop

What's wrong?