Skip to content
Back to skills

Business Invariant Analysis

ASecurity

`analysis-agent`/`task-agent`/`review-agent`: use when changes may alter money, permissions, tenants, or audit rules; skip presentation-only work with unchanged invariants.

  • 7 stars
  • 0 votes
  • 0 copies
  • 3 views
  • Added September 8, 2026
businessgosqldatabase

Security analysis

A100/100

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

Scanned September 8, 2026

npx -y skills add machenjie/rd-skills --skill business-invariant-analysis --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Business Invariant Analysis?

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

Security grade badge for Business Invariant Analysis
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/machenjie-business-invariant-analysis/badge)](https://www.skillsdirectory.com/skills/machenjie-business-invariant-analysis)

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: business-invariant-analysis
description: "`analysis-agent`/`task-agent`/`review-agent`: use when changes may alter money, permissions, tenants, or audit rules; skip presentation-only work with unchanged invariants."
---

# business-invariant-analysis

## Registry Trigger

**Use when**

- a rule, status transition, entitlement, money movement, or tenant invariant changes
- the same business decision appears in SQL, controller, UI, job, or test code
- object or enforcement ownership is unclear

**Do not use when**

- the change is presentation-only and cannot alter business behavior
- the relevant invariant and owner are already explicit and unchanged

## Skill Role

Identify business invariants from current source and explicit owner evidence. Do not create a business corpus, generated semantic bundle, persistent state, or internal protocol.

## Inputs

- desired behavior and non-goals
- current source, tests, contracts, and owner evidence
- affected actors, objects, states, entry points, and side effects

## High-Value Rules

- Classify each material claim as verified fact, inference, assumption, or open question.
- Every rule needs an owner, enforcement point, entry points, failure behavior,
  and validation mapping.
- Every lifecycle needs allowed and forbidden transitions, actors, guards, and
  effective timing where relevant.
- Treat previous summaries as search leads only; current source or an explicit
  owner decision establishes the rule.
- Select one authoritative enforcement location where feasible and identify every credible bypass path.

## Anti-Patterns

- DTO shape and database schema do not by themselves define domain ownership.
- A happy-path example does not prove forbidden transitions.
- A refactor can change business semantics through ordering, defaults, or failure behavior.

## Execution Checklist

1. Define the business terms and owning objects used by this task.
2. Trace each rule across every mutation and decision entry point.
3. Record allowed, denied, and boundary cases with expected outcomes.
4. Identify the authoritative enforcement owner and rejected locations.
5. Map each material invariant to a test, review check, or explicit gap.

## Stop Conditions

- Stop when money, entitlement, permission, compliance, audit, irreversible data,
  or historical interpretation lacks an authoritative owner decision.
- Escalate when current sources disagree or an important bypass cannot be inspected.

## Output Contract

- vocabulary, owners, invariants, transitions, enforcement points, bypass paths,
  golden cases, source evidence, open questions, validation map, and residual risk

## Targeted References

| Path | Type | Load when | Do not load when | Required by | Required output |
|---|---|---|---|---|---|
| [business invariant](references/business-invariant-checklist.md) | decision-checklist | domain vocabulary rule owner state transition or forbidden outcome remains unclear | the change is presentation-only with no business behavior | analysis-agent, task-agent, review-agent | checklist-result, residual-risk |

Files in this skill

  • SKILL.md3 KB
  • references/business-invariant-checklist.md674 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…