OSCAL Document Engineering
Use this skill when a user wants to turn old compliance documents into maintainable OSCAL.
Typical outputs are SSPs, SAPs, SARs, POA&Ms, component definitions, and evidence packages.
Core rule
Every OSCAL statement must be traceable to source text, collected evidence, or a user-supplied assertion.
If the source is unclear, mark the item needs_review.
Do not invent a compliance fact.
Inputs
Common inputs:
- SSP in PDF, DOCX, Markdown, or text.
- Existing OSCAL JSON, XML, or YAML.
- Evidence folders, diagrams, inventories, policies, or POA&M spreadsheets.
- Framework or profile target such as FedRAMP Moderate, NIST 800-53, SOC 2, ISO 27001, or organization-specific profiles.
Outputs
Make these artifacts:
- OSCAL workspace or package.
source-traceability-map.csv.
ssp-import-plan.md.
import-summary.md.
validation-report.json or a Markdown equivalent.
unmapped-items.md that lists content that needs human review.
Workflow
- Make sure you know the source files and the target OSCAL document type.
- Make a workspace outside committed source unless you use a synthetic example.
- Extract text. Keep page numbers, headings, and section identifiers when possible.
- Build a source traceability map with
templates/source-traceability-map.csv.
- Start or update a Compliance Trestle workspace.
- Draft a schema-valid SSP from extracted sections when Trestle is available:
bash plugins/document-transform/oscal-document-workbench/scripts/draft-ssp-from-extraction.sh <workspace> --overwrite
The FedRAMP Rev 5 heading map at plugins/document-transform/oscal-document-workbench/templates/fedramp-rev5-heading-map.json is an optional adapter for FedRAMP-style SSPs.
For SOC 2, ISO 27001, or other sources, keep unmatched sections needs_review.
Do not force FedRAMP field targets.
7. Refine mappings and fill remaining OSCAL SSP structure:
- metadata
- parties and roles
- system characteristics
- system implementation
- control implementation
- inventory items
- back matter resources
- Validate with Compliance Trestle and OSCAL CLI when available.
- Make summary reports and identify gaps.
- Ask the user or system owner to review all
needs_review items.
Mapping guidance
- Map document title, version, system name, owner, and dates into OSCAL metadata.
- Map authorizing officials, system owners, ISSOs, assessors, and service providers into parties and responsible roles.
- Map boundary descriptions, data types, users, deployment model, and interconnections into system characteristics.
- Map components, services, accounts, inventories, and cloud resources into system implementation.
- Map control narratives by control ID into control implementation statements.
- Map attachments, diagrams, policies, and evidence into back matter resources.
Validation commands
Use commands that are available in the local environment. Examples:
trestle validate -f <path-to-ssp.json>
trestle validate -a
oscal-cli validate --disable-constraint-validation <path-to-ssp.json>
If a validator is missing, report the missing dependency.
Continue only if the user accepts partial validation.
References
references/legacy-doc-ingestion.md
references/oscal-validation.md
templates/ssp-import-plan.md
templates/source-traceability-map.csv
1---2name: oscal-document-engineering3description: Convert, validate, and maintain OSCAL documents from legacy SSP/PDF/DOCX/Markdown source material.4---56# OSCAL Document Engineering78Use this skill when a user wants to turn old compliance documents into maintainable OSCAL.9Typical outputs are SSPs, SAPs, SARs, POA&Ms, component definitions, and evidence packages.1011## Core rule1213Every OSCAL statement must be traceable to source text, collected evidence, or a user-supplied assertion.14If the source is unclear, mark the item `needs_review`.15Do not invent a compliance fact.1617## Inputs1819Common inputs:2021- SSP in PDF, DOCX, Markdown, or text.22- Existing OSCAL JSON, XML, or YAML.23- Evidence folders, diagrams, inventories, policies, or POA&M spreadsheets.24- Framework or profile target such as FedRAMP Moderate, NIST 800-53, SOC 2, ISO 27001, or organization-specific profiles.2526## Outputs2728Make these artifacts:2930- OSCAL workspace or package.31- `source-traceability-map.csv`.32- `ssp-import-plan.md`.33- `import-summary.md`.34- `validation-report.json` or a Markdown equivalent.35- `unmapped-items.md` that lists content that needs human review.3637## Workflow38391. Make sure you know the source files and the target OSCAL document type.402. Make a workspace outside committed source unless you use a synthetic example.413. Extract text. Keep page numbers, headings, and section identifiers when possible.424. Build a source traceability map with `templates/source-traceability-map.csv`.435. Start or update a Compliance Trestle workspace.446. Draft a schema-valid SSP from extracted sections when Trestle is available:4546```bash47bash plugins/document-transform/oscal-document-workbench/scripts/draft-ssp-from-extraction.sh <workspace> --overwrite48```4950The FedRAMP Rev 5 heading map at `plugins/document-transform/oscal-document-workbench/templates/fedramp-rev5-heading-map.json` is an optional adapter for FedRAMP-style SSPs.51For SOC 2, ISO 27001, or other sources, keep unmatched sections `needs_review`.52Do not force FedRAMP field targets.537. Refine mappings and fill remaining OSCAL SSP structure:54 - metadata55 - parties and roles56 - system characteristics57 - system implementation58 - control implementation59 - inventory items60 - back matter resources618. Validate with Compliance Trestle and OSCAL CLI when available.629. Make summary reports and identify gaps.6310. Ask the user or system owner to review all `needs_review` items.6465## Mapping guidance6667- Map document title, version, system name, owner, and dates into OSCAL metadata.68- Map authorizing officials, system owners, ISSOs, assessors, and service providers into parties and responsible roles.69- Map boundary descriptions, data types, users, deployment model, and interconnections into system characteristics.70- Map components, services, accounts, inventories, and cloud resources into system implementation.71- Map control narratives by control ID into control implementation statements.72- Map attachments, diagrams, policies, and evidence into back matter resources.7374## Validation commands7576Use commands that are available in the local environment. Examples:7778```bash79trestle validate -f <path-to-ssp.json>80trestle validate -a81oscal-cli validate --disable-constraint-validation <path-to-ssp.json>82```8384If a validator is missing, report the missing dependency.85Continue only if the user accepts partial validation.8687## References8889- `references/legacy-doc-ingestion.md`90- `references/oscal-validation.md`91- `templates/ssp-import-plan.md`92- `templates/source-traceability-map.csv`