reuse-or-replace

reuse-or-replace is a skill for Claude Code from melodic-software/claude-code-plugins. It costs 118 tokens per session (2,075 once invoked), scanned A, original, MIT.

A consistency guide for reusing an established code, document, naming, or process pattern instead of creating a parallel one.

In plain words
What is it for?
Use it when adding a new structure, workflow, format, or convention to an existing project.
Why use it?
Multiple ways to do the same thing make a project harder to understand and maintain. It requires a clear reuse or replacement decision.

Skill for Claude Code

Written for Claude Code: disable-model-invocation in frontmatter. Also seen: mentions CLAUDE.md.

Runs only inside its plugin — its command needs a path that Claude Code sets for a plugin’s own hooks and for nothing else. Install the plugin, not this.

Part of the discipline plugin — 18 skills shipped together

Good fit Use it when adding a new structure, workflow, format, or convention to an existing project.

Compare 6 skills from other repositories ↓
Install

Getting it into your agent

This one installs as part of its plugin. Adding the marketplace and installing the plugin brings it with everything else the plugin ships.

Claude Code
/plugin marketplace add melodic-software/claude-code-plugins
Claude Code
/plugin install discipline

Made for: Claude Code.

Or install discipline, the plugin that ships this one along with the rest of its 18 skills.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for reuse-or-replace

README.md
[![agentmods](https://agentmods.dev/badge/skills/melodic-software/claude-code-plugins/reuse-or-replace/github.svg)](https://agentmods.dev/skills/melodic-software/claude-code-plugins/reuse-or-replace)
Your own site
<a href="https://agentmods.dev/skills/melodic-software/claude-code-plugins/reuse-or-replace"><img src="https://agentmods.dev/badge/skills/melodic-software/claude-code-plugins/reuse-or-replace/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for reuse-or-replace

Your own site · 80×15
<a href="https://agentmods.dev/skills/melodic-software/claude-code-plugins/reuse-or-replace"><img src="https://agentmods.dev/badge/skills/melodic-software/claude-code-plugins/reuse-or-replace.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 118 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 2,075 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
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.1 $0.00118 $0.02075
Opus 5.5 $0.00047 $0.00830
Sonnet 5.5 $0.00024 $0.00415
Haiku 4.5 $0.00012 $0.00208

Measured 5d ago against content hash 94ed7c9de348, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

reuse-or-replace 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 5d 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.

plugins/discipline/skills/reuse-or-replace/SKILL.md · 158 lines

How it starts

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

Reuse or replace

A drift corrector for anti-fragmentation discipline: one way to do a thing, not two. The shared method (re-anchor, audit the work in flight, correct forward, report) lives in ${CLAUDE_PLUGIN_ROOT}/context/re-anchor-audit-correct.md. Read it; this file adds only what is specific to reusing or replacing an established way rather than splitting into a parallel one.

The discipline this re-anchors

When a codebase, structure, or process already has an established way of doing something, new work must not silently stand up a second, parallel way beside it. Two coexisting ways of doing the same thing is fragmentation: it splits the reader's model, doubles the surface that drifts, and taxes every future change with a "which one?" decision. Resolve the source of truth per the method doc's ladder: if the consuming project states a consistency / one-way rule in its own CLAUDE.md / .claude/rules/, re-anchor THAT. Otherwise re-anchor this portable baseline.

Facing an established way, new work has exactly two honest options:

  • Reuse it. Follow the established way, so the codebase keeps one way.
  • Replace it. Openly argue the established way should change, then, if it should, migrate the old uses to the new way and record the decision. Replacement converges the codebase on the new single way.

The sin is neither of those: it is leaving the established way in place and quietly adding a divergent way alongside it, so both now exist.

Misconstrual guard. This is NOT "always conform" (mandatory)

Reusing is not blind conformity, and this skill never demands straight obedience to the incumbent way. Replacing the established way is a first-class, encouraged move, not a deviation to be suppressed. The established way should be replaced when:

  • evidence backs an improvement. Research or measurement shows a better way (route the evidence-gathering to /discipline:do-your-research, invoked via the Skill tool);
  • its rationale is missing. Nobody can say why it is done this way ("I don't know, it just is");
  • it rests on incumbency only. "we've always done it this way" is the sole support;
  • it is stale or outdated. Newer developments may have superseded it; a challenge on this ground requires fresh research, not recall.

Read the full file on GitHub · 158 lines

Files

What ships with it

1 file beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

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. 5d ago Changed · -22 lines 94ed7c9de348
  2. 8d ago Changed · +14 lines 772e19d2ac55
  3. 22d ago Changed · -65 tokens per session b52f688bf503
  4. 27d ago Changed 92536d1730d5
  5. 1mo ago Changed · -3 lines 30f00eb54d10
  6. 1mo ago First seen · 169 lines · 183 tokens per session scan A f9c737375fc1

Subscribe to this mod's changes

reuse-or-replace is a skill published in the GitHub repository melodic-software/claude-code-plugins (26 stars, last pushed today), licensed MIT. It adds 118 tokens to every session and 2,075 once invoked, about $0.0005 per session on Opus 5.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-09-03.

Related

Other skills, from other repositories

parallel-orchestrator

Manage parallel Claude Code workstreams using git worktrees. Use when: splitting large tasks across multiple workers, coordinating parallel development, monitoring worker progress, integrating completed work, analyzing work item documents (code reviews, issue lists). Triggers: parallel, orchestrator, worktrees…

jimmc414/claude-code-plugin-marketplace · 78 tokens

event-planner

Event planning with timelines, budgets, vendor coordination, logistics checklists, and post-event evaluation. Use when organizing conferences, workshops, galas, or corporate events.

travisjneuman/.claude · 37 tokens

pass-function-as-arg

For generic algorithms: strategy pattern, callbacks, configurable behavior. Pass functions as parameters to customize algorithm behavior.

jimmc414/claude-code-plugin-marketplace · 27 tokens

catch-expected-errors

For iteration with errors: catch exceptions during exploration, skip invalid cases, continue to next attempt.

jimmc414/claude-code-plugin-marketplace · 24 tokens

find-shortest-path

For pathfinding and search: shortest path, maze solving, game AI, route planning, graph traversal, BFS/DFS, Dijkstra, A problems.

jimmc414/claude-code-plugin-marketplace · 37 tokens

hiring-craft

Use when designing interview loops, writing interview questions or rubrics, calibrating panel feedback, running hiring debriefs, or making a hire/no-hire call. Trigger phrases include "design an interview loop for [role]", "write interview questions for [signal]", "help me run the debrief", "should we hire X", "I need…

shrwnsan/vibekit-claude-plugins · 83 tokens