Minimal Validation
Purpose
After a code change, find and run the cheapest validation loop that gives credible evidence the change is correct.
This skill is not for "run everything".
It is for:
- narrow tests
- focused lint or type checks
- targeted smoke checks
- tiny local repros
- behavior-preserving refactor verification
Use when
Use this skill when:
- code has just been changed
- the user asks to "check", "verify", "validate", "make sure it works", "run minimal tests", or similar
- a fix, refactor, or feature slice needs lightweight proof
- the user did not specify a validation plan, but some verification is clearly needed
Typical trigger phrases:
- "проверь"
- "провалидаируй"
- "сделай минимальную проверку"
- "запусти только нужные тесты"
- "smoke check this"
- "validate the change"
- "make sure this refactor still works"
- "run the smallest relevant checks"
Do not use when
Do not use this skill for:
- full CI or full regression suites
- benchmark or performance validation
- load or stress testing
- security testing
- release readiness checks
- architecture review
- debugging without code changes
- test authoring as the main goal
If the user explicitly asks for full validation, broad CI, performance checks, or release checks, do that directly instead.
Inputs
Expected inputs:
- the changed files or diff
- the kind of change:
- bug fix
- refactor
- feature slice
- config or schema change
- test-only change
- repository conventions and available tooling
Optional inputs:
- repro steps
- failing test or CI output
- nearby tests
- build or run commands
- changed public interfaces
Outputs
Always produce:
- the chosen minimal validation plan
- the commands run
- the result of each check
- any remaining validation gap or residual risk
Core rule
Choose the smallest check that still meaningfully exercises the changed behavior.
Bias toward:
- one focused unit test over a whole suite
- one package or file-level type check over the entire workspace
- one targeted smoke run over a full application boot sequence
- one narrow repro over a broad integration pass
Constraints
- Read the nearest
AGENTS.md before selecting commands.
- Prefer existing tests, scripts, and validation commands over inventing new ones.
- Keep the validation loop cheap by default.
- If narrow validation passes, describe what remains unvalidated instead of overstating confidence.
- Only add new tests when the case is obviously small and strongly justified by the change.
Procedure
Inspect what changed.
Read the diff and identify:
- changed files
- changed behavior
- whether the change is logic, interface, UI, config, data, or refactor only
Inspect local validation affordances.
Look for:
- test framework and nearest tests
- lint or formatting commands
- type-check commands
- package- or module-level verification commands
- smoke run scripts
- existing repo conventions from
AGENTS.md, README, package files, or scripts
Classify the change.
Common categories:
- pure logic change
- behavior-preserving refactor
- API or interface change
- UI or frontend change
- config or schema change
- CLI or script change
- data pipeline step change
- test-only change
Pick the narrowest relevant validation.
For each category, prefer:
Pure logic change:
focused unit test(s) for the touched function or module
Behavior-preserving refactor:
the smallest test, build, or smoke check that proves behavior stayed the same
API or interface change:
targeted test around the touched interface plus type or static checks if relevant
UI or frontend change:
smallest build, test, preview, or smoke path that exercises the changed screen or component
Config or schema change:
schema parse, config load, or the narrowest startup path that reads it
CLI or script change:
targeted command invocation with a minimal fixture or dry-run path
Data pipeline step:
tiny sample input run, schema check, and output shape assertions
Prefer existing tests first.
If an existing focused test already covers the touched behavior, run it.
If not, run the next-cheapest meaningful check.
Only add new tests if they are obviously small and strongly justified.
Keep scope tight.
Do not escalate to:
- full suite
- full workspace type-check
- full end-to-end run
- expensive training or data processing
unless the narrow checks are insufficient or the user explicitly asks
Run checks and interpret results.
For each check:
- report the exact command
- summarize pass or fail
- connect the result back to the changed behavior
Report residual risk honestly.
If the minimal checks pass but there is still an unvalidated surface, say so explicitly.
Decision rules
Minimality rule
Validation should be as cheap as possible, but not cheaper than the changed behavior allows.
Existing-path rule
Prefer existing tests, scripts, and validation commands over inventing new ones.
Refactor rule
For behavior-preserving refactors, prove non-change with the smallest useful check after each meaningful extraction or change.
Escalation rule
Escalate validation scope only if:
- the minimal check fails
- the minimal check does not exercise the changed behavior
- the change affects a wider contract than initially assumed
Honesty rule
A passing narrow check is evidence, not proof of total correctness.
Always name the remaining blind spots.
References
Use the supporting references when needed:
references/validation-matrix.md for change-type to check selection
references/common-check-patterns.md for common narrow validation shapes
references/residual-risk-template.md for consistent residual-risk reporting
Definition of done
- The changed behavior has a concrete, minimal validation target.
- The narrowest meaningful checks were chosen and, when possible, executed.
- Commands and outcomes are reported explicitly.
- Coverage is tied back to the actual change.
- Residual risk is stated honestly.
Final response format
Return a compact summary in this structure:
- Validation target: ...
- Chosen checks:
<command> — why this is the smallest relevant check
<command> — why this is needed
- Results:
- Coverage:
- what behavior was actually exercised
- Residual risk:
Positive examples
Use this skill for:
- "проверь изменение"
- "сделай минимальную валидацию"
- "запусти только нужные тесты"
- "проверь, что рефактор ничего не сломал"
- "run the smallest relevant checks"
- "smoke test this change"
Negative examples
Do not use this skill for:
- "прогони весь CI"
- "сделай benchmark"
- "нагрузи сервис"
- "сделай security review"
- "напиши тестовую стратегию на релиз"
1---2name: minimal-validation3description: Build and run the smallest credible validation loop after code changes. Trigger when the user asks to verify, validate, sanity-check, smoke-test, run the minimal tests, check that a refactor or fix still works, or when code was just changed and the task needs a cheap proof of correctness but no explicit validation plan was given. Inspect the diff, changed files, local project conventions, and available validation commands, then choose the narrowest relevant checks: focused unit tests, file- or package-scoped lint and type checks, smoke checks, targeted local runs, or tiny repros. Prefer the cheapest validation that meaningfully exercises the changed behavior. Do not use for full CI, broad regression suites, performance benchmarking, load testing, or release validation unless the user explicitly asks for those.4---56# Minimal Validation78## Purpose910After a code change, find and run the cheapest validation loop that gives credible evidence the change is correct.1112This skill is not for "run everything".13It is for:14- narrow tests15- focused lint or type checks16- targeted smoke checks17- tiny local repros18- behavior-preserving refactor verification1920## Use when2122Use this skill when:23- code has just been changed24- the user asks to "check", "verify", "validate", "make sure it works", "run minimal tests", or similar25- a fix, refactor, or feature slice needs lightweight proof26- the user did not specify a validation plan, but some verification is clearly needed2728Typical trigger phrases:29- "проверь"30- "провалидаируй"31- "сделай минимальную проверку"32- "запусти только нужные тесты"33- "smoke check this"34- "validate the change"35- "make sure this refactor still works"36- "run the smallest relevant checks"3738## Do not use when3940Do not use this skill for:41- full CI or full regression suites42- benchmark or performance validation43- load or stress testing44- security testing45- release readiness checks46- architecture review47- debugging without code changes48- test authoring as the main goal4950If the user explicitly asks for full validation, broad CI, performance checks, or release checks, do that directly instead.5152## Inputs5354Expected inputs:55- the changed files or diff56- the kind of change:57 - bug fix58 - refactor59 - feature slice60 - config or schema change61 - test-only change62- repository conventions and available tooling6364Optional inputs:65- repro steps66- failing test or CI output67- nearby tests68- build or run commands69- changed public interfaces7071## Outputs7273Always produce:741. the chosen minimal validation plan752. the commands run763. the result of each check774. any remaining validation gap or residual risk7879## Core rule8081Choose the smallest check that still meaningfully exercises the changed behavior.8283Bias toward:84- one focused unit test over a whole suite85- one package or file-level type check over the entire workspace86- one targeted smoke run over a full application boot sequence87- one narrow repro over a broad integration pass8889## Constraints9091- Read the nearest `AGENTS.md` before selecting commands.92- Prefer existing tests, scripts, and validation commands over inventing new ones.93- Keep the validation loop cheap by default.94- If narrow validation passes, describe what remains unvalidated instead of overstating confidence.95- Only add new tests when the case is obviously small and strongly justified by the change.9697## Procedure98991. Inspect what changed.100 Read the diff and identify:101 - changed files102 - changed behavior103 - whether the change is logic, interface, UI, config, data, or refactor only1041052. Inspect local validation affordances.106 Look for:107 - test framework and nearest tests108 - lint or formatting commands109 - type-check commands110 - package- or module-level verification commands111 - smoke run scripts112 - existing repo conventions from `AGENTS.md`, `README`, package files, or scripts1131143. Classify the change.115116 Common categories:117 - pure logic change118 - behavior-preserving refactor119 - API or interface change120 - UI or frontend change121 - config or schema change122 - CLI or script change123 - data pipeline step change124 - test-only change1251264. Pick the narrowest relevant validation.127128 For each category, prefer:129130 - Pure logic change:131 focused unit test(s) for the touched function or module132133 - Behavior-preserving refactor:134 the smallest test, build, or smoke check that proves behavior stayed the same135136 - API or interface change:137 targeted test around the touched interface plus type or static checks if relevant138139 - UI or frontend change:140 smallest build, test, preview, or smoke path that exercises the changed screen or component141142 - Config or schema change:143 schema parse, config load, or the narrowest startup path that reads it144145 - CLI or script change:146 targeted command invocation with a minimal fixture or dry-run path147148 - Data pipeline step:149 tiny sample input run, schema check, and output shape assertions1501515. Prefer existing tests first.152 If an existing focused test already covers the touched behavior, run it.153 If not, run the next-cheapest meaningful check.154 Only add new tests if they are obviously small and strongly justified.1551566. Keep scope tight.157 Do not escalate to:158 - full suite159 - full workspace type-check160 - full end-to-end run161 - expensive training or data processing162 unless the narrow checks are insufficient or the user explicitly asks1631647. Run checks and interpret results.165 For each check:166 - report the exact command167 - summarize pass or fail168 - connect the result back to the changed behavior1691708. Report residual risk honestly.171 If the minimal checks pass but there is still an unvalidated surface, say so explicitly.172173## Decision rules174175### Minimality rule176177Validation should be as cheap as possible, but not cheaper than the changed behavior allows.178179### Existing-path rule180181Prefer existing tests, scripts, and validation commands over inventing new ones.182183### Refactor rule184185For behavior-preserving refactors, prove non-change with the smallest useful check after each meaningful extraction or change.186187### Escalation rule188189Escalate validation scope only if:190- the minimal check fails191- the minimal check does not exercise the changed behavior192- the change affects a wider contract than initially assumed193194### Honesty rule195196A passing narrow check is evidence, not proof of total correctness.197Always name the remaining blind spots.198199## References200201Use the supporting references when needed:202- `references/validation-matrix.md` for change-type to check selection203- `references/common-check-patterns.md` for common narrow validation shapes204- `references/residual-risk-template.md` for consistent residual-risk reporting205206## Definition of done207208- The changed behavior has a concrete, minimal validation target.209- The narrowest meaningful checks were chosen and, when possible, executed.210- Commands and outcomes are reported explicitly.211- Coverage is tied back to the actual change.212- Residual risk is stated honestly.213214## Final response format215216Return a compact summary in this structure:217218- Validation target: ...219- Chosen checks:220 - `<command>` — why this is the smallest relevant check221 - `<command>` — why this is needed222- Results:223 - pass / fail / blocked224- Coverage:225 - what behavior was actually exercised226- Residual risk:227 - what remains unchecked228229## Positive examples230231Use this skill for:232- "проверь изменение"233- "сделай минимальную валидацию"234- "запусти только нужные тесты"235- "проверь, что рефактор ничего не сломал"236- "run the smallest relevant checks"237- "smoke test this change"238239## Negative examples240241Do not use this skill for:242- "прогони весь CI"243- "сделай benchmark"244- "нагрузи сервис"245- "сделай security review"246- "напиши тестовую стратегию на релиз"