Contributing a New Framework¶
This project uses a plugin architecture. Each compliance framework is defined in a single YAML file. No Python code changes needed to add a new framework.
For the full step-by-step guide with field reference, examples, and validation instructions, see:
Quick Start¶
# Generate skeleton
python scripts/scaffold_framework.py --new --id gdpr --name "EU GDPR" --source-url "https://gdpr-info.eu"
# With optional search/update-detection metadata
python scripts/scaffold_framework.py --new --id gdpr --name "EU GDPR" \
--source-url "https://gdpr-info.eu" \
--search-sources "https://gdpr-info.eu" \
--circular-sources "https://edpb.europa.eu/our-work-tools/general-guidance" \
--keywords "data protection,controller"
# Fill in domains (use your LLM to read the regulation and generate the YAML)
# Auto-suggest checks from config_rules you defined
python scripts/scaffold_framework.py --suggest-checks src/aws_india_compliance/frameworks/gdpr.yaml
# Validate
python scripts/scaffold_framework.py --validate src/aws_india_compliance/frameworks/gdpr.yaml
# Rebuild manifest
python scripts/build_manifest.py
# Run tests
PYTHONPATH=src python -m pytest tests/ -v
# Submit PR
git checkout -b add-framework-gdpr
git add src/aws_india_compliance/frameworks/gdpr.yaml
git commit -m "feat: add GDPR compliance framework"
git push origin add-framework-gdpr
What Happens After You Submit a PR¶
- CI validates your YAML automatically (schema, domain fields, check structure, Config rule formats)
- Maintainers review the PR for domain accuracy, correct regulatory citations, and Config rule validity
- Once merged to main, GitHub Actions automatically:
- Validates all framework YAMLs
- Rebuilds
control_mappings.jsonfrom all YAMLs - Regenerates framework documentation pages
- Updates the README "Supported Frameworks" list
- Deploys updated documentation site
- Next PyPI release includes your framework (maintainers handle version bumps and publishing)
You do not need to run any update scripts manually. All post-merge automation is handled by CI.
What Works Automatically After Merge¶
Once your YAML is in src/aws_india_compliance/frameworks/ on main:
list_control_domains("your_id")returns your domainsgenerate_conformance_pack("your_id")generates a Config packsearch_regulatory_text(query, "your_id")searches your source URLsscan_aws_account(...)evaluates your declarative checksadmin checkmonitors your circular_sources for updates- Framework docs are live on the documentation site
- README shows your framework in the supported list