Pattern Learn
Skill name: pattern-learn
Learn from normalized downstream failure events. Use after judge, PR review, GitHub review, CI, QA, or manual notes emit docs/issues/<branch>/learning-events/*.yaml to classify findings, create pattern rule proposals or rule modifications, and write non-rule learning recommendations.
Use this after downstream evaluators produce learning events. It consumes failure signals and proposes durable improvements. It does not change active rules.
Deterministic helper:
python3 /Users/trent.brown/agentic-development-workflow/scripts/pattern_tool.py event-inventory <issue-dir> <pattern-dir>
Workflow:
- Fail if no applicable
.pattern-reviewdirectory is found after the normal scope walk or if an explicit pattern directory does not exist. Tell the caller to run/pattern-init <intended-scope>. - Display the
.pattern-reviewdirectory that will receive proposals or be checked for processed provenance. - Read
docs/issues/<branch>/learning-events/*.yaml. Each event represents one finding. - Use event IDs and fingerprints to skip already-processed events by checking provenance in
rules.yaml,proposals.yaml,deferred.yaml, andrejected.yaml. - Classify each pending event as one of:
new_pattern_rule,existing_rule_missed,existing_rule_ignored,process_gap,documentation_gap,test_gap,domain_knowledge,one_off_bug, ordisputed_or_unclear. - For rule-worthy outcomes, write
new_ruleormodify_ruleproposals to.pattern-review/proposals.yamlwith event provenance. For modifications, include a complete resolved rule candidate; do not patch active rules. Preserve evidence as structured source locations withpathrelative to the.pattern-reviewscope root and, when known,line. Avoid machine-specific absolute paths unless the source is outside any portable checkout context. Do not encode Markdown links in YAML; reports can render clickable links from those fields. - For non-rule outcomes, write
docs/issues/<branch>/learning-recommendations.mdor the analogous source-event location. - Normalize lifecycle YAML after writing proposals:
python3 /Users/trent.brown/agentic-development-workflow/scripts/pattern_tool.py normalize-buckets <pattern-dir>. - Parse the normalized lifecycle files before reporting success. Treat parse failures as command failures.
- Do not mutate learning-event source files. They are evidence, not state.
- Do not modify
rules.yaml; onlypattern-promotechanges active rules.