defensive-development

Enforce a read-verify protocol before code edits, deletions, or refactors.

5|1|Updated Mar 10, 2026
One-click install
npx skills add https://github.com/microbians/AI.SKILLS --skill defensive-development
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: defensive-development
Source: https://github.com/microbians/AI.SKILLS/tree/main/skills/defensive-development
Command: npx skills add https://github.com/microbians/AI.SKILLS --skill defensive-development

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Verification-first coding practices for AI agents. Verify before acting.

Core Features & Use Cases

  • READ-VERIFY protocol: Read → Map → List → Present → Wait → Execute → Verify
  • API discovery: How to find properties, constructors, getters/setters before using them
  • Safe refactoring: Grep all references across codebase before renaming
  • Deletion thresholds: Confirmation required based on line count
  • Debug first: Logs before changing code

Quick Start

Load this skill at session start or when needed using the command: skill({ name: "defensive-development" }).

Frequently Asked Questions about defensive-development

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I prevent AI agents from making coding mistakes during refactoring?

AI coding mistakes during refactoring are prevented by enforcing a verification-first protocol that requires reading, mapping, listing, presenting, waiting, executing, and verifying before applying edits or deletions.

What is the best way to safely rename functions across an unfamiliar codebase?

Safely renaming functions across an unfamiliar codebase requires grepping all references and presenting a comprehensive list of dependencies before executing the refactor, ensuring no usages are missed.

How does the read-verify protocol work for safe code edits?

The read-verify protocol works by enforcing a strict sequence: read the code, map dependencies, list proposed changes, present them for confirmation, wait for approval, execute edits, and verify the final state.

Do I need to add logging before debugging or changing code?

Adding logs before changing code is a core defensive debugging practice that verifies actual program behavior and runtime property values before executing any modifications or refactors.

How do I verify API properties and constructors before using them in code?

API properties and constructors are verified through API discovery practices that require agents to inspect getters, setters, and constructors in the codebase before attempting to integrate or call them.

Are there line count thresholds for deleting code during refactoring?

Line count thresholds for deleting code require explicit confirmation based on the volume of lines targeted, preventing accidental bulk deletions and ensuring safe refactoring outcomes.