learn
БесплатноЗапускает вложенные скриптыНе проверенDistill learnings from completed features and propose amendments to constitution.md or prompt.md. Use after feature completion. Triggers on: capture…
от ArvorCo★ 100 звёзд на GitHubОб этом скилле
Relentless Learning System
Capture learnings from completed features and propose amendments to improve future runs.
Philosophy: "Loop Ralph" - Create a feedback loop where each feature execution improves the system for future features.
SpecKit Workflow
This skill is optional and runs after feature completion:
specify → plan → tasks → convert → analyze → implement → (optional) learn
Prerequisites:
- Feature must be complete (all stories
passes: trueorskipped: true) progress.txtmust exist with iteration learningsprd.jsonmust exist with execution dataconstitution.mdand/orprompt.mdmust exist inrelentless/
The Job
- Extract learnings from completed feature (using CLI scripts)
- Classify each learning (Constitutional / Tactical / Discard)
- Generate proposals for human approval
- Apply approved amendments to constitution.md or prompt.md
- Save learning log to feature directory
- Update aggregate stats
Step 0: Run Extraction Scripts
IMPORTANT: Use CLI scripts for extraction - do NOT read entire files into context.
Run the extraction scripts from .claude/skills/learn/scripts/:
# Main extraction - runs all extractors
bash .claude/skills/learn/scripts/extract-learnings.sh relentless/features/<feature-name>
# Individual extractors (run by main script):
# - extract-patterns.sh - Patterns from progress.txt
# - extract-costs.sh - Cost accuracy from prd.json
# - extract-failures.sh - Failed checks from checklist.md
# - extract-errors.sh - Error patterns from progress.txt
The output is compact JSON (~500 tokens max):
{
"patterns": ["Pattern 1: description", "Pattern 2: description"],
"costs": {"feature": "name", "estimated": 0.45, "actual": 0.52},
"failures": ["Unchecked item 1", "Unchecked item 2"],
"errors": ["Error context 1", "Error context 2"]
}
If more context is needed for a specific story:
# Extract session context for deeper investigation
bash .claude/skills/learn/scripts/extract-session-context.sh relentless/features/<feature-name> US-XXX
Step 1: Parse Extracted Data
Parse the JSON output from the extraction scripts:
- Patterns: Reusable learnings discovered during implementation
- Costs: Cost accuracy metrics (estimated vs actual)
- Failures: Unchecked checklist items (potential gaps)
- Errors: Error patterns that were fixed (potential rules)
Count and categorize:
- How many patterns were discovered?
- Was cost estimation accurate (>80%)?
- Are there unchecked checklist items (quality gaps)?
- What error patterns emerged?
Step 2: Classify Learnings
For each learning, classify as:
| Type | Target | Criteria | Example |
|---|---|---|---|
| Constitutional | constitution.md | Applies to ALL features, governance/quality/process, prevents significant issues | "Always export new types with implementation" |
| Tactical | prompt.md | Specific to task types or tech stack, workflow tips, common pitfalls | "Mock CLI calls in adapter tests" |
| Discard | None | One-time edge case, already covered, too specific | "Fixed typo in variable name" |
Constitutional criteria (becomes a MUST or SHOULD rule):
- Applies universally to all features
- Related to governance, quality, or process
- Prevents significant issues if violated
- Not already covered in constitution
Tactical criteria (becomes a prompt.md pattern):
- Specific to certain task types or tech stack
- Workflow tip or common pitfall
- Helps agents avoid repeated mistakes
- Not governance-level
Discard criteria (do not propose):
- One-time edge case
- Already covered by existing rules
- Too specific to be reusable
- Subjective preference
Step 3: Generate Proposals
Generate maximum 5 constitutional + 5 tactical proposals per feature.
Constitutional Proposal Format:
### PROP-C01: [Short Title]
**Target:** constitution.md > Principle [N] > [MUST|SHOULD]
**Amendment:**
> [1-2 sentence rule in imperative form]
**Evidence:**
> [Quote from progress.txt showing the issue]
**Classification:** Constitutional - [Rationale why this applies to all features]
Tactical Proposal Format:
### PROP-T01: [Short Title]
**Target:** prompt.md > [Section Name]
**Amendment:**
> [1-2 sentence tip or pattern]
**Evidence:**
> [Quote from progress.txt showing the context]
**Classification:** Tactical - [Rationale why this is task-specific]
Discarded Learnings (include for transparency):
### Discarded Learnings
| Learning | Reason |
|----------|--------|
| Fixed typo in variable name | One-time edge case |
| Used specific API endpoint | Already covered in docs |
Step 4: Present for Human Approval
Use the proposal template from templates/learning-proposal.md to format the output.
The proposal should include:
- Feature Summary: Name, stories, escalations, cost accuracy
Установить learn в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
Без ограничений — скилл может использовать любой инструмент.
Вложенные файлы
FAQ
Что делает скилл learn?
Distill learnings from completed features and propose amendments to constitution.md or prompt.md. Use after feature completion. Triggers on: capture learnings, learn from feature, distill learnings, relentless learn.
Как установить скилл learn?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл learn запускает скрипты?
Да, скилл несёт исполняемые скрипты. Проверь исходник перед установкой.
Похожие скиллы
patterns
Find patterns worth sharing from recent PRs and repo history, both repeats to fix and good practices worth spreading. Use when a champion wants to know what…
от Anthropiccopilot-cli-quickstart
Use this skill when someone wants to learn GitHub Copilot CLI from scratch. Offers interactive step-by-step tutorials with separate Developer and…
от GitHubvardoger-analyze
Use when the user asks to personalize the GitHub Copilot CLI assistant, adapt Copilot to their style, use vardoger, or analyze their Copilot CLI conversation…
от GitHubpolicy-lookup
Find and explain company policies in plain language. Trigger with "what's our PTO policy", "can I work remotely from another country", "how do expenses work"…
от Anthropic