nyann:retrofit

nyann:retrofit is a command for Claude Code from thettwe/nyann. It costs 61 tokens per session (634 once invoked), scanned A, original, MIT.

A command that checks an existing repository against a nyann profile and offers to fix differences. A repository is a project’s files and version-control history; drift means the project no longer matches its expected setup.

In plain words
What is it for?
Use it to bring a partly configured or changed repository back in line with a saved profile. It can be run again safely.
Why use it?
It finds missing or incorrectly configured files, documentation problems, and commit messages that do not follow the Conventional Commits format. It can then preview and apply a repair plan.

Command for Claude Code

Written for Claude Code: arguments in frontmatter. Also seen: mentions CLAUDE.md; mentions Claude Code.

Part of the nyann plugin — 41 skills, 41 commands, 3 hooks shipped together

Good fit Use it to bring a partly configured or changed repository back in…

Compare 6 commands from other repositories ↓
Install with agentmods
npx agentmods add commands/thettwe/nyann/retrofit
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.

Clone the repo
git clone --depth 1 https://github.com/thettwe/nyann

Made for: Claude Code.

Or install nyann, the plugin that ships this one along with the rest of its 41 skills, 41 commands, 3 hooks.

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 nyann:retrofit

README.md
[![agentmods](https://agentmods.dev/badge/commands/thettwe/nyann/retrofit.svg)](https://agentmods.dev/commands/thettwe/nyann/retrofit)
Your own site
<a href="https://agentmods.dev/commands/thettwe/nyann/retrofit"><img src="https://agentmods.dev/badge/commands/thettwe/nyann/retrofit.svg" alt="Measured on agentmods" height="20"></a>
Per session 61 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 634 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.00061 $0.00634
Opus 5 $0.00030 $0.00317
Sonnet 5 $0.00012 $0.00127
Haiku 4.5 $0.00006 $0.00063

Measured 7d ago against content hash 3358cfd5c811, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-06, from the pricing page.

Security

Grade A, and why

nyann:retrofit 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 7d 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.

commands/retrofit.md · 71 lines

How it starts

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

Plugin root: This is a Claude Code plugin, NOT a CLI tool. Do NOT search via which, npm list, pip list, or brew list. This file is at <plugin_root>/commands/. All scripts: <plugin_root>/bin/. Read the matching skills/*/SKILL.md for the full flow.

/nyann:retrofit

Wraps bin/retrofit.sh --target <cwd> --profile <name>.

Audit + remediation flow for existing repos with partial or drifted setups:

detect stack → load profile → compute drift → render report → offer fix
                                                                  ↓
                                              build plan → preview → bootstrap

Output is the same four-section drift report as doctor:

MISSING:                  files the profile expects but the repo lacks
MISCONFIGURED:            files present but content short of expectations
NON-COMPLIANT HISTORY:    last N commit subjects that don't match Conventional
                          Commits (informational only — no rewrite offered)

DOCUMENTATION:
  ✓/⚠/✗ CLAUDE.md size against budget
  ✓/✗  internal link resolution
  ⚠    MCP links needing connector verification (skill-layer)
  ✓/⚠  orphan detector on docs/ + memory/

Exit codes:

Code Meaning
0 clean — no drift, nothing to fix
4 warnings only (misconfigured, non-compliant history, orphans, CLAUDE.md warn/absent)
5 critical (missing hygiene files, broken internal links, CLAUDE.md hard-cap error)

When to invoke

  • "fix this repo" / "retrofit this repo" / "bring into compliance" → run this.
  • "my repo is half set up, finish it" / "fill in the gaps" → run this.
  • After /nyann:doctor reports drift and user says "fix it" → run this.

Flags the skill layer forwards

  • --profile <name> override profile resolution for this run.
  • --json emit DriftReport JSON; skips remediation offer.

See also:

  • /nyann:doctor — read-only audit (same report, no remediation).
  • /nyann:bootstrap — full setup from scratch.

Read the full file on GitHub · 71 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. 7d ago First seen · 71 lines · 61 tokens per session scan A 3358cfd5c811

Subscribe to this mod's changes

nyann:retrofit is a command published in the GitHub repository thettwe/nyann (6 stars, last pushed 8d ago), licensed MIT. It adds 61 tokens to every session and 634 once invoked, about $0.0003 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.