Back to Skills

learn

pjt222
Updated 2 days ago
7 views
17
2
17
View on GitHub
Metaaidesign

About

The 'learn' skill enables Claude to systematically acquire knowledge from unfamiliar domains by building structured mental models through iterative exploration and verification. It's designed for situations requiring deep investigation rather than simple recall, such as understanding new codebases, resolving conflicting information, or preparing to teach complex topics. The skill implements a deliberate learning cycle—surveying, hypothesizing, probing, and consolidating—to create durable understanding for future retrieval.

Quick Install

Claude Code

Recommended
Primary
npx skills add pjt222/agent-almanac -a claude-code
Plugin CommandAlternative
/plugin add https://github.com/pjt222/agent-almanac
Git CloneAlternative
git clone https://github.com/pjt222/agent-almanac.git ~/.claude/skills/learn

Copy and paste this command in Claude Code to install this skill

Documentation

Learn

Conduct a structured knowledge acquisition session — surveying unfamiliar territory, building initial models, testing them through deliberate exploration, integrating findings into coherent understanding, and consolidating for durable retrieval.

When to Use

  • Encountering an unfamiliar codebase, framework, or domain with no prior context
  • A user asks about a topic outside current working knowledge and the answer requires genuine investigation, not recall
  • Multiple conflicting sources or patterns exist and a coherent mental model needs to be built from scratch
  • After remote-viewing surfaces intuitive leads that need systematic validation
  • Preparing to teach a topic — the AI must first understand it deeply enough to explain it

Inputs

  • Required: Learning target — a topic, codebase area, API, domain concept, or technology to understand
  • Optional: Scope boundary — how deep to go (surface survey vs. deep expertise)
  • Optional: User's purpose — why this knowledge matters (guides which aspects to prioritize)
  • Optional: Known starting points — files, docs, or concepts already familiar

Procedure

Step 1: Survey — Map the Territory

Before attempting to understand anything, map the landscape to identify what exists.

Learning Modality Selection:
┌──────────────────┬──────────────────────────┬──────────────────────────┐
│ Territory Type   │ Primary Modality         │ Tool Pattern             │
├──────────────────┼──────────────────────────┼──────────────────────────┤
│ Codebase         │ Structural mapping —     │ Glob for file tree,      │
│                  │ find entry points, core  │ Grep for exports/imports,│
│                  │ modules, boundaries      │ Read for key files       │
├──────────────────┼──────────────────────────┼──────────────────────────┤
│ API / Library    │ Interface mapping —      │ WebFetch for docs,       │
│                  │ find public surface,     │ Read for examples,       │
│                  │ types, configuration     │ Grep for usage patterns  │
├──────────────────┼──────────────────────────┼──────────────────────────┤
│ Domain concept   │ Ontology mapping —       │ WebSearch for overviews,  │
│                  │ find core terms,         │ WebFetch for definitions,│
│                  │ relationships, debates   │ Read for local notes     │
├──────────────────┼──────────────────────────┼──────────────────────────┤
│ User's context   │ Conversational mapping   │ Read conversation,       │
│                  │ — find stated goals,     │ Read MEMORY.md,          │
│                  │ preferences, constraints │ Read CLAUDE.md           │
└──────────────────┴──────────────────────────┴──────────────────────────┘
  1. Identify the territory type and select the primary modality
  2. Perform a broad scan — not reading deeply, but identifying landmarks (key files, entry points, core concepts)
  3. Note the boundaries: what is in scope, what is adjacent, what is out of scope
  4. Identify gaps: areas that look important but are opaque from the surface
  5. Create a rough map: list the major components and their apparent relationships

Got: A skeletal map of the territory with 5-15 landmarks identified. A sense of which areas are clear from the surface and which require deeper investigation. No understanding yet — a map.

If fail: If the territory is too large to survey, narrow scope immediately. Ask: "What is the minimum I need to understand to serve the user's purpose?" If the territory has no clear entry point, start from the output (what does this system produce?) and trace backward.

Step 2: Hypothesize — Build Initial Models

From the survey, construct initial hypotheses about how the system works.

  1. Formulate 2-3 hypotheses about the territory's structure or behavior
  2. State each hypothesis clearly: "I believe X because I observed Y"
  3. For each hypothesis, identify what evidence would confirm it and what would refute it
  4. Rank hypotheses by confidence: which feels most supported, which is shakiest
  5. Identify the highest-value hypothesis to test first (the one that, if confirmed, would unlock the most understanding)

Got: Concrete, falsifiable hypotheses — not vague impressions. Each has a test that would confirm or refute it. The hypotheses collectively cover the most important aspects of the territory.

If fail: If no hypotheses form, the survey was too shallow — return to Step 1 and read 2-3 landmarks in depth. If all hypotheses feel equally uncertain, start with the simplest one (Occam's razor) and build from there.

Step 3: Explore — Probe and Test

Systematically test each hypothesis through targeted investigation.

  1. Select the highest-priority hypothesis
  2. Design a minimal probe: what is the smallest investigation that would confirm or refute it?
  3. Execute the probe (read a file, search for a pattern, test an assumption)
  4. Record the result: confirmed, refuted, or modified
  5. If refuted, update the hypothesis based on the new evidence
  6. If confirmed, probe deeper: does the hypothesis hold at the edges, or only in the center?
  7. Move to the next hypothesis and repeat

Got: At least one hypothesis tested to conclusion. The mental model is beginning to take shape — some parts confirmed, some revised. Surprises are noted as valuable data.

If fail: If probes consistently produce ambiguous results, the hypotheses may be testing the wrong things. Step back and ask: "What would someone who understands this system consider the most important fact?" Probe for that instead.

Step 4: Integrate — Build Mental Model

Synthesize findings into a coherent model that connects the pieces.

  1. Review all confirmed hypotheses and revised models
  2. Identify the central organizing principle: what is the "spine" that everything connects to?
  3. Map relationships: which components depend on which? What flows where?
  4. Identify the surprising findings — these often contain the deepest insight
  5. Look for patterns that repeat across different parts of the territory
  6. Build a mental model that can predict behavior: "Given input X, I expect Y because Z"

Got: A coherent mental model that explains the territory's structure and predicts its behavior. The model should be expressible in 3-5 sentences and should make specific claims, not vague generalizations.

If fail: If the pieces do not integrate into a coherent model, there may be a fundamental misunderstanding in one of the earlier hypotheses. Identify the piece that does not fit and re-test it. Alternatively, the territory may be incoherent (poorly designed systems exist) — note this as a finding rather than forcing coherence.

Step 5: Verify — Challenge Understanding

Test the mental model by making predictions and checking them.

  1. Use the model to make 3 specific predictions about the territory
  2. Test each prediction through investigation (not by assuming it is true)
  3. For each confirmed prediction, confidence increases
  4. For each refuted prediction, identify where the model is wrong and correct it
  5. Identify edge cases: does the model hold at the boundaries, or does it break down?
  6. Ask: "What would surprise me?" — then check if that surprise is possible

Got: The mental model survives at least 2 of 3 prediction tests. Where it breaks, the failure is understood and the model is corrected. The model now has both confirmed strengths and known limitations.

If fail: If most predictions fail, the mental model has a fundamental flaw. This is valuable information — it means the territory works differently than expected. Return to Step 2 with the new evidence and rebuild the hypotheses from scratch. The second attempt will be much faster because the wrong models have been eliminated.

Step 6: Consolidate — Store for Retrieval

Capture the learning in a form that supports future retrieval and application.

  1. Summarize the mental model in 3-5 sentences
  2. Note the key landmarks — the 3-5 most important things to remember
  3. Record any counterintuitive findings that might be forgotten
  4. Identify related topics that this learning connects to
  5. If the learning is durable (will be needed across sessions), update MEMORY.md
  6. If the learning is session-specific, note it as context for the current conversation
  7. State what remains unknown — honest gaps are more useful than false confidence

Got: A concise, retrievable summary that captures the essential understanding. Future references to this topic can start from this summary rather than re-learning from scratch.

If fail: If the learning resists summarization, it may not yet be fully integrated — return to Step 4. If the learning seems too obvious to be worth storing, consider that what feels obvious now may not feel obvious in a fresh context. Store the non-obvious parts.

Validation

  • A survey was conducted before any deep investigation (map before dive)
  • Hypotheses were explicitly stated and tested, not assumed
  • At least one hypothesis was revised based on evidence (indicates genuine learning)
  • The mental model makes specific, testable predictions about the territory
  • Known unknowns are identified alongside known knowns
  • The consolidated summary is concise enough to be useful for future retrieval

Pitfalls

  • Skipping the survey: Diving into detail before understanding the landscape wastes time on unimportant areas and misses the big picture
  • Unfalsifiable hypotheses: "This is probably complex" cannot be tested. "This module handles authentication because it imports crypto" can be
  • Confirmation bias during exploration: Seeking only evidence that supports the initial hypothesis while ignoring contradictions
  • Premature consolidation: Storing a model before it has been tested leads to confidently wrong future predictions
  • Perfectionism: Attempting to learn everything before applying any knowledge. Learning is iterative — use partial understanding, then refine
  • Learning without purpose: Acquiring knowledge with no application in mind produces unfocused, shallow understanding

Related Skills

  • learn-guidance — the human-guidance variant for coaching a person through structured learning
  • teach — knowledge transfer calibrated to a learner; builds on the model constructed here
  • remote-viewing — intuitive exploration that surfaces leads for systematic learning to validate
  • meditate — clearing prior context noise before entering a new learning territory
  • observe — sustained neutral pattern recognition that feeds learning with raw data

GitHub Repository

pjt222/agent-almanac
Path: i18n/caveman-lite/skills/learn
0
agentsagentskillsai-assisted-developmentclaude-codeskillsteams

Related Skills

content-collections

Meta

This skill provides a production-tested setup for Content Collections, a TypeScript-first tool that transforms Markdown/MDX files into type-safe data collections with Zod validation. Use it when building blogs, documentation sites, or content-heavy Vite + React applications to ensure type safety and automatic content validation. It covers everything from Vite plugin configuration and MDX compilation to deployment optimization and schema validation.

View skill

polymarket

Meta

This skill enables developers to build applications with the Polymarket prediction markets platform, including API integration for trading and market data. It also provides real-time data streaming via WebSocket to monitor live trades and market activity. Use it for implementing trading strategies or creating tools that process live market updates.

View skill

creating-opencode-plugins

Meta

This skill helps developers create OpenCode plugins that hook into 25+ event types like commands, files, and LSP operations. It provides the plugin structure, event API specifications, and implementation patterns for JavaScript/TypeScript modules. Use it when you need to intercept, monitor, or extend the OpenCode AI assistant's lifecycle with custom event-driven logic.

View skill

sglang

Meta

SGLang is a high-performance LLM serving framework that specializes in fast, structured generation for JSON, regex, and agentic workflows using its RadixAttention prefix caching. It delivers significantly faster inference, especially for tasks with repeated prefixes, making it ideal for complex, structured outputs and multi-turn conversations. Choose SGLang over alternatives like vLLM when you need constrained decoding or are building applications with extensive prefix sharing.

View skill