Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx agentmods add skills/boshu2/agentops/pattern-miningnpx skills add boshu2/agentops --skill pattern-mininggit clone --depth 1 https://github.com/boshu2/agentopsWhat it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5 | $0.00045 | $0.01476 |
| Opus 5 | $0.00023 | $0.00738 |
| Sonnet 5 | $0.00009 | $0.00295 |
| Haiku 4.5 | $0.00005 | $0.00148 |
Grade A, and why
pattern-mining scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 157 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Pattern Mining
Decide whether repeated code demonstrates a reusable rule or only a plausible hypothesis. Similar names and syntax are not enough; the abstraction must survive examples it was not designed around.
Constraints
- To prevent lineage copies from faking recurrence, use independently implemented exemplars with repository anchors.
- Because the candidate must generalize, form it without seeing the holdout and back-apply every holdout-driven refinement.
- To keep weak evidence from becoming architecture, route hypotheses to
no-action; only a fully proven promotion may reachoperationalize.
Workflow
- State the candidate pattern and collect independently implemented
exemplars with repository anchors. Use
researchwhen coverage is unclear. - From the exemplars, separate required invariants, legitimate variation points, and incidental similarity.
- Require at least three distinct exemplars before promotion is possible. Form the candidate abstraction without using the holdout.
- Test it against every exemplar, then a separate holdout. Back-apply the refined abstraction to the original exemplars so the holdout fix cannot silently break them.
- Emit
outcome: promoteonly when the exemplar floor, holdout, and back-application all pass. Route that evidence tooperationalize, which decides whether the eventual shape is a skill, gate, library, template, or no action. - Otherwise emit
outcome: hypothesiswithroute: no-action. Keep the evidence bounded and name what additional observation would retest it.
Diff/align across exemplars
Invariants are extracted mechanically, not remembered. Lay the exemplars side by side, align them structurally (same role, same position in the flow — not same variable names), and diff: what survives every alignment is a candidate invariant; what varies by site is a variation point; what varies with no functional consequence is incidental. Work pairwise before generalizing — an "invariant" derived by skimming all exemplars at once is usually the first exemplar's shape with the others squinted into agreement. Stop condition: every line of the candidate abstraction is traceable to a surviving alignment across all exemplars, or it is deleted. The named failure mode is eyeball convergence — declaring similarity from memory of the files rather than from an explicit alignment, which smuggles one lineage's incidentals into the rule.
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 2d ago First seen · 157 lines · 45 tokens per session scan A 8444d7f8f9aa
pattern-mining is a skill published in the GitHub repository boshu2/agentops (431 stars, last pushed 4d ago), licensed Apache-2.0. It adds 45 tokens to every session and 1,476 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.
Other skills, from other repositories
brainstorm
Explore vague or ambitious ideas into a right-sized requirements-only plan. Use when the user wants to brainstorm, think through scope, decide what to build, or needs collaborative product framing before planning, not for a decisive verdict on whether to adopt or switch to a specific external technology, library, or…
doc-review
Use when the user asks to review or critique a prose planning document — a plan, spec, PRD, requirements doc, or design doc.
audit-project
Run an iterative multi-agent code audit until critical and high findings are resolved. Use when the user says "audit my code", "find all the bugs", "deep code audit", "iterative review", or "review until clean".
autolearn
Compound a solved problem into a durable in-repo learning doc. Use when a verified non-trivial fix lands, the user says "compound this", "document this fix", or "remember this". This is the automatic-capture entry point; for an explicitly requested one-off write-up, use compound.
doubt-driven
Doubt-driven adversarial review. Use when correctness matters more than speed, the code is unfamiliar, stakes are high, a claim can't be checked by the type system or compiler, or verifying now is cheaper than debugging later.
drift-detect
Use when the user says "plan drift", asks whether the roadmap, plans, or docs still match the code, or is deciding what to rebuild when restarting a stalled project. For doc-vs-code drift inside a specific diff, use sync-docs.