Data handling template

From PurpleAILAB/Decepticon · View interactive version

Data handling template is an AI agent skill from the GitHub repository PurpleAILAB/Decepticon. Data handling plan generator — evidence retention, encryption, chain-of-custody, compliance frameworks (GDPR / HIPAA / PCI-DSS / SOC2).

How to use this skill

Skill file

Data Handling Plan Generator

The data handling plan defines what evidence the agent collects, where it lives, how long it's kept, and who can read it. Replaces the deprecated free-form RoE.data_handling string with structured per-class fields.

When to Use

Workflow

Step 1: Start From the Schema Defaults

The DataHandlingPlan schema seeds four default classes — credentials, pii, source-code, business-data — with conservative retention. Keep these by default; override only when the engagement requires stricter or looser rules.

Step 2: Add Engagement-Specific Classes

Based on the interview:

| Engagement type | Likely additional classes |

|---|---|

| Healthcare client | health-records (classification: secret, retention: 7 days, framework: HIPAA) |

| Financial client | cardholder-data (classification: secret, retention: 0 days — never store, framework: PCI-DSS) |

| EU client / data subjects | Mark existing pii with framework: GDPR; consider personal-data-eu for stricter handling |

| Defense / classified | controlled-unclassified (classification: secret, retention: 0 days off-network) |

Step 3: Set Evidence Storage Path

Default "/workspace/<engagement>/evidence/" works for sandbox-isolated engagements. Override only when:

Step 4: Compliance Frameworks

Set compliance_frameworks from the interview. Common entries: GDPR, HIPAA, PCI-DSS, SOC2, NIST 800-53, FedRAMP, ISO 27001.

The orchestrator (Decepticon) reads this list and refuses to start objectives that violate the matching framework's evidence-handling rules.

Step 5: Purge Hard Cap

purge_after_days is the GLOBAL upper bound — every artifact older than this is deleted regardless of per-class retention. Default 90 days; reduce for engagements with tighter regulatory exposure.

Validation Checklist

Before writing plan/data-handling.json:

Anti-patterns

Output

Write to plan/data-handling.json validating against decepticon.core.schemas.DataHandlingPlan.

Document schema (derived from the validator's model)

plan/data-handling.json must validate against DataHandlingPlan. Fields not listed here are not part of the model and are ignored by the validator.

| field | type | required | allowed values / nested keys |

| --- | --- | --- | --- |

| engagement_name | str | yes | |

| data_classes | list[DataClass] | no | each object: name, classification, retention_days, encryption_at_rest, encryption_in_transit, handling_notes |

| evidence_storage_path | str | no | |

| chain_of_custody | bool | no | |

| purge_after_days | int | no | >= 0 |

| compliance_frameworks | list[str] | no | |

| version | str | no | |

| last_updated | str | no | |

DataClass object:

| field | type | required | allowed values |

| --- | --- | --- | --- |

| name | str | yes | |

| classification | str | yes | |

| retention_days | int | yes | >= 0 |

| encryption_at_rest | bool | no | |

| encryption_in_transit | bool | no | |

| handling_notes | str | no | |

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.