Invariants is an agent skill by Raphael Salaja that reads an app for rules its code relies on but never writes down. It finds flags that only make sense together and assumptions nothing checks, then returns one numbered report.
What it does
- Groups booleans and status values that are written or read together, and counts the combinations they allow.
- Lists each impossible state with the line that can produce it.
- Suggests collapsing each group into one status or reducer with a single writer.
- Searches for risky shapes like non-null assertions, casts, blind [0] reads and defaults that hide gaps.
- Names where each rule should be enforced, such as a type or a schema parse at the fetch, then waits for you to pick fixes.
When to use it
Use it when UI state feels fragile, before a refactor, or after a bug that came from two flags disagreeing.
How to get it
The skill is free on GitHub under the MIT license, in Raphael Salaja's skills repo. Install the set with npx skills add raphaelsalaja/skills. You call it by name, as /invariants; your agent won't load it on its own.
more skills
Invariants is an agent skill by Raphael Salaja that reads an app for rules its code relies on but never writes down. It finds flags that only make sense together and assumptions nothing checks, then returns one numbered report.
What it does
- Groups booleans and status values that are written or read together, and counts the combinations they allow.
- Lists each impossible state with the line that can produce it.
- Suggests collapsing each group into one status or reducer with a single writer.
- Searches for risky shapes like non-null assertions, casts, blind [0] reads and defaults that hide gaps.
- Names where each rule should be enforced, such as a type or a schema parse at the fetch, then waits for you to pick fixes.
When to use it
Use it when UI state feels fragile, before a refactor, or after a bug that came from two flags disagreeing.
How to get it
The skill is free on GitHub under the MIT license, in Raphael Salaja's skills repo. Install the set with npx skills add raphaelsalaja/skills. You call it by name, as /invariants; your agent won't load it on its own.
more skills
Invariants is an agent skill by Raphael Salaja that reads an app for rules its code relies on but never writes down. It finds flags that only make sense together and assumptions nothing checks, then returns one numbered report.
What it does
- Groups booleans and status values that are written or read together, and counts the combinations they allow.
- Lists each impossible state with the line that can produce it.
- Suggests collapsing each group into one status or reducer with a single writer.
- Searches for risky shapes like non-null assertions, casts, blind [0] reads and defaults that hide gaps.
- Names where each rule should be enforced, such as a type or a schema parse at the fetch, then waits for you to pick fixes.
When to use it
Use it when UI state feels fragile, before a refactor, or after a bug that came from two flags disagreeing.
How to get it
The skill is free on GitHub under the MIT license, in Raphael Salaja's skills repo. Install the set with npx skills add raphaelsalaja/skills. You call it by name, as /invariants; your agent won't load it on its own.

