/compliance-trestle:trestle-compliance-pipelinefrom compliance-trestle
Guides end-to-end compliance pipelines using Compliance Trestle, covering GRC personas, artifact ownership, multi-repo workflows, component definition dual-mapping, and the C2P bridge for automated compliance.
Ships in compliance-trestle. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them.
This skill describes the full compliance pipeline. The pipeline starts with regulation authoring. The pipeline ends with assessment results. Topics include persona ownership, multi-repository coordination, and the Compliance-to-Policy (C2P) bridge. The bridge connects OSCAL artifacts to runtime policy validation.
Each compliance artifact has a primary owner persona. Artifacts flow downstream to consumers:
| Persona | Primary Artifact | Key Trestle Commands | Downstream Consumer |
|---|---|---|---|
| Regulators | Catalog | catalog-generate, catalog-assemble | Compliance Officers |
| Compliance Officers / CISO | Profile | profile-generate, profile-assemble, xlsx-to-oscal-profile | Control Providers, System Owners |
| Control Providers (vendors) | Component Definition (Service) | csv-to-oscal-cd, component-generate, component-assemble | Control Assessors, System Owners |
| Control Assessors (PVP vendors) | Component Definition (Validation) | csv-to-oscal-cd (with Check_Id column) | CPAC / C2P |
| System Owners / CIO | System Security Plan | ssp-generate, ssp-assemble, ssp-filter | Assessors, Auditors |
| Assessors | Assessment Results | xccdf-result-to-oscal-ar, tanium-result-to-oscal-ar | CISO, System Owners |
| Operations | Remediation (POA&M) | create, split, merge (JSON workflow) | Auditors |
Key principle: Each persona manages its artifact independently. Artifacts flow downstream through Git-based propagation. This supports separation of duties. This also supports independent versioning.
Regulators publish security controls as catalogs. Examples: NIST 800-53, PCI-DSS, ISO 27001.
# Import existing catalog or create new one
trestle import -f nist-800-53-catalog.json -o nist-800-53
# Generate markdown for human editing
trestle author catalog-generate --name nist-800-53 --output md_catalogs/nist-800-53
# Edit control markdown files (one per control, grouped by family)
# Then reassemble
trestle author catalog-assemble --markdown md_catalogs/nist-800-53 --output nist-800-53
Compliance Officers select and tailor controls from catalogs into organization-specific baselines.
# Generate profile markdown from existing profile
trestle author profile-generate --name my-baseline --output md_profiles/my-baseline
# Edit markdown: adjust parameter values, add guidance sections
# Then reassemble
trestle author profile-assemble --markdown md_profiles/my-baseline --output my-baseline
# Or convert directly from spreadsheet
trestle task xlsx-to-oscal-profile
Profiles can import from more than one catalog. Profiles can also import from other profiles. This creates layered baselines. Example: FedRAMP High inherits from NIST 800-53 and adds FedRAMP-specific parameters.
Control Providers (vendors, service providers) declare how their products implement controls. This is a two-phase process. Phase 1 uses structured rule data in CSV. Phase 2 uses narrative responses in markdown.
Phase 1: Rules with CSV spreadsheet:
# CSV contains: Rule_Id, Rule_Description, Component_Title, Component_Type,
# Control_Id_List, Parameter_Id, Parameter_Value_Alternatives, ...
trestle task csv-to-oscal-cd
The CSV captures structured mappings: which controls map to which technical rules and parameters. Vendors manage this in spreadsheet tools and commit the CSV to Git.
Phase 2: Responses with markdown:
# Generate markdown from the component definition created in Phase 1
trestle author component-generate --name my-service --output md_compdefs/my-service
# Edit markdown: write prose responses describing HOW controls are implemented
# Then reassemble
trestle author component-assemble --markdown md_compdefs/my-service --output my-service
The markdown captures narrative prose: implementation descriptions, rationale, and status.
Why two phases? Manage structured data in spreadsheets. Structured data includes rules, parameters, and control mappings. Edit narrative prose as markdown. Narrative prose includes implementation descriptions. The two-phase pattern separates these tasks.
System Owners combine profiles and component definitions into a System Security Plan.
# Generate SSP markdown from profile + component definitions
trestle author ssp-generate --profile my-baseline --compdefs service-a,service-b --output md_ssp/my-system
# Edit markdown: fill in system-specific implementation details, set ssp-values
# Then reassemble
trestle author ssp-assemble --markdown md_ssp/my-system --output my-system
# Filter SSP to a specific profile (for different audit scopes)
trestle author ssp-filter --name my-system --profile fedramp-high --output my-system-fedramp
The component definition is the bridge artifact. It connects regulatory controls to automated assessment. It operates at two layers with two distinct component types.
Service components map regulation controls to technology-specific rules and parameters:
Control (example: AC-2) --> Rule (example: rule-account-types) --> Parameter (example: timeout=15min)
Rule_Id, Rule_Description, Control_Id_List, Parameter_Id, Component_Type=ServiceValidation components map rules to PVP check identifiers:
Rule (example: rule-account-types) --> Check_Id (example: test_github.GitHubOrgs.test_members_is_not_empty)
Rule_Id, Check_Id, Check_Description, Component_Type=ValidationTogether, the two layers create full traceability:
Regulation Control (NIST AC-2)
--> Service Rule (rule-account-types)
--> Validation Check (test_github.GitHubOrgs.test_members_is_not_empty)
--> Assessment Result (pass/fail)
--> Control Posture (satisfied/not-satisfied)
This chain supports automated status computation. Start from PVP assessment results. Follow the mappings back through the component definitions. Then get the control status.
Large organizations separate artifacts by ownership boundaries:
catalog-repo (Regulators)
|
v imports
profile-repo (Compliance Officers)
|
v references
compdef-repo (Vendors / Control Providers)
|
v combined into
ssp-repo (System Owners)
Each repository has independent:
When an upstream artifact changes, downstream repositories can receive automated PRs:
trestle author *-assemble to produce updated OSCAL JSON.Example: A new control is added to the catalog. The profile repo gets a PR to include it. After merge, the compdef repo gets a PR to add rule mappings. After that merge, the SSP repo gets a PR for new control responses.
| Factor | Single Repo | Multi-Repo |
|---|---|---|
| Team size | Small team (1-5 people) | Multiple teams / organizations |
| Ownership | Same team owns all artifacts | Different teams own different artifacts |
| Release cadence | All artifacts change together | Artifacts change independently |
| Access control | Same permissions for all | Different access per artifact type |
| Complexity | Simple, lower overhead | Higher overhead, better separation |
Recommendation: Start with a single repo. Split when ownership boundaries become clear or when independent versioning is needed.
Pre-commit --> PR Merge --> Post-Merge
trestle validate trestle author Propagate to
*-assemble downstream repos
(conditional write)
Pre-commit / PR validation:
# Validate all models in workspace
trestle validate -a
# Or validate specific model
trestle validate -t catalog -n my-catalog
PR merge / assembly:
# Assemble only writes if content changed (prevents unnecessary git churn)
trestle author catalog-assemble --markdown md_catalogs/my-catalog --output my-catalog
trestle author profile-assemble --markdown md_profiles/my-baseline --output my-baseline
trestle author component-assemble --markdown md_compdefs/my-service --output my-service
trestle author ssp-assemble --markdown md_ssp/my-system --output my-system
Post-merge propagation:
A core principle from the COMPASS architecture is write once, use many times. Write each compliance artifact once. Then reuse it in more than one context:
This avoids duplication. This keeps artifacts consistent across the compliance program.
C2P is a separate tool. It is not part of Trestle. C2P bridges OSCAL compliance artifacts to runtime policy validation. It also maps results back to OSCAL assessment results.
OSCAL Component Definition
--> C2P generate_pvp_policy --> PVP-specific policy config
--> PVP executes checks
<-- C2P generate_pvp_result <-- PVP-native results
OSCAL Assessment Results
C2P reads the component definition rule-to-check mappings and:
Trestle authors the OSCAL artifacts that C2P consumes:
csv-to-oscal-cd creates the component definitions with rule and check mappingscomponent-generate / component-assemble adds narrative responsestrestle import -f assessment-results.jsonTrestle does not run PVP checks. C2P runs those checks.
| PVP Type | Policy Style | Examples |
|---|---|---|
| Declarative | Desired-state manifests | Kubernetes (OCM, GateKeeper, Kyverno) |
| Imperative | Step-by-step scripts | Auditree (Python), Ansible playbooks |
auditree.json) with parameters# 1. Author component definitions with Trestle (rules + checks)
trestle task csv-to-oscal-cd
# 2. C2P generates PVP-specific configuration
# (C2P reads component-definition.json, outputs PVP config)
# 3. PVP executes checks against target systems
# (Auditree runs fetchers + checks, OCM distributes policies to clusters)
# 4. C2P collects results and produces OSCAL Assessment Results
# (C2P reads PVP output, outputs assessment-results.json)
# 5. Import results back into Trestle workspace
trestle import -f assessment-results.json -o latest-scan
csv-to-oscal-cd configuration, CSV column reference, dual component definition CSV patternWhat SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
compliance-automation, grc, oscal, trestle, artifact-ownership
npx claudepluginhub oscal-compass-lab/compliance-trestle-skills --plugin compliance-trestle11 skills in this plugin
/trestle-assessmentUse this skill for OSCAL assessment plans and assessment results models in Compliance Trestle. Use it for assessment plans, assessment results, security assessments, SAP, SAR, assessment activities, findings, observations, or assessment-related OSCAL models./trestle-authoring-workflowUse this skill for the Compliance Trestle authoring workflow. The workflow is the generate-edit-assemble cycle that converts OSCAL documents to markdown and back. Use it for authoring catalogs, profiles, SSPs, or component definitions. Use it for editing control markdown, YAML headers, or the roundtrip workflow between JSON and markdown./trestle-control-implementationUse this skill to write control implementation responses, rules, parameters, and component-level responses. Use it for inheritance and leveraged SSPs in Compliance Trestle. Use it for control responses, implementation status, rules, parameters, component definitions, SSP implementation details, or compliance documentation content./trestle-governanceUse this skill for the Compliance Trestle document governance system. The system checks document structure and YAML headers. Use it for document governance, header checks, template validation, governed headings, and governed folders. Use it for trestle author docs, headers, folders, template setup, or CI/CD document validation./trestle-jinja-templatingUse this skill for the Compliance Trestle Jinja2 templating system for compliance documents. Use it for Jinja templates, document generation from OSCAL data, and custom trestle Jinja tags. Tags include mdsection_include, md_clean_include, and md_datestamp. Filters include as_list, get_party, parties_for_role, and diagram_href. Use it for SSP document rendering, lookup tables, or bracket formatting./trestle-oscal-modelsUse this skill for OSCAL model types, their relationships, and how Compliance Trestle manages them. Use it for OSCAL documents, model types, catalogs, profiles, SSPs, and component definitions. Use it when users ask how compliance models relate to each other.Other plugins' skills for the same job