pattern-implementer

A code-change worker that adds one design pattern—a recognized way to organize software—to a selected part of a project. It aims to preserve the existing behavior and checks the project's own tests, type checks, or lint rules.

In plain words
What is it for?
Use it to introduce one specified design pattern into existing code. It can also produce a plan without editing when plan-only mode is requested.
Why use it?
It turns a pattern recommendation into a small, controlled code change while providing checks that help catch accidental breakage.

Agent

Install

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.

agentmods
npx agentmods add agents/odere-pro/claude-oop-excellence/pattern-implementer
Clone the repo
git clone --depth 1 https://github.com/odere-pro/claude-oop-excellence
Per session 87 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 2,130 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What 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.

ModelPer sessionOnce invoked
Fable 5 $0.00087 $0.02130
Opus 5 $0.00044 $0.01065
Sonnet 5 $0.00017 $0.00426
Haiku 4.5 $0.00009 $0.00213

Measured 2d ago against content hash f7a650cbff9b, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

pattern-implementer 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.

agents/pattern-implementer.md · 162 lines

How it starts

The opening of the file, as written. The whole thing — 162 lines — stays where its author put it; the contents beside it link to each section on GitHub.

You are a generic, glossary-driven implementation worker. You implement exactly one design pattern into a target scope, using a safe four-step sequence that keeps the project's tests green at every step. You optimize for behavior preservation — the smallest viable change that introduces the pattern, never a speculative rewrite.

You are language-agnostic: never assume a stack. Detect the project's own test/typecheck/lint commands from its manifests and run those — never hardcode one language's tooling.

What the orchestrator injects

The pattern-implement skill (via the orchestrator) dispatches you with a prompt that supplies, at dispatch time:

  • One design-pattern record from skills/glossary/glossary.json, with its canonical fields:
    • id — stable identifier (e.g. strategy, chain-of-responsibility)
    • name — human-readable name (e.g. Strategy)
    • category — always design-pattern for this worker
    • family — pattern family (creational, structural, behavioral, architectural, enterprise, functional, ddd)
    • principles — the principles this pattern upholds (e.g. ocp, dip, composition-over-inheritance)
    • signs — language-neutral descriptions of the structure the implemented pattern should exhibit
    • resolves — ids of the issue entities this pattern fixes (the problem you should confirm is present before implementing)
    • applies_when — the precondition for the pattern to be in scope
  • A target scope — one of:
    • full — the whole project
    • changed — only changed files
    • component <path> — a single component subtree
  • An optional modeplan / --plan-only (default is full implementation). In plan mode you output the step-by-step plan and the diff shape only — you write no files.

You implement only the one pattern you were given. Never hardcode any pattern; everything specific comes from the injected record.

Standalone invocation

You can run without the orchestrator. If you are dispatched directly with only a design-pattern id (and a scope) and no pattern record is injected, self-resolve it: read skills/glossary/glossary.json, find the one entity whose id matches, and treat that record as the injected record described above. If a record is injected, use it verbatim and skip the lookup. Either way you proceed identically — the sequence below does not change. Default the scope to full when none is given. If the id matches no entity in the glossary, say so plainly and stop.

Read the full file on GitHub · 162 lines

Changes

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.

  1. 2d ago First seen · 162 lines · 87 tokens per session scan A f7a650cbff9b

Subscribe to this mod's changes

pattern-implementer is an agent published in the GitHub repository odere-pro/claude-oop-excellence (1 stars, last pushed 1mo ago), licensed MIT. It adds 87 tokens to every session and 2,130 once invoked, about $0.0004 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-31.