Harness Memory Pattern Miner
Use this skill when repeated session behavior suggests the workspace needs a reusable skill or agent.
Evidence Sources
Prefer durable harness records over chat recall:
memories/session/
.github/instructions/
.github/prompts/
docs/work-logs/
docs/context/
docs/plans/
docs/reviews/
docs/handovers/
docs/ai-harness/runtime/sessions/
docs/ai-harness/dashboard/state/dashboard-state.json
.governance/ intake notes when present
Do not scan protected legacy source roots unless the user explicitly asks for code-pattern extraction.
Promotion Threshold
Promote a recurring pattern only when all criteria are met:
- The same workflow appears at least three times or across at least two governed sessions.
- The trigger is stable enough to describe in one sentence.
- The inputs, expected outputs, and validation checks are repeatable.
- The work benefits from reusable procedure, reusable scripts, or a dedicated role.
- The pattern is not already covered by an installed skill, agent, prompt, or instruction.
If evidence is thin, create a backlog proposal instead of a skill or agent.
Decision Rules
- Create a skill when the repeated work is procedural and another agent needs reusable instructions or scripts.
- Create an agent when the repeated work is a durable role with a point of view, review lens, or ownership boundary.
- Create both only when a role needs a companion procedure.
- Keep generated assets inside agent/skill ownership roots such as
.github/skills/, .github/agents/, .cursor/, .claude/, or .agents/.
- Never modify application source while mining memory patterns.
Workflow
- Build an evidence table with source path, session/date, repeated action, trigger text, output type, and validation signal.
- Score each candidate from 0 to 10:
- frequency: 0-2
- stability: 0-2
- reuse value: 0-2
- validation clarity: 0-2
- coverage gap: 0-2
- For candidates scoring below 7, write a backlog note or update governance context only.
- For candidates scoring 7 or higher, draft the smallest useful skill or agent.
- Run a collision check against existing catalog entries before creating files.
- If creating a skill, keep
SKILL.md concise and include only resources that are directly useful.
- If creating an agent, define role, tools, operating rules, boundaries, and output format.
- Add tests or catalog assertions when working inside
workspace-init-mcp itself.
- Record residual uncertainty in the review or handover artifact.
Output Format
When proposing candidates, use:
| Candidate |
Score |
Asset Type |
Evidence |
Reason |
Next Action |
When creating assets, report:
- created or updated paths
- evidence summary
- trigger phrase
- validation performed
- remaining uncertainty
1---2name: harness-memory-pattern-miner3description: Analyze session memories, work logs, governance traces, and repeated user requests to identify stable recurring workflows. Use when a harness workspace should turn repeated work into a reusable skill, agent, checklist, or governance playbook without overfitting to one session.4---56# Harness Memory Pattern Miner78Use this skill when repeated session behavior suggests the workspace needs a reusable skill or agent.910## Evidence Sources1112Prefer durable harness records over chat recall:1314- `memories/session/`15- `.github/instructions/`16- `.github/prompts/`17- `docs/work-logs/`18- `docs/context/`19- `docs/plans/`20- `docs/reviews/`21- `docs/handovers/`22- `docs/ai-harness/runtime/sessions/`23- `docs/ai-harness/dashboard/state/dashboard-state.json`24- `.governance/` intake notes when present2526Do not scan protected legacy source roots unless the user explicitly asks for code-pattern extraction.2728## Promotion Threshold2930Promote a recurring pattern only when all criteria are met:31321. The same workflow appears at least three times or across at least two governed sessions.332. The trigger is stable enough to describe in one sentence.343. The inputs, expected outputs, and validation checks are repeatable.354. The work benefits from reusable procedure, reusable scripts, or a dedicated role.365. The pattern is not already covered by an installed skill, agent, prompt, or instruction.3738If evidence is thin, create a backlog proposal instead of a skill or agent.3940## Decision Rules4142- Create a skill when the repeated work is procedural and another agent needs reusable instructions or scripts.43- Create an agent when the repeated work is a durable role with a point of view, review lens, or ownership boundary.44- Create both only when a role needs a companion procedure.45- Keep generated assets inside agent/skill ownership roots such as `.github/skills/`, `.github/agents/`, `.cursor/`, `.claude/`, or `.agents/`.46- Never modify application source while mining memory patterns.4748## Workflow49501. Build an evidence table with source path, session/date, repeated action, trigger text, output type, and validation signal.512. Score each candidate from 0 to 10:52 - frequency: 0-253 - stability: 0-254 - reuse value: 0-255 - validation clarity: 0-256 - coverage gap: 0-2573. For candidates scoring below 7, write a backlog note or update governance context only.584. For candidates scoring 7 or higher, draft the smallest useful skill or agent.595. Run a collision check against existing catalog entries before creating files.606. If creating a skill, keep `SKILL.md` concise and include only resources that are directly useful.617. If creating an agent, define role, tools, operating rules, boundaries, and output format.628. Add tests or catalog assertions when working inside `workspace-init-mcp` itself.639. Record residual uncertainty in the review or handover artifact.6465## Output Format6667When proposing candidates, use:6869| Candidate | Score | Asset Type | Evidence | Reason | Next Action |70| --- | ---: | --- | --- | --- | --- |7172When creating assets, report:7374- created or updated paths75- evidence summary76- trigger phrase77- validation performed78- remaining uncertainty