code-modernization-expert

code-modernization-expert is a skill for Claude Code, Codex from ibm-self-serve-assets/building-blocks. It costs 28 tokens per session (1,223 once invoked), scanned A, a copy of code-modernization-expert, Apache-2.0.

A guide for updating older software to newer language versions, frameworks and architectures. It includes assessing the codebase, finding outdated or risky parts, and planning changes in small steps.

In plain words
What is it for?
Use it to plan migrations such as Python 2 to 3, Java 8 to 21, React classes to Hooks, Vue 2 to 3, monoliths to microservices, or callbacks to async code.
Why use it?
It gives structure to modernisation work that can otherwise become a risky, unclear rewrite. It helps identify technical debt, such as duplicated code, vulnerable dependencies, missing tests and tightly connected components.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit Use it to plan migrations such as Python 2 to 3, Java 8 to 21, React classes to Hooks, Vue 2 to 3, monoliths to microservices, or callbacks to async code.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/ibm-self-serve-assets/building-blocks/code-modernization-java
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.

Any agent
npx skills add ibm-self-serve-assets/building-blocks --skill code-modernization-java
Clone the repo
git clone --depth 1 https://github.com/ibm-self-serve-assets/building-blocks

Made for: Claude Code, Codex.

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 code-modernization-expert

README.md
[![agentmods](https://agentmods.dev/badge/skills/ibm-self-serve-assets/building-blocks/code-modernization-java/github.svg)](https://agentmods.dev/skills/ibm-self-serve-assets/building-blocks/code-modernization-java)
Your own site
<a href="https://agentmods.dev/skills/ibm-self-serve-assets/building-blocks/code-modernization-java"><img src="https://agentmods.dev/badge/skills/ibm-self-serve-assets/building-blocks/code-modernization-java/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 code-modernization-expert

Your own site · 80×15
<a href="https://agentmods.dev/skills/ibm-self-serve-assets/building-blocks/code-modernization-java"><img src="https://agentmods.dev/badge/skills/ibm-self-serve-assets/building-blocks/code-modernization-java.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 28 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,223 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 100% copy Near-identical to another mod 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.00028 $0.01223
Opus 5.5 $0.00011 $0.00489
Sonnet 5.5 $0.00006 $0.00245
Haiku 4.5 $0.00003 $0.00122

Measured 1mo ago against content hash a916bb723100, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

code-modernization-expert 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 1mo 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.

Origin

This is a copy

100% identical to code-modernization-expert — 0 lines differ, which has more behind it and is treated as the original. This page carries a canonical link to it rather than competing with it.

ibm-bob/skills/code-modernization-java/SKILL.md · 195 lines

How it starts

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

Modernize legacy codebases systematically using proven enterprise patterns and automated transformations.

Supported Migrations

  • Languages: Python 2→3, Java 8→21, JavaScript ES5→ES6+, TypeScript
  • Frameworks: React Class→Hooks, Vue 2→3, Spring Boot 2→3, Django, Rails, Angular
  • Architecture: Monolith→Microservices, REST→GraphQL, Callbacks→Async/Await

Use Glob to find all source files. Use Grep to identify:

  • Framework versions (package.json, requirements.txt, pom.xml)
  • Deprecated APIs and imports
  • Code smells (TODO, FIXME, HACK)
  • Security vulnerabilities

Generate Current State Report with:

  • Languages, frameworks, versions
  • Dependency health (outdated, vulnerable)
  • Test coverage percentage
  • Technical risks

See assessment-checklist.md for detailed items.

Categorize debt by severity and effort:

  • Code quality (God classes, long methods, duplicates)
  • Dependencies (EOL frameworks, vulnerable libraries)
  • Testing gaps (low coverage, missing tests)
  • Architecture issues (tight coupling, monolithic design)

Use prioritization matrix in debt-prioritization.md to rank items.

Create inventory with: Severity, Effort, Risk, Impact on velocity.

Choose based on context:

  • Strangler Fig: Large monoliths, zero downtime required → patterns/strangler-fig.md
  • Branch by Abstraction: Internal modules, service layers → patterns/branch-by-abstraction.md
  • Seam-Based: Low test coverage, tightly coupled code → patterns/seam-based.md
  • Parallel Run: Mission-critical, financial, healthcare systems → patterns/parallel-run.md

Generate phased roadmap:

Preparation (1-2 weeks):

  • Set up feature flags
  • Implement monitoring/alerting
  • Generate characterization tests
  • Create rollback procedures (see rollback-template.yaml)

Execution (Iterative per module):

  • Read source files
  • Generate tests capturing current behavior
  • Apply transformations with Edit/MultiEdit
  • Update imports and dependencies
  • Run tests to validate
  • Deploy incrementally (1% → 5% → 25% → 100%)

Validation:

  • Run test suite
  • Perform shadow testing
  • Monitor error rates and latency

Cleanup:

  • Remove legacy code
  • Remove feature flags
  • Update documentation

Apply language-specific changes:

Python 2→3: See migrations/python.md

  • print statements → print()
  • dict.iteritems() → dict.items()
  • Add type hints, dataclasses, f-strings

Java 8→21: See migrations/java.md

  • javax.* → jakarta.*
  • Date → java.time.*
  • POJOs → Records
  • Add pattern matching, text blocks

JavaScript ES5→ES6+: See migrations/javascript.md

  • var → let/const
  • callbacks → async/await
  • prototypes → classes
  • Add template literals, modules

React Class→Hooks: See migrations/react.md

  • constructor+state → useState
  • componentDidMount → useEffect
  • lifecycle methods → hooks

Create comprehensive coverage:

Characterization Tests: Capture current behavior (even if buggy) Golden Master Tests: Record production inputs/outputs Approval Tests: Snapshot complex outputs

See testing-strategies.md for examples.

Use Task tool to delegate test generation when needed.

Implement mitigation:

Risk Registry: Track risks with likelihood, impact, mitigation, owners

Rollback Plan: Define triggers (error rate, latency, bugs), immediate actions, validation steps

Monitoring: Track error rates, latency, business metrics, set alerts

See rollback-template.yaml for complete template.

Generate migration report with:

  • Executive summary (current vs target, approach, timeline)
  • Technical details (files modified, dependencies updated, tests added)
  • Results (statistics, test results, performance impact)
  • Lessons learned and next steps

Read the full file on GitHub · 195 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. 1mo ago First seen · 195 lines · 28 tokens per session scan A a916bb723100

Subscribe to this mod's changes

code-modernization-expert is a skill published in the GitHub repository ibm-self-serve-assets/building-blocks (28 stars, last pushed yesterday), licensed Apache-2.0. It adds 28 tokens to every session and 1,223 once invoked, about $0.0001 per session on Opus 5.5. A static security scan graded it A with 0 findings. It is 100% identical to code-modernization-expert, differing in 0 lines, and is treated as a copy.

Related

Other skills, from other repositories

debug-optimize-lcp

Guides debugging and optimizing Largest Contentful Paint (LCP) using Chrome DevTools MCP tools. Use this skill whenever the user asks about LCP performance, slow page loads, Core Web Vitals optimization, or wants to understand why their page's main content takes too long to appear. Also use when the user mentions…

ChromeDevTools/chrome-devtools-mcp · 99 tokens

systematic-debugging

Use when debugging a failing test, build error, or runtime issue that isn't immediately obvious. Guides a 4-phase root cause analysis instead of random fix attempts.

open-metadata/OpenMetadata · 37 tokens

log-error-digest

Analyze log files to troubleshoot errors, identify peak error periods, and produce error clustering, frequency statistics, and time distribution reports. Supports JSON, syslog, and Nginx formats with automatic detection. Use when a user uploads a .log file and asks to analyze errors, find patterns, debug issues, or…

zebbern/claude-code-guide · 71 tokens

deck-retro

Run a fully local agent-deck retrospective over the user's own transcripts, Recall index and logs. Use when a user wants to find recurring failures or take their own finding from investigation through synthetic reproduction, a user-filed issue, a test-first fix and contributor PR handoff. Also use for weekly usage…

asheshgoplani/agent-deck · 86 tokens

incident-response-incident-response

Coordinate production incident triage, mitigation, investigation, recovery, and follow-up. Use when responding to outages or other incidents that require structured operational coordination.

rmyndharis/antigravity-skills · 36 tokens

cwv-optimizer

Diagnose and fix Core Web Vitals issues on AEM Edge Delivery Services pages. Goes deeper than generic CWV advice by understanding EDS-specific performance patterns including the 100KB LCP budget, E-L-D loading phases, block rendering behavior, and third-party script impact. Produces specific fixes for LCP, CLS, and…

adobe/skills · 112 tokens