Skip to content
Back to skills

Specdd Refactor

ASecurity

Use when Claude Code needs to refactor code, tests, docs, specs, or project structure in a SpecDD project while preserving specified behavior, public contracts, scenarios, ownership, and local write authority.

  • 4 stars
  • 0 votes
  • 0 copies
  • 1 view
  • Added September 12, 2026
businessgotestingrefactoring

Works with

  • claude code

Security analysis

A100/100

Pro scans all 2 files and shows the line behind each finding

Scanned September 12, 2026

npx -y skills add aibot88/sec_skill_store --skill specdd-refactor --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Specdd Refactor?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Specdd Refactor
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/aibot88-specdd-refactor/badge)](https://www.skillsdirectory.com/skills/aibot88-specdd-refactor)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: specdd-refactor
description: Use when Claude Code needs to refactor code, tests, docs, specs, or project structure in a SpecDD project while preserving specified behavior, public contracts, scenarios, ownership, and local write authority.
license: Apache-2.0
---

# SpecDD Refactor

Use this skill for structure changes that should not change specified behavior.

## Bootstrap Resolution

Before doing anything else in the target project, read bootstrap files in this exact order:

1. `.specdd/bootstrap.md`
2. `.specdd/bootstrap.project.md`, if it exists
3. `.specdd/bootstrap.local.md`, if it exists

Apply them in that order. Later files may narrow or specialize earlier rules, but must not silently weaken project contracts, inherited constraints, or write authority.

## Spec Chain Resolution

Before planning, editing, reviewing, testing, or reporting on a target:

1. Identify the target path, task, behavior, or changed files.
2. Resolve the effective spec chain using the active bootstrap rules.
3. Include same-directory basename specs when applicable.
4. Walk ancestor specs from the selected content root to the target.
5. Read explicit `References` only when they affect the requested work.
6. Identify the nearest local spec that grants write authority before any edit.

Do not infer authority from similar filenames, nearby files, symbols, module names, or conventions unless the active bootstrap or a governing spec explicitly defines that mapping.

## Workflow

1. Identify public contracts, scenarios, invariants, dependencies, and forbidden boundaries.
2. Confirm write authority for every file that would move or change.
3. Prefer small mechanical steps with verification between risky changes.
4. Run baseline checks before refactoring when practical, then rerun after.

## Refactor Rules

- Preserve behavior described by active specs.
- Do not move responsibility across spec boundaries unless the specs or user request require it.
- Do not widen dependencies or add forbidden imports.
- Do not rename public symbols, paths, or contracts unless explicitly in scope.
- Update specs, docs, and tests only when the refactor changes structure they describe.

If behavior must change to complete the request, stop treating it as a pure
refactor and resolve authority for the behavior change.

Files in this skill

  • SKILL.md2.3 KB
  • source.json736 B

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.