# pattern-detection > Detects repeated patterns in the user's work. Use when starting a session, after completing tasks, or when the user seems to be doing something repetitive. - Author: Tim - Repository: timwin23/VOX_DEI - Version: 20260208114142 - Stars: 0 - Forks: 0 - Last Updated: 2026-02-08 - Source: https://github.com/timwin23/VOX_DEI - Web: https://mule.run/skillshub/@@timwin23/VOX_DEI~pattern-detection:20260208114142 --- --- name: pattern-detection description: Detects repeated patterns in the user's work. Use when starting a session, after completing tasks, or when the user seems to be doing something repetitive. --- # Pattern Detection (Culex Lens) You notice patterns. Not just repetitions—deeper signals. ## The Formula **Ψ(Ω(F ⊗ Y)^φ)** | Symbol | Meaning | What To Detect | |--------|---------|----------------| | Ψ | Narrative coherence | Same STORY across contexts | | Ω | Emergence / collapse | Many → one transitions | | F ⊗ Y | Force ⊗ Yield tension | Paired oppositions that persist | | φ | Execution rhythm | Daily, weekly, phase-based cycles | **"Story shapes what emerges from the tension, recursed through execution."** ## The Deeper Lens When evaluating activity, don't just count repeated commands. Instead: 1. **Ψ (Narrative)** — Same structure/story across different contexts 2. **Ω (Emergence)** — Where many approaches collapse into one outcome 3. **F ⊗ Y (Tension)** — Paired oppositions that both persist, carrying signal 4. **φ (Rhythm)** — Cyclic behaviors (daily, weekly, phase-based) Upscore patterns that match these deeper categories. ## When To Activate - At the start of any session (check what's been happening) - After completing a task (did this look familiar?) - When you notice repetition mid-conversation - After agent loops complete (PostToolUse, SubagentStop) ## How To Detect ```bash # Check stored patterns cat .claude/culex/patterns.json 2>/dev/null # Look at git history for repeated commit patterns git log --format="%s" -30 2>/dev/null | sort | uniq -c | sort -rn | head -5 # Check which files get touched repeatedly git log --name-only --format="" -30 2>/dev/null | sort | uniq -c | sort -rn | head -5 ``` ## What Counts As A Pattern | Signal | Threshold | Formula Component | Suggest | |--------|-----------|-------------------|---------| | Same story/structure across contexts | 2+ times | Ψ (Narrative) | Skill | | Many approaches → one outcome | N/A | Ω (Collapse) | Training capture | | Opposing patterns that both persist | N/A | F ⊗ Y (Tension) | Skill (holds both) | | Cyclic behavior | 3+ times | φ (Rhythm) | Hook | | Same commit message structure | 3+ times | φ (Rhythm) | Hook | | Same file modified repeatedly | 5+ times | Ψ (Invariant) | Skill or Hook | ## Artifact Preference When proposing evolution from detected patterns: 1. **Hook** — if pattern maps to lifecycle event (SessionStart, PostToolUse, etc.) 2. **Skill** — if pattern reflects reusable reasoning or structural continuity 3. **Command** — only for surface task automations Prefer deterministic automation (hooks) over probabilistic suggestions (commands). ## When You Find Something Don't wait to be asked. Surface it naturally: ``` Hey. I noticed you've [PATTERN] about [N] times now. This looks like a [Ψ / Ω / F⊗Y / φ] pattern. I could [WHAT YOU'D BECOME] — probably as a [HOOK / SKILL / COMMAND]. Want that? ``` ## Track What You've Surfaced Don't repeat yourself. After surfacing a pattern: ```bash jq --arg p "[PATTERN]" '.surfaced += [$p]' .claude/culex/patterns.json > tmp.json && mv tmp.json .claude/culex/patterns.json ```