| name | knowledge-distillation |
| description | Extracts reusable patterns and lessons from execution history and project experience. Generates structured knowledge entries for the knowledge base. |
| tags | ["knowledge","distill","extract","lesson","pattern","experience","postmortem"] |
| stage | evaluation |
| type | delivery-skill |
| category | KNOWLEDGE |
| scope | PLATFORM |
| version | 1.0 |
| author | forge-team |
Knowledge Distillation Skill
Purpose
Analyzes execution history, session summaries, and project artifacts to extract reusable patterns, lessons learned, and knowledge entries. This corresponds to the asset-extractor component in the Forge learning loop architecture.
When to Use
- User says "总结经验" / "提炼 pattern" / "写入知识库"
- After a series of bug fixes to identify recurring patterns
- When a complex task is completed and lessons should be captured
- For postmortem analysis after incidents
Distillation Process
Step 1: Gather Source Material
- Use
get_session_history to retrieve recent session summaries
- Search workspace memory for accumulated facts
- Identify failure→fix chains in execution history
- Read any relevant project docs or changelogs
Step 2: Pattern Recognition
- Recurring Problems: Same type of error appearing multiple times
- Effective Solutions: Patterns that consistently resolve issues
- Convention Gaps: Implicit rules not yet documented
- Tool Usage Patterns: Which tools work best for which tasks
- Architectural Insights: Design decisions and their outcomes
Step 3: Structure the Knowledge
Experience Record Template
## [Title]: [Brief description of the pattern/lesson]
### Context
- When does this apply?
- What conditions trigger this?
### Problem
- What goes wrong without this knowledge?
- What are the symptoms?
### Solution
- Step-by-step resolution
- Code examples if applicable
### Prevention
- How to avoid this in the future
- Suggested Skill/Baseline updates
### Evidence
- Session(s) where this was observed
- Number of occurrences
ADR (Architecture Decision Record) Template
Accepted | Proposed | Deprecated
[What situation prompted this decision?]
[What was decided?]
[Positive and negative impacts]
[What else was evaluated?]