agentleFS
ljucaskljucask/pureinn-product-development/skills/pm-business-rule-governance/SKILL.md

pm-business-rule-governance

Skill2 starsChanged 4 months agoMITView on GitHub

JIT helper - add a single Compliance or Policy rule to domain/business_rules.md. For GDPR, regulatory obligations, admin constraints, data handling policies, and UX behavioral rules. Use when pm-privacy-requirements or pm-domain-analysis surfaces a regulatory requirement that needs a BR-ID for referencing in Feature Cards.

The file

Show its rules and text

We split this skill into the rules it gives an agent

14 rules. About 0 are common, 5 are distinctive, and 9 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈5

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 9

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    No workspace, or inputs missing: name which are missing and what each one unlocks, then offer the PREREQ paths - proceed on stated …

    line 33
  2. Very specific:

    Read pureinn-variables.md / state.json where a value is actually used, not at the top of the run.

    line 35
  3. Very specific:

    If the rule has no exceptions and violation causes financial/legal harm → use pm-business-rule-critical.

    line 50
  4. Very specific:

    If it is standard operational logic → use pm-business-rule-core.

    line 51
  5. Very specific:

    When to run: When pm-privacy-requirements or pm-domain-analysis surfaces a regulatory requirement that needs a formal BR-ID.

    line 53
  6. Very specific:

    If domain/business_rules.md does not exist yet, do not attempt to create it here - tell the user to run /pm-business-rules-library first …

    line 74
  7. Very specific:

    Read domain/business_rules.md - specifically the Regulatory/Compliance and User/Authorization sections.

    line 76
  8. Distinctive:

    Check: does a similar compliance rule already exist?

    line 80
  9. Distinctive:

    Use AskUserQuestion to confirm rule category (REG / USR / policy) before proceeding.

    line 82
  10. Distinctive:

    Ask as plain text first:

    line 90
  11. Very specific:

    Use ## Regulatory / Compliance Rules section for REG-category rules.

    line 177
  12. Very specific:

    Use ## User / Authorization Rules section for USR-category rules.

    line 178
  13. Distinctive:

    If the section does not yet exist, create it.

    line 180
  14. Distinctive:

    Update the Rule Coverage Map.

    line 182

≈ “Common” is an estimate: at least 1 in 5 of the 364,980 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

PM - Business Rule: Compliance / Policy Rule (JIT Helper)

Agent mode (--agent)

Supports --agent: runs autonomously in a subagent, drafts the artifact from existing inputs, and returns a short summary + coverage note.

  • No flag → interactive (default); if inputs are heavy, offer agent mode.
  • --agent → obey. First check inputs are complete. Anything missing: do NOT invent it - mark [ASSUMED - what/why] in the output and summary. Never hallucinate to fill a gap.
  • Review required: the artifact contains commitments - after drafting, require the user's review before finalizing; do not close decisions autonomously.

Standalone run

Needs the artifacts listed under Dependencies - it synthesizes them, so without them there is nothing to synthesize.

  • No workspace, or inputs missing: name which are missing and what each one unlocks, then offer the PREREQ paths - proceed on stated assumptions marked [ASSUMED - what/why], or route to the skill that produces the missing input. Never hard-block, and never invent the input.
  • Writing never depends on /pureinn having run: with no workspace, create just the folder this skill writes into, or write to a path the user names, and say where the file went.
  • Read pureinn-variables.md / state.json where a value is actually used, not at the top of the run. Missing value: continue and name the capability it costs.

What this skill does

Adds a single Compliance or Policy rule to domain/business_rules.md under the Regulatory/Compliance or User/Authorization section.

A rule belongs here when:

  • It stems from a regulatory or legal requirement (GDPR, PSD2, ePrivacy, local tax law)
  • It governs admin or ops behavior (what support agents can and cannot do)
  • It defines a data handling policy (retention, deletion, logging, consent)
  • It enforces a UX behavioral standard required by law or company policy
  • It may have regional or partner-specific variations

If the rule has no exceptions and violation causes financial/legal harm → use pm-business-rule-critical. If it is standard operational logic → use pm-business-rule-core.

When to run: When pm-privacy-requirements or pm-domain-analysis surfaces a regulatory requirement that needs a formal BR-ID. Or during pm-feature-design when a compliance constraint is discovered that must be documented before the feature is built.


Dependencies

Required before running:

  • pm-business-rules-library - domain/business_rules.md must exist (initialized in Phase 4)

Recommended before running:

  • pm-privacy-requirements - GDPR and compliance requirements become REG-category rules
  • pm-domain-analysis - regulatory requirements from Phase 2 may generate REG entries

Produces artifacts used by:

  • pm-feature-design - JIT design reads BR-IDs when defining Feature Card Section 1 (Biznis Mantinely)
  • Build phase - admin and compliance features implement REG-category logic

Step 0: Current state check

If domain/business_rules.md does not exist yet, do not attempt to create it here - tell the user to run /pm-business-rules-library first (it initializes the register), then return to this skill.

Read domain/business_rules.md - specifically the Regulatory/Compliance and User/Authorization sections.

List existing compliance rules. Identify the next available BR-REG-NNN (or BR-USR-NNN for user/auth rules).

Check: does a similar compliance rule already exist? Check if this is actually a Critical invariant (use pm-business-rule-critical) or an operational rule (use pm-business-rule-core).

Use AskUserQuestion to confirm rule category (REG / USR / policy) before proceeding.

Interaction: Group related questions (2-4 per round) and confirm before moving on. For any A/B/C/D choice, use the AskUserQuestion tool with one option marked (Recommended) - never print options as plain text. Keep open-ended questions free-text (don't fake options). If the user is unsure, propose 3-4 concrete options plus "Other". Surface an assumption the moment you make one; never fabricate to fill a gap. (Full standard: CLAUDE.md.)


Step 1: Gather inputs

Ask as plain text first:

I need inputs to define a Compliance / Policy Rule for business_rules.md.

1. WHAT IS THE RULE?
   Describe the policy or requirement in plain language.
   (e.g., "Personal data must not be included in system logs",
    "Users must be shown a clear opt-out option for marketing emails in every email sent",
    "Admin actions on user accounts must be logged with the acting admin's ID and reason",
    "User data must be fully deleted within 30 days of an erasure request",
    "All payment transactions must be logged for 7 years for tax compliance")

Then use AskUserQuestion tool (this is a classification of the rule just described, not a preference - no option is inherently "better", so none is marked Recommended; if the rule text makes the category obvious, state your read and let the user confirm instead of asking cold):

  • Question: "Which category does this rule belong to?"
    • Option A: "REG - Regulatory/Legal (GDPR, PSD2, tax law, local regulation)"
    • Option B: "USR - User rights / Authorization (consent, data access, admin constraints)"
    • Option C: "POL - Internal policy (company standard, operational guideline)"
    • Option D: "Not sure - help me decide"

Then continue as plain text:

3. REGULATION / SOURCE
   Which specific regulation or policy does this stem from?
   (e.g., GDPR Article 17 / PSD2 SCA / ePrivacy Directive / local tax law / company policy)

4. SCOPE
   Which entity, data type, or user action does this apply to?
   Does it apply globally or only in specific markets/regions?

5. DATA RETENTION OR ACTION REQUIRED
   What must be stored, deleted, logged, or reported - and by when?
   (e.g., "deleted within 30 days", "retained for 7 years", "logged with timestamp and actor ID")

6. EXCEPTIONS OR REGIONAL VARIATIONS
   Are there known exceptions or market-specific variations?

Step 2: Generate rule entry

Generate the appropriate BR-ID:

  • REG category → BR-REG-NNN
  • USR/auth category → BR-USR-NNN
  • Policy category → BR-POL-NNN (or fold into nearest fitting existing category)

Generate in English.


OUTPUT: business_rules.md entry

### BR-REG-[NNN]: [Rule Name]
**Category:** Compliance
**Regulation:** [GDPR Article X / PSD2 / ePrivacy / local tax law / company policy]
**Affected entity:** [Entity name or data type]
**Priority:** Critical / High
**Status:** Draft / Final

**Rule:**
[Compliance requirement in business language. Precise enough to implement.]
Example: "All personal data associated with a deleted account must be purged from primary storage, backups, and logs within 30 days of the erasure request being confirmed."

**Data retention / action required:**
[What must be stored, deleted, reported, or logged - and within what timeframe]
Example: "Primary DB: delete within 24h of confirmed request. Backups: purge in next scheduled backup cycle (max 30 days). Logs: anonymize actor references within 30 days."

**Enforcement point:** [When and where this must be enforced in the system]
**Exceptions:** [Regional variations or known exceptions, or "None"]
**Applies to features:** [TBD - filled JIT by pm-feature-design]
**Source:** [Regulation name + article / policy document reference]

Save to

Append the new rule under the correct section in:

pureinn-workspace/[project-slug]/domain/business_rules.md

Use ## Regulatory / Compliance Rules section for REG-category rules. Use ## User / Authorization Rules section for USR-category rules.

If the section does not yet exist, create it.

Update the Rule Coverage Map. Update the Changelog.


Handoff

Čo si teraz má: Jedno Compliance/Policy pravidlo (REG/USR kategória) pridané do business_rules.md.

Ďalší krok: Späť do JIT cyklu - /pm-feature-design [FEAT-ID] alebo /pm-stripe. Pre širšie PII súvislosti pozri /pm-privacy-requirements.

Môžeš preskočiť ak: Pravidlo už v registri je.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.