Initial commit

This commit is contained in:
Zhongwei Li
2025-11-29 18:16:56 +08:00
commit 8a3d331e04
61 changed files with 11808 additions and 0 deletions

View File

@@ -0,0 +1,211 @@
# Template: Insight-Based Skill (SKILL.md)
This template shows the recommended structure for skills generated from insights.
Use this as a reference pattern when creating SKILL.md files.
---
name: {{ skill_name }}
description: {{ description }}
---
# {{ skill_title }}
## Overview
{{ overview_text }}
**Based on {{ insight_count }} insight(s)**:
{% for insight in insights %}
- {{ insight.title }} ({{ insight.category }}, {{ insight.date }})
{% endfor %}
**Key Capabilities**:
{% for capability in capabilities %}
- {{ capability }}
{% endfor %}
## When to Use This Skill
**Trigger Phrases**:
{% for trigger in trigger_phrases %}
- "{{ trigger }}"
{% endfor %}
**Use Cases**:
{% for use_case in use_cases %}
- {{ use_case }}
{% endfor %}
**Do NOT use when**:
{% for anti_use_case in anti_use_cases %}
- {{ anti_use_case }}
{% endfor %}
## Response Style
{{ response_style }}
---
{% if pattern == 'phase-based' %}
## Workflow
{% for phase in phases %}
### Phase {{ loop.index }}: {{ phase.name }}
**Purpose**: {{ phase.purpose }}
**Steps**:
{% for step in phase.steps %}
{{ loop.index }}. {{ step }}
{% endfor %}
**Output**: {{ phase.output }}
{% if phase.common_issues %}
**Common Issues**:
{% for issue in phase.common_issues %}
- {{ issue }}
{% endfor %}
{% endif %}
{% endfor %}
{% elif pattern == 'mode-based' %}
## Mode Selection
This skill operates in {{ modes|length }} distinct modes. Choose based on your needs:
{% for mode in modes %}
### Mode {{ loop.index }}: {{ mode.name }}
**When to use**: {{ mode.when_to_use }}
**Steps**:
{% for step in mode.steps %}
{{ loop.index }}. {{ step }}
{% endfor %}
**Output**: {{ mode.output }}
{% endfor %}
{% elif pattern == 'validation' %}
## Validation Workflow
### Analysis Phase
**Steps**:
{% for step in analysis_steps %}
{{ loop.index }}. {{ step }}
{% endfor %}
### Issue Detection
**Checks performed**:
{% for check in checks %}
- {{ check }}
{% endfor %}
### Recommendations
**Output format**:
- Issue severity (Critical/High/Medium/Low)
- Issue description
- Recommended fix
- Code examples (if applicable)
{% endif %}
---
## Reference Materials
{% if has_data_dir %}
Detailed reference information is available in:
- [Insights Reference](data/insights-reference.md) - Original insights that informed this skill
{% if has_additional_data %}
{% for data_file in data_files %}
- [{{ data_file.title }}](data/{{ data_file.filename }}) - {{ data_file.description }}
{% endfor %}
{% endif %}
{% endif %}
{% if has_examples %}
**Examples**:
{% for example in examples %}
- [{{ example.title }}](examples/{{ example.filename }}) - {{ example.description }}
{% endfor %}
{% endif %}
{% if has_templates %}
**Templates**:
{% for template in templates %}
- [{{ template.title }}](templates/{{ template.filename }}) - {{ template.description }}
{% endfor %}
{% endif %}
---
## Important Reminders
{% for reminder in important_reminders %}
- {{ reminder }}
{% endfor %}
{% if warnings %}
**Warnings**:
{% for warning in warnings %}
- ⚠️ {{ warning }}
{% endfor %}
{% endif %}
---
## Best Practices
{% for practice in best_practices %}
{{ loop.index }}. **{{ practice.title }}**: {{ practice.description }}
{% endfor %}
---
## Troubleshooting
{% for issue in troubleshooting %}
### {{ issue.problem }}
**Symptoms**: {{ issue.symptoms }}
**Solution**: {{ issue.solution }}
{% if issue.prevention %}
**Prevention**: {{ issue.prevention }}
{% endif %}
{% endfor %}
---
## Next Steps
After using this skill:
{% for next_step in next_steps %}
{{ loop.index }}. {{ next_step }}
{% endfor %}
---
## Metadata
**Source Insights**:
{% for insight in insights %}
- Session: {{ insight.session_id }}
- Date: {{ insight.date }}
- Category: {{ insight.category }}
- File: {{ insight.source_file }}
{% endfor %}
**Skill Version**: {{ version }}
**Generated**: {{ generated_date }}
**Last Updated**: {{ updated_date }}

View File

@@ -0,0 +1,71 @@
# Template: Actionable Checklist (templates/checklist.md)
This template creates actionable checklists from insight action items.
# {{ skill_title }} - Checklist
This checklist extracts actionable items from the insights that inform this skill.
## Overview
Use this checklist to ensure you've applied all recommendations from the **{{ skill_title }}** skill.
**Total Items**: {{ total_items }}
**Estimated Time**: {{ estimated_time }}
---
{% for section in sections %}
## {{ section.name }}
{{ section.description }}
{% for item in section.items %}
- [ ] {{ item.description }}
{% if item.details %}
- Details: {{ item.details }}
{% endif %}
{% if item.why %}
- Why: {{ item.why }}
{% endif %}
{% if item.how %}
- How: {{ item.how }}
{% endif %}
{% if item.validation %}
- Validation: {{ item.validation }}
{% endif %}
{% endfor %}
{% if section.notes %}
**Notes**:
{% for note in section.notes %}
- {{ note }}
{% endfor %}
{% endif %}
---
{% endfor %}
## Verification
After completing this checklist:
{% for verification in verifications %}
- [ ] {{ verification }}
{% endfor %}
## Common Mistakes
{% for mistake in common_mistakes %}
{{ loop.index }}. **{{ mistake.what }}**
- How to avoid: {{ mistake.how_to_avoid }}
{% if mistake.fix %}
- If you made this mistake: {{ mistake.fix }}
{% endif %}
{% endfor %}
---
**Source**: Generated from {{ insight_count }} insight(s)
**Last Updated**: {{ updated_date }}

View File

@@ -0,0 +1,96 @@
# Template: Insights Reference (data/insights-reference.md)
This template consolidates the original insights that informed a generated skill.
# Insights Reference: {{ skill_name }}
This document contains the original insights from Claude Code's Explanatory output style that were used to create the **{{ skill_title }}** skill.
## Overview
**Total Insights**: {{ insight_count }}
**Date Range**: {{ earliest_date }} to {{ latest_date }}
**Categories**: {{ categories|join(', ') }}
**Sessions**: {{ session_count }} unique session(s)
---
{% for insight in insights %}
## {{ loop.index }}. {{ insight.title }}
**Metadata**:
- **Date**: {{ insight.date }}
- **Category**: {{ insight.category }}
- **Session**: {{ insight.session_id }}
- **Source File**: {{ insight.source_file }}
**Original Content**:
{{ insight.content }}
{% if insight.code_examples %}
**Code Examples from this Insight**:
{% for example in insight.code_examples %}
```{{ example.language }}
{{ example.code }}
```
{% endfor %}
{% endif %}
{% if insight.related_insights %}
**Related Insights**: {{ insight.related_insights|join(', ') }}
{% endif %}
---
{% endfor %}
## Insight Clustering Analysis
**Similarity Scores**:
{% for cluster in clusters %}
- Cluster {{ loop.index }}: {{ cluster.insights|join(', ') }} (score: {{ cluster.score }})
{% endfor %}
**Common Keywords**:
{% for keyword in common_keywords %}
- {{ keyword.word }} (frequency: {{ keyword.count }})
{% endfor %}
**Category Distribution**:
{% for category, count in category_distribution.items() %}
- {{ category }}: {{ count }} insight(s)
{% endfor %}
---
## How These Insights Inform the Skill
{% for mapping in insight_mappings %}
### {{ mapping.insight_title }} → {{ mapping.skill_section }}
{{ mapping.explanation }}
{% endfor %}
---
## Additional Context
**Why These Insights Were Selected**:
{{ selection_rationale }}
**Insights Not Included** (if any):
{% if excluded_insights %}
{% for excluded in excluded_insights %}
- {{ excluded.title }}: {{ excluded.reason }}
{% endfor %}
{% else %}
All relevant insights were included.
{% endif %}
---
**Generated**: {{ generated_date }}
**Last Updated**: {{ updated_date }}