Skip to content
beginner 40 min read ⚡ 500 XP by CMSG Team · Mar 5, 2026
claude ai cli anthropic

Claude CLI: The Architect’s Assistant

Course Overview

Claude Code is the cutting-edge agentic CLI from Anthropic. In this course, you will learn to integrate Claude into your terminal workflow, build Agentic SOPs (Directives), and master the art of Tool-Augmented Reasoning for professional software engineering.

⚡ Instant QuickStart: The First Summon

Initialize Claude in your project in 30 seconds.

# 1. Install & Login
npm install -g @anthropic-ai/claude-code
claude login

# 2. The First Action
claude "Initialize a TODO.md in this project and audit my package.json for outdated deps."

Learning Objectives

  • Master SOP-Driven Engineering using directives/ and PROMPT.md.
  • Leverage Claude’s ability to Self-Anneal Arcane Glossary The ability of an AI agent to detect its own errors (e.g., build failures) and automatically fix them without human intervention. (fix its own errors).
  • Implement the 3-Layer Architecture (Directive, Orchestration, Execution).
  • Use MCP (Model Context Protocol) Arcane Glossary Model Context Protocol. An open standard that allows AI models to connect with local tools, data, and APIs securely. to extend Claude’s reach into local databases.

Prerequisite Rituals

Verify your circle before starting

Check all to unlock lesson focus READY TO CAST

Technical Deep Dive: The 3-Layer Architecture

For maximum reliability, we structure agentic work in three layers:

  1. Layer 1: Directive (SOP): A markdown file in directives/ that defines what to do.
  2. Layer 2: Orchestration (Agent): Claude reads the directive and decides which tools to call.
  3. Layer 3: Execution (Scripts): Deterministic Python/Node scripts that handle the “heavy lifting” (API calls, DB migrations).

Walkthrough: Building the “Self-Healing” Tool

Step 1: The Directive

Create directives/audit_site.md.

# Site Audit SOP
1. Check if the site is reachable via `curl`.
2. If down, check logs in `/var/logs/app.log`.
3. Propose a fix and execute if approved.

Step 2: The Orchestration

Invoke Claude with the directive.

claude "Follow the SOP in directives/audit_site.md for the local dev server."

Step 3: Self-Annealing Loop

If a tool fails, Claude is trained to read the error message, fix its own script, and try again. This is called Self-Annealing.


Pro Patterns: Directives vs. Prompts

  • Prompts are for one-off questions.
  • Directives are for repeatable, business-critical workflows.
  • Rule of Thumb: If you’ll do it more than twice, write a directive.

Capstone Project: The Automated DevOps Agent

Build a system where Claude monitors a deployment.

  1. Write a Directive for checking build health.
  2. Link Claude to your Cloudflare Pages status through an MCP server.
  3. Implementation: Claude identifies a build failure, reads the log, and fixes the offending code automatically.

You are no longer coding alone. You have an architect by your side.

📜 The Grimoire

Progress to Adept 0%
Knowledge Acquired

No spells mastered yet...

Rank Hierarchy

Progress saved locally to your browser.

🕯️ Academy Support

Common Ritual Issues
"Node.js version not found"
Run node -v. If it's below 22.12.0, use NVM to upgrade: nvm install 22 && nvm use 22
"Build fails on Cloudflare"
Ensure you've set the NODE_VERSION environment variable to 22.12.0 in the Cloudflare Dashboard settings.
"Prerequisites not checking"
The checklists are interactive but local to your current lesson view. They help you track your own setup progress manually.

Still blocked by a technical curse?

Ask the Archmage