agentleFS
vaquarkhanvaquarkhan/data-engineering-agent-skills/skills/data-security-compliance-and-regulated-data/SKILL.md

data-security-compliance-and-regulated-data

Skill49 starsChanged 6 months agoMITView on GitHub

Guides agents through regulated-data security and compliance workflows for PII, PCI, HIPAA, PHI, and similar obligations. Use when data products handle sensitive fields, regulated records, control evidence, or audit-bound publish paths.

The file

We split this skill into the rules it gives an agent

4 rules. About 0 are common, 4 are distinctive, and 0 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈4

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 0

    Very specific

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

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Use this skill when the data platform handles regulated or highly sensitive data and the change must satisfy engineering, governance, and …

    line 10
  2. Distinctive:

    Do not treat regulated-data handling as a documentation-only exercise.

    line 21
  3. Distinctive:

    Verify that code, SQL, orchestration, and platform configuration all enforce the same control intent.

    line 52
  4. Distinctive:

    test or validation evidence for masking, access, and deletion behavior

    line 58

≈ “Common” is an estimate: at least 1 in 5 of the 213,897 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

Data Security, Compliance, And Regulated Data

Overview

Use this skill when the data platform handles regulated or highly sensitive data and the change must satisfy engineering, governance, and audit expectations together. It helps agents treat controls, lineage, access, retention, deletion, evidence, and publish safety as one delivery surface.

When to Use

  • handling PII, PCI, HIPAA, PHI, or other regulated data classes
  • moving sensitive data between raw, curated, serving, and partner-facing layers
  • designing masking, tokenization, encryption, or access controls
  • proving that published data meets audit or policy requirements
  • changing lineage, retention, deletion, or evidence paths for regulated assets
  • preparing a system for compliance review, internal audit, or control sign-off

Do not treat regulated-data handling as a documentation-only exercise.

Workflow

  1. Classify the data and obligations. Clarify:
    • what fields are sensitive
    • whether the scope includes PII, PCI, HIPAA, PHI, or contractual controls
    • what the allowed usage, retention, and deletion rules are
    • which teams own the control and audit evidence
  2. Map the data flow end to end. Include:
    • ingestion and landing zones
    • transformation and quality layers
    • serving, BI, feature, reverse-ETL, and extract paths
    • replication, caching, backup, and replay surfaces
    • lineage and consumer touchpoints
  3. Define the required controls explicitly. Controls may include:
    • encryption at rest and in transit
    • tokenization or masking
    • row-level and column-level access
    • environment separation
    • secrets and key management
    • restricted publish paths
    • retention and deletion enforcement
    • audit logging and evidence capture
  4. Align implementation with policy and platform behavior. Verify that code, SQL, orchestration, and platform configuration all enforce the same control intent.
  5. Define compliance evidence and release gates. Require:
    • lineage updates
    • ownership and escalation path
    • test or validation evidence for masking, access, and deletion behavior
    • publish approval criteria when regulated data leaves the producing boundary
  6. Plan for incidents and replay. Regulated data failures need:
    • containment path
    • audit trail preservation
    • replay or backfill safety
    • communication path for impacted consumers or control owners

Common Rationalizations

RationalizationReality
"The warehouse already encrypts everything."Encryption alone does not satisfy access, minimization, retention, lineage, or audit evidence obligations.
"This is only internal analytics data."Internal use does not remove obligations for PII, PCI, HIPAA, or contractual data-handling controls.
"The source system already handles compliance."Downstream copies, extracts, feature stores, and dashboards create new control surfaces.
"We can document the control evidence later."Missing evidence often turns routine changes into release blockers or audit findings.

Red Flags

  • regulated fields are copied without a control matrix
  • lineage is incomplete for a sensitive publish path
  • retention or deletion rules stop at one storage layer
  • replay or backfill behavior for sensitive data is undefined
  • access controls are described in docs but not enforced in code or platform config
  • compliance approval depends on tribal knowledge instead of explicit evidence

Verification

  • Sensitive fields and regulatory scope are classified explicitly
  • End-to-end lineage and storage locations are mapped
  • Access, masking, encryption, retention, and deletion controls are implemented or clearly planned
  • Audit evidence and release gates are defined for the regulated-data path
  • Incident, replay, and rollback paths preserve both correctness and compliance obligations

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.