Dashboard/Phase 1: Foundations
🔬 Lab20 min25 XP

Lesson 6: Lab — Your First Real Task

Day 6 of 50 · ~20 min hands-on · Phase 1: Foundations


The Mission

In the first five lessons, you learned the concepts behind Claude Code. Now it's time to experience it.

Your mission: Build a working CLI utility that reads a CSV file and generates a summary report in Markdown.

This is a real task. It's small enough to complete in 20 minutes, but complex enough to touch every concept from Lessons 1-5:

  • You'll have a multi-turn conversation with Claude
  • Claude will read your project (if you have one) or start from scratch
  • It will use the agentic loop multiple times
  • You'll see tool use in action
  • You'll see Claude check its own work

By the end, you'll have a working tool that does something useful.


What You'll Practice

  • Lesson 1: How Claude Code saves time on navigation and understanding
  • Lesson 2: Writing clear instructions and responding to permission prompts
  • Lesson 3: Watching the agentic loop work through a multi-step task
  • Lesson 4: Seeing tools in action (Glob, Read, Write, Edit, Bash)
  • Lesson 5: Watching Claude explore code structure

Setup

Option A: Start Fresh (Recommended for first time)

  1. Create a new project folder:

    mkdir claude-csv-reporter
    cd claude-csv-reporter
    
  2. Create a sample CSV file named data.csv:

    name,age,role,years
    Alice,32,Engineer,5
    Bob,28,Designer,3
    Carol,45,Manager,10
    David,26,Engineer,1
    
  3. You're ready. Stay in this directory for the conversation.

Option B: Use an Existing Project

If you have a real project you'd like to work with, navigate to it instead. Claude will adapt.


Step 1: Start the Conversation

Open your terminal in the project folder and start Claude Code:

claude

You'll see Claude ready for conversation. This is a multi-turn interaction — you guide it.

What to notice: Claude will ask you clarifying questions or wait for your instructions. You're in control of the pace.


Step 2: Give Claude the Task

Type your first message. Here's a good starting point:

I want to build a Node.js CLI tool that:
1. Reads a CSV file (data.csv)
2. Counts rows and shows basic stats (average age, count by role, etc.)
3. Generates a summary report in Markdown format
4. Saves it to report.md

The tool should be runnable with: node index.js

Can you help me build this?

What to notice:

  • Claude will likely ask clarifying questions or outline a plan
  • Claude might ask which libraries to use (csv-parser, papaparse, etc.)
  • Claude will break the task into steps
  • You'll see the agentic loop starting — Claude reads → reasons → asks questions

Step 3: Let Claude Build

Claude will now create files. You'll see prompts like:

I'm going to create index.js with the main CLI logic.
[Edit: /path/to/index.js]

What to notice:

  • Claude uses the Write or Edit tool to create files
  • It might create package.json and install dependencies
  • It will likely use Bash to run npm install
  • You'll be asked for permission before these actions (this is the permission prompt from Lesson 2)

For each permission prompt, just type yes or y and press Enter. Claude is being safe and asking before doing anything risky.


Step 4: Verify It Works

Once Claude claims to have built the tool, you might see:

Let me verify this works by running it:
[Bash: node index.js]

What to notice:

  • Claude uses Bash to run your tool
  • If there's an error, Claude will:
    • Read the error message
    • Reason about what went wrong
    • Fix the code
    • Run it again
  • This is the agentic loop's "check" phase

If Claude successfully generates a report, you're done!


Reflect

Once your tool is working, answer these questions:

  1. Agentic loop: Count how many times you saw the pattern: Claude read some code → explained what it would do → made a change → checked the result. How many loops did it take?

  2. Tools: Which tools did Claude use? (Write, Edit, Bash, Read, Glob, Grep?) How did each one help?

  3. Your role: What decisions did you make, and what did Claude decide? How did the conversation guide Claude?

  4. Understanding: Did Claude need to ask you clarifying questions? Why do you think it asked?

  5. Iteration: Did Claude make mistakes? If so, how did it fix them?


Bonus Challenge

If you finished early and want to go deeper:

Challenge 1 — Add features without starting over:

Now add the ability to filter the report by role. 
Show stats only for "Engineer" or "Designer" if I pass --role=Engineer as an argument.

Challenge 2 — Make it more robust:

Add error handling for:
- Missing data.csv file
- Malformed CSV (missing columns)
- Non-numeric age values

Challenge 3 — Extend the reporting:

Include a visualization: show age distribution as ASCII bars in the markdown report.
For example, show how many people are in the 20-30, 30-40, 40-50 age ranges.

For each challenge, watch Claude add features using the same agentic loop. Notice how it reads the existing code, reasons about the changes, adds them, and checks the result.


What You've Just Done

You've experienced Claude Code the way it's meant to be used:

  • You gave it a goal, not step-by-step instructions
  • Claude broke the goal into steps automatically
  • Claude read your project (or created it from scratch)
  • Claude reasoned about what to build
  • Claude used tools to act
  • Claude checked its work and fixed issues
  • You guided the process but didn't have to execute commands yourself

This is the superpower: Claude does the navigation, searching, and coordination — you just guide the mission.


← Back to Curriculum · Lesson 7 →