
Rules Distill
Scans your installed Claude skills to find principles that show up in multiple places, then promotes them into your rules files. The workflow is deterministic collection (bash scripts inventory skills and rules) followed by LLM judgment (batched analysis with full context, no grep filtering). It won't auto-edit anything. Instead, it presents candidates with verdicts like "append to security.md" or "revise testing.md" and waits for you to approve, modify, or skip. Run this monthly or after a skill stocktake when you notice repeated patterns that should graduate from individual skills into system-wide rules. The cross-batch merge step is clever: it rechecks the "appears in 2+ skills" requirement across all batches combined, not just within each cluster.
- skills.sh installs
- 5.4K
- GitHub stars
- 300.3K
- last updated
- Aug 21, 2026
Install
$ npx -y skills add affaan-m/ecc --skill rules-distill --agent claude-codeInstalls into .claude/skills of the current project.
Files
Rules Distill
Scan installed skills, extract cross-cutting principles that appear in multiple skills, and distill them into rules — appending to existing rule files, revising outdated content, or creating new rule files.
Applies the "deterministic collection + LLM judgment" principle: scripts collect facts exhaustively, then an LLM cross-reads the full context and produces verdicts.
When to Use
- Periodic rules maintenance (monthly or after installing new skills)
- After a skill-stocktake reveals patterns that should be rules
- When rules feel incomplete relative to the skills being used
How It Works
The rules distillation process follows three phases:
Phase 1: Inventory (Deterministic Collection)
1a. Collect skill inventory
bash ~/.claude/skills/rules-distill/scripts/scan-skills.sh
1b. Collect rules index
bash ~/.claude/skills/rules-distill/scripts/scan-rules.sh
1c. Present to user
Rules Distillation — Phase 1: Inventory
────────────────────────────────────────
Skills: {N} files scanned
Rules: {M} files ({K} headings indexed)
Proceeding to cross-read analysis...
Sponsors
Details
- Repository
- github.com/affaan-m/ecc
- First seen
- Jul 14, 2026
More from affaan-m/ecc
All 263- Content Hash Cache Pattern5.4K
- Network Config Validation5.4K
- Dmux Workflows5.4K
- Quarkus Patterns5.4K
- Ecc Tools Cost Audit5.4K
- Foundation Models On Device5.4K
- Network Interface Health5.4K
- Netmiko Ssh Automation5.4K
- Swift Concurrency 6 25.4K
- Opensource Pipeline5.4K
- Plankton Code Quality5.4K
- Defi Amm Security5.4K
- Gan Style Harness5.4K
- Homelab Pihole Dns5.4K
- Returns Reverse Logistics5.4K
- Benchmark Optimization Loop5.4K
- Customer Billing Ops5.4K
- Openclaw Persona Forge5.4K
- Google Workspace Ops5.4K
- Hookify Rules5.4K
- Connections Optimizer5.4K
- Swift Protocol Di Testing5.4K
- Energy Procurement5.4K
- Swift Actor Persistence5.4K