upgrade

upgrade is a command for coding agents from MartyBonacci/specswarm. It costs 15 tokens per session (4,255 once invoked), scanned A, original, MIT.

A command for upgrading dependencies or frameworks in a code project. Dependencies are external libraries the project uses, while a framework provides its main application structure.

In plain words
What is it for?
Use it to upgrade packages or frameworks, refactor code affected by breaking changes, run validation tests, and produce a migration report.
Why use it?
It organizes the risky parts of an upgrade, including finding breaking changes and checking whether the updated code still works. It also identifies follow-up tasks that need manual work.

Command

Part of the ss plugin — 10 skills, 34 commands, 6 agents, 4 hooks shipped together

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 commands/martybonacci/specswarm/upgrade
Clone the repo
git clone --depth 1 https://github.com/MartyBonacci/specswarm

Or install ss, the plugin that ships this one along with the rest of its 10 skills, 34 commands, 6 agents, 4 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 upgrade

README.md
[![agentmods](https://agentmods.dev/badge/commands/martybonacci/specswarm/upgrade.svg)](https://agentmods.dev/commands/martybonacci/specswarm/upgrade)
Your own site
<a href="https://agentmods.dev/commands/martybonacci/specswarm/upgrade"><img src="https://agentmods.dev/badge/commands/martybonacci/specswarm/upgrade.svg" alt="Measured on agentmods" height="20"></a>
Per session 15 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 4,255 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.00015 $0.04255
Opus 5 $0.00008 $0.02128
Sonnet 5 $0.00003 $0.00851
Haiku 4.5 $0.00002 $0.00426

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

Security

Grade A, and why

upgrade 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 4d 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/ss/commands/upgrade.md · 633 lines

How it starts

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

User Input

$ARGUMENTS

You MUST consider the user input before proceeding (if not empty).

Goal

Upgrade dependencies or frameworks with automated breaking change analysis and code refactoring.

Purpose: Streamline complex upgrade processes by automating dependency updates, breaking change detection, and code refactoring.

Workflow: Analyze → Plan → Update → Refactor → Test → Report

Scope:

  • Framework upgrades (React 18→19, Vue 2→3, Next.js 13→14, etc.)
  • Dependency upgrades (specific packages or all dependencies)
  • Breaking change detection from changelogs
  • Automated code refactoring for breaking changes
  • Test validation after upgrade

User Experience:

  • Single command handles complex multi-step upgrades
  • Automatic breaking change detection
  • Guided refactoring with codemod suggestions
  • Test-driven validation
  • Clear migration report with manual tasks

Pre-Flight Checks

# Parse arguments
UPGRADE_TARGET=""
UPGRADE_ALL_DEPS=false
PACKAGE_NAME=""
DRY_RUN=false

# Extract upgrade target (first non-flag argument)
for arg in $ARGUMENTS; do
  if [ "${arg:0:2}" != "--" ] && [ -z "$UPGRADE_TARGET" ]; then
    UPGRADE_TARGET="$arg"
  elif [ "$arg" = "--deps" ]; then
    UPGRADE_ALL_DEPS=true
  elif [ "$arg" = "--package" ]; then
    shift
    PACKAGE_NAME="$1"
  elif [ "$arg" = "--dry-run" ]; then
    DRY_RUN=true
  fi
done

# Validate upgrade target
if [ -z "$UPGRADE_TARGET" ] && [ "$UPGRADE_ALL_DEPS" = false ] && [ -z "$PACKAGE_NAME" ]; then
  echo "❌ Error: Upgrade target required"
  echo ""
  echo "Usage: /ss:upgrade \"target\" [--deps] [--package name] [--dry-run]"
  echo ""
  echo "Examples:"
  echo "  /ss:upgrade \"React 18 to React 19\""
  echo "  /ss:upgrade \"Next.js 14 to Next.js 15\""
  echo "  /ss:upgrade --deps                    # All dependencies"
  echo "  /ss:upgrade --package react           # Specific package"
  echo "  /ss:upgrade \"Vue 2 to Vue 3\" --dry-run"
  exit 1
fi

# Normalize upgrade target
if [ "$UPGRADE_ALL_DEPS" = true ]; then
  UPGRADE_TARGET="all dependencies"
elif [ -n "$PACKAGE_NAME" ]; then
  UPGRADE_TARGET="$PACKAGE_NAME to latest"
fi

# Get project root
if ! git rev-parse --git-dir > /dev/null 2>&1; then
  echo "❌ Error: Not in a git repository"
  exit 1
fi

REPO_ROOT=$(git rev-parse --show-toplevel)
cd "$REPO_ROOT"

# Check for package.json
if [ ! -f "package.json" ]; then
  echo "❌ Error: package.json not found"
  echo "   This command currently supports Node.js/npm projects."
  exit 1
fi

Read the full file on GitHub · 633 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. 4d ago First seen · 633 lines · 15 tokens per session scan A 1646f60dd702

Subscribe to this mod's changes

upgrade is a command published in the GitHub repository MartyBonacci/specswarm (65 stars, last pushed 1mo ago), licensed MIT. It adds 15 tokens to every session and 4,255 once invoked, about $0.0001 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.