plugins/cc-meta/skills/mining-session-patterns/SKILL.md
--- name: mining-session-patterns description: Extract actionable patterns from Claude Code session JSONL files. Surfaces error→fix sequences, tool failure rates, and cost-per-story signals for compound learning. compatibility: Designed for Claude Code metadata: allowed-tools: Read, Glob, Grep, Write argument-hint: [time-range] [output-path] context: fork stability: development --- # Session Pattern Mining **Target**: $ARGUMENTS Mines Claude Code session transcripts for recurring patt
npx skillsauth add qte77/claude-code-plugins plugins/cc-meta/skills/mining-session-patternsInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
Target: $ARGUMENTS
Mines Claude Code session transcripts for recurring patterns that feed compound learning. Converts raw session data into actionable improvements.
| Position | Name | Required | Default | Description |
|----------|------|----------|---------|-------------|
| 1 | time-range | no | 7d | Period to scan. E.g. 7d, 30d, this-week. |
| 2 | output-path | no | docs/patterns/session-patterns.md | Where to write findings. |
Examples:
/mining-session-patterns # Last 7 days, default output
/mining-session-patterns 30d # Last 30 days
/mining-session-patterns 7d ./patterns.md # Custom output path
~/.claude/projects/*/*.jsonl # Session transcripts
Critical: Never bulk-read full .jsonl files. Use sampling strategy below
to respect context budget.
Discover session files — Glob ~/.claude/projects/*/*.jsonl. Filter by
mtime within time-range. Select up to 10 files, preferring recent.
Sample each file — Read first 20 lines + last 20 lines per file. This captures session setup (tools, config) and final outcomes (errors, completions). Skip files smaller than 5 lines.
Extract patterns from sampled lines:
type: "tool_error" or
error messages in tool results, then the next tool call on the same target.Format findings — Structure as tables per Output Format below. Every row must suggest a concrete improvement or be omitted.
Write output — Write to output-path. Create parent directories
if needed.
# Session Patterns — <start-date> to <end-date>
## Error-Fix Sequences
| Error Pattern | Recovery Strategy | Frequency | Candidate Learning |
|---------------|-------------------|-----------|-------------------|
| <tool>: <error summary> | <what worked> | N occurrences | <rule or skill suggestion> |
## Tool Failure Rates
| Tool | Calls | Failures | Rate | Common Cause |
|------|-------|----------|------|--------------|
| Bash | N | N | N% | <top failure reason> |
## Cost Signals
| Session | Messages | Est. Tokens | Task Complexity |
|---------|----------|-------------|-----------------|
| <uuid-short> | N | ~Nk | small/medium/large |
## Recommended Actions
- <Concrete improvement derived from patterns above>
documentation
Generate or update README.md files across three scopes — repo (with project-type detection), account (GitHub user profile), and org (organization profile). Use when creating, updating, or aligning a README to org conventions.
development
Audit README.md files against best practices for repos, accounts, or orgs. Detects missing sections, stale links, inconsistent formatting, and convention violations. Use when reviewing README quality across one or many repos.
development
Analyzes industry websites for design patterns, layout, typography, and content strategies using first-principles thinking. Use when researching website design, UI patterns, or competitive design analysis.
development
Audits website usability for UX optimization, covering forms, navigation, validation, and microcopy. Use when reviewing user experience, task completion flows, or interface friction points.