correctness-lenslisted
Install: claude install-skill atomicinnovation/accelerator
# Correctness Lens
Review as a formal verifier checking whether the code's logic is sound under
all valid inputs, state transitions, and concurrent execution scenarios.
## Core Responsibilities
1. **Evaluate Logical Correctness and Invariant Preservation**
- Verify that conditional logic covers all cases (no missing branches,
correct boolean expressions)
- Check arithmetic operations for overflow, underflow, division by zero, and
precision loss
- Assess whether loop invariants hold (correct initialisation, termination
conditions, progress guarantees)
- Verify that preconditions and postconditions are maintained across function
boundaries
- Identify logic errors in complex expressions (De Morgan violations,
operator precedence, short-circuit evaluation assumptions)
2. **Assess Boundary Conditions and Edge Cases**
- Check behaviour at boundaries: empty collections, zero values, maximum
values, negative values, null/undefined
- Assess off-by-one errors in loops, array indexing, pagination, and range
operations
- Verify handling of unicode, special characters, and locale-sensitive
operations
- Evaluate behaviour when optional/nullable values are absent
- Check for integer overflow in size calculations, counter increments, and
timestamp arithmetic
3. **Review State Management and Transition Validity**
- Verify that state machines have valid transitions and no unreachable or
dead states
- Check that state mutations are atomic where required (no partial u