Skip to content
Agent Memory
Skill

/learn

Explore a codebase with parallel Haiku agents — clone, read, and document. Modes — --fast (1 agent), default (3), --deep (5). Use when user says "learn [repo]", "explore codebase", "study this repo", or shares a GitHub URL to study. Do NOT trigger for finding projects (use

BOOST
From plugin
arra-oracle-skills-cli
12532 skills3 hooks
Install
$ npx -y skills add soul-brews-studio/arra-oracle-skills-cli --skill learn --agent claude-code

How it fires

How this skill gets triggered: by you, by Claude, or both.

  • Fires itselfAuto-invocation. Claude auto-loads it when your prompt matches the work.Auto-invocation is when the right skill fires by itself at the right moment, driven by a FLOW.md router and a hook, instead of you invoking it by name. It is the difference between a skill being installed and a skill actually getting used.Read the full definition →
  • You can call itInvoke it directly when you want it.
  • Slash command/learn

Context preview

The summary Claude sees to decide when to auto-load this skill.

Explore a codebase with parallel Haiku agents — clone, read, and document. Modes — --fast (1 agent), default (3), --deep (5). Use when user says "learn [repo]", "explore codebase", "study this repo", or shares a GitHub URL to study. Do NOT trigger for finding projects (use

SKILL.md

learn.SKILL.md
name: learn
description: Explore a codebase with parallel Haiku agents — clone, read, and document. Modes — --fast (1 agent), default (3), --deep (5). Use when user says "learn [repo]", "explore codebase", "study this repo", or shares a GitHub URL to study. Do NOT trigger for finding projects (use /trace), session mining (use /dig), or cloning for active development (use /incubate).
argument-hint: "<repo-url> [--fast | --deep]"

/learn - Deep Dive Learning Pattern

Explore a codebase with 3 parallel Haiku agents → create organized documentation.

Usage

/learn [url]             # Auto: clone via ghq, symlink origin/, then explore
/learn [slug]            # Use slug from ψ/memory/slugs.yaml
/learn [repo-path]       # Path to repo
/learn [repo-name]       # Finds in ψ/learn/owner/repo
/learn --init            # Restore all origins after git clone (like submodule init)

Depth Modes

| Flag | Agents | Files | Use Case | |------|--------|-------|----------| | `--fast` | 1 | 1 overview | Quick scan, "what is this?" | | (default) | 3 | 3 docs | Normal exploration | | `--deep` | 5 | 5 docs | Master complex codebases |

/learn --fast [target]   # Quick overview (1 agent, ~2 min)
/learn [target]          # Standard (3 agents, ~5 min)
/learn --deep [target]   # Deep dive (5 agents, ~10 min)

Directory Structure

ψ/learn/
├── .origins             # Manifest of learned repos (committed)
└── owner/
    └── repo/
        ├── origin       # Symlink to ghq source (gitignored)
        ├── repo.md      # Hub file - links to all sessions (committed)
        └── YYYY-MM-DD/  # Date folder
            ├── 1349_ARCHITECTURE.md      # Time-prefixed files
            ├── 1349_CODE-SNIPPETS.md
            ├── 1349_QUICK-REFERENCE.md
            ├── 1520_ARCHITECTURE.md      # Second run same day
            └── ...

**Multiple learnings**: Each run gets time-prefixed files (HHMM_), nested in date folder.

**Offload source, keep docs:**

unlink ψ/learn/owner/repo/origin   # Remove symlink
ghq rm owner/repo                  # Remove source
# Docs remain in ψ/learn/owner/repo/

/learn --init

Restore all origins after cloning (like `git submodule init`):

ROOT="$(pwd)"
# Read .origins manifest and restore symlinks
while read repo; do
  ghq get -u "https://github.com/$repo"
  OWNER=$(dirname "$repo")
  REPO=$(basename "$repo")
  mkdir -p "$ROOT/ψ/learn/$OWNER/$REPO"
  ln -sf "$(ghq root)/github.com/$repo" "$ROOT/ψ/learn/$OWNER/$REPO/origin"
  echo "✓ Restored: $repo"
done < "$ROOT/ψ/learn/.origins"

Step 0: Detect Input Type + Resolve Path

**CRITICAL: Capture ABSOLUTE paths first (before spawning any agents):**

date "+🕐 %H:%M %Z (%A %d %B %Y)" && ROOT="$(pwd)"
echo "Learning from: $ROOT"

**IMPORTANT FOR SUBAGENTS:** When spawning Haiku agents, you MUST give them TWO literal paths: 1. **SOURCE_DIR** (where to READ code) — the **`readlink`-RESOLVED ghq path**. **Never the `origin/` symlink path.** See ⚠️ below — this is not cosmetic. 2. **DOCS_DIR** (where to WRITE docs) - the parent directory, NOT inside origin/

⚠️ **BUG 1 (writes)**: If you only give agents `origin/` path, they cd into it and write there → files end up in WRONG repo!

⚠️ **BUG 2 (reads — worse, and silent)**: The `origin/` path is *nested inside this oracle repo* (`ROOT/ψ/learn/...`). An agent handed that path reads the target as a subdirectory of us and describes it as a variant of our repo. Measured on `mattpocock/skills` (2026-08-16): the arm given the nested path produced 3 contaminated docs / 26 false claims; the arm given the resolved ghq path produced **zero**. Same target, same minute, same model. Resolve it:

SOURCE_DIR="$(readlink "$ROOT/ψ/learn/$OWNER/$REPO/origin")"   # → ghq path

**FIX**: Always give BOTH paths as LITERAL absolute values (no variables!):

Example: ROOT=/home/user/ghq/.../my-oracle, learning acme-corp/cool-library, TODAY=2026-02-04, TIME=1349:

READ from:  /home/user/ghq/github.com/acme-corp/cool-library/     ← resolved, NOT under ψ/
WRITE to:   .../ψ/learn/acme-corp/cool-library/2026-02-04/1349_[FILENAME].md

Tell each agent: "Read from [SOURCE_DIR]. Write to [DOCS_DIR]/[TIME]_[FILENAME].md"

⚠️ MANDATORY: Isolation preamble (prepend to EVERY agent prompt)

Agents spawned here inherit **this oracle repo's** `CLAUDE.md` as project instructions. They will silently describe the *target* repo using *our* vocabulary. Measured on `mattpocock/skills` (2026-08-16): 3 of 5 docs contaminated, 26 false structural claims — including a doc that wrote *"(not in mattpocock/skills; reference from oracle-skills-cli CLAUDE.md)"* and then asserted the claim anyway. **Detection is not containment.** The agent noticing the mismatch does not stop it shipping.

Prepend this verbatim to every agent prompt:

ISOLATION RULE — read before anything else.
You are running inside an unrelated repo whose CLAUDE.md is in your context.
Its conventions describe YOUR HOST, not the target you are analyzing.
Document ONLY what you can cite from a file under SOURCE_DIR.
Before writing any structural claim (build tooling, versioning scheme,
directory layout, curation/lifecycle model, CI gates), verify it with a
concrete check — `ls`, reading package.json, reading the config file.
If you cannot cite it, write "not present" — never substitute a mechanism
you know from elsewhere, and never describe the target as a variant of
another repo.

**Do not soften this to "be careful."** The failure mode is confident and fluent; only a citation requirement catches it.

⚠️ Absent-referent rule (the biggest single cause)

A mandated section with no material in the target is what actually produces contamination. `TESTING.md` was demanded for a repo with **zero tests**; the agent correctly wrote "no test infrastructure" — then filled the rest of the page with our CalVer, our `bun run compile`, our "public shelf". The two docs whose topics were fully s

Read more
Ships witharra-oracle-skills-cli

25 skills for AI coding agents — persistent memory, session awareness, and collaborative tools.

Get the whole plugin
Stats
125
Stars
58
Forks
Active
Maintenance
TypeScript
Language
MIT
License
22d ago
Last commit
9mo ago
Created
3h ago
Added

Repo: soul-brews-studio/arra-oracle-skills-cli

Other skills on arra-oracle-skills-cli.