pattern-learning
БесплатноБез исполняемых скриптовНе проверенEnables autonomous pattern recognition, storage, and retrieval at project level with self-learning capabilities for continuous improvement
Об этом скилле
Overview
This skill provides the framework for autonomous pattern learning and recognition at the project level. It enables Claude agents to:
- Automatically detect and store successful task execution patterns
- Build a knowledge base of project-specific approaches
- Recommend skills and strategies based on historical success
- Continuously improve through self-assessment and adaptation
Pattern Recognition System
Automatic Pattern Detection
Task Categorization: Automatically classify tasks into categories:
refactoring: Code restructuring and improvementbug-fix: Error resolution and debuggingfeature: New functionality implementationoptimization: Performance improvementsdocumentation: Docs creation and updatestesting: Test suite developmentsecurity: Security analysis and fixes
Context Extraction: Automatically extract context from:
- Programming languages used (file extensions)
- Frameworks detected (package.json, requirements.txt, etc.)
- Project structure patterns (MVC, microservices, etc.)
- Complexity indicators (file count, LOC, dependencies)
Pattern Storage Structure
Directory Setup:
.claude-patterns/
├── patterns.json # Main pattern database
├── skill-effectiveness.json # Skill performance metrics
└── task-history.json # Complete task execution log
Pattern Data Model:
{
"version": "1.0.0",
"project_context": {
"detected_languages": ["python", "javascript"],
"frameworks": ["flask", "react"],
"project_type": "web-application"
},
"patterns": [
{
"id": "pattern-001",
"timestamp": "2025-10-20T10:30:00Z",
"task_type": "refactoring",
"task_description": "Refactor authentication module",
"context": {
"language": "python",
"framework": "flask",
"module": "authentication",
"complexity": "medium"
},
"execution": {
"skills_used": ["code-analysis", "quality-standards"],
"agents_delegated": ["code-analyzer", "quality-controller"],
"approach": "Extract method refactoring with pattern matching",
"duration_seconds": 120
},
"outcome": {
"success": true,
"quality_score": 96,
"tests_passing": true,
"standards_compliance": 98,
"documentation_complete": true
},
"lessons_learned": "Security-critical modules benefit from quality-controller validation",
"reuse_count": 5
}
],
"skill_effectiveness": {
"code-analysis": {
"total_uses": 45,
"successful_uses": 42,
"success_rate": 0.93,
"avg_quality_contribution": 15,
"recommended_for": ["refactoring", "bug-fix", "optimization"]
},
"testing-strategies": {
"total_uses": 30,
"successful_uses": 27,
"success_rate": 0.90,
"avg_quality_contribution": 20,
"recommended_for": ["testing", "feature", "bug-fix"]
}
},
"agent_effectiveness": {
"code-analyzer": {
"total_delegations": 38,
"successful_completions": 36,
"success_rate": 0.95,
"avg_execution_time": 85
}
}
}
Skill Auto-Selection Algorithm
Decision Process
Step 1: Analyze Current Task
Input: Task description
Output: Task type, context, complexity
Process:
1. Extract keywords and intent
2. Scan project files for context
3. Classify task type
4. Determine complexity level (low/medium/high)
Step 2: Query Pattern Database
Input: Task type, context
Output: Recommended skills, agents, approach
Process:
1. Load patterns.json
2. Filter patterns by task_type match
3. Filter patterns by context similarity
4. Rank by success_rate * reuse_count
5. Extract top 3 most successful patterns
Step 3: Skill Selection
Input: Top patterns, skill effectiveness data
Output: Ordered list of skills to load
Process:
1. Aggregate skills from top patterns
2. Weight by skill effectiveness scores
3. Filter by task type recommendation
4. Return ordered list (highest effectiveness first)
Selection Examples
Example 1: Refactoring Task
Task: "Refactor user authentication module"
Analysis:
- Type: refactoring
- Context: authentication (security-critical)
- Language: Python (detected)
- Complexity: medium
Pattern Query Results:
- Pattern-001: refactoring + auth → success_rate: 0.96
- Pattern-015: refactoring + security → success_rate: 0.94
- Pattern-023: refactoring + Python → success_rate: 0.91
Skill Selection:
1. code-analysis (appeared in all 3 patterns, avg effectiveness: 0.93)
2. quality-standards (appeared in 2/3 patterns, avg effectiveness: 0.88)
3. pattern-learning (for continuous improvement)
Auto-Load: code-analysis, quality-standards, pattern-learning
Example 2: Testing Task
Task: "Add unit tests for payment processing"
Analysis:
- Type: testing
- Context: payment (critical business logic)
- Language: JavaScript (detected)
- Complexity: hig
Установить pattern-learning в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
Без ограничений — скилл может использовать любой инструмент.
FAQ
Что делает скилл pattern-learning?
Enables autonomous pattern recognition, storage, and retrieval at project level with self-learning capabilities for continuous improvement
Как установить скилл pattern-learning?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл pattern-learning запускает скрипты?
Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.
Похожие скиллы
theme-factory
Toolkit for styling artifacts with a theme. These artifacts can be slides, docs, reportings, HTML landing pages, etc. There are 10 pre-set themes with…
от Anthropicaccess
Manage Discord channel access — approve pairings, edit allowlists, set DM/group policy. Use when the user asks to pair, approve someone, check who's allowed…
от Anthropicconfigure
Set up the Discord channel — save the bot token and review access policy. Use when the user pastes a Discord bot token, asks to configure Discord, asks "how…
от Anthropicaccess
Manage iMessage channel access — approve pairings, edit allowlists, set DM/group policy. Use when the user asks to pair, approve someone, check who's allowed…
от Anthropic