reference-controls-enricher
БесплатноЗапускает вложенные скриптыНе проверенEnrich a CISO Assistant framework YAML by linking each assessable requirement to reference control URNs from the central doc-pol library (CISO Assistant Key…
от intuitem★ 4 698 звёзд на GitHubОб этом скилле
Reference Controls Enricher
What this skill does
For a given framework YAML, walk every assessable requirement and propose 1–5 reference control URNs from the central doc-pol library (the CISO Assistant Key Reference Controls). Outputs:
- a reviewable xlsx per framework
- a YAML patch applied in place (adds URNs to each requirement's
reference_controlsfield, addsdoc-poltodependencies) - a coverage report
Claude is the reasoner — no embedders, no local models. The pipeline is pure stdlib + pyyaml (+ optional openpyxl for xlsx).
When NOT to use this skill:
- For frameworks with >500 assessable items: the conversation context fills up. Chunk the run across sessions or adapt
tools/mapping_builder/map_v2.pyfor offline use. - For frameworks that already reference
doc-pol:*URNs on most requirements: runcoverage_report.pyfirst; if coverage is already good, don't rewrite.
How to use the helpers
Stdlib + pyyaml scripts under .claude/skills/reference-controls-enricher/scripts/.
SKILL=.claude/skills/reference-controls-enricher/scripts
MB=.claude/skills/mapping-builder/scripts # reused for framework parsing
# Parse a framework YAML (same parser as mapping-builder)
.venv/bin/python $MB/parse_framework.py backend/library/libraries/<framework>.yaml > /tmp/fw.json
# Parse the key-controls library
.venv/bin/python $SKILL/parse_controls.py backend/library/libraries/key-reference-controls.yaml > /tmp/controls.json
# Write a reviewable xlsx from the running verdicts
.venv/bin/python $SKILL/write_review.py /tmp/fw.json /tmp/controls.json /tmp/verdicts.jsonl /tmp/<name>_review.xlsx
# Apply URN assignments to the framework YAML (adds doc-pol dependency if needed)
.venv/bin/python $SKILL/apply_enrichment.py backend/library/libraries/<framework>.yaml /tmp/verdicts.jsonl --bump
# Audit coverage + low-confidence verdicts + zero-URN requirements
.venv/bin/python $SKILL/coverage_report.py /tmp/fw.json /tmp/verdicts.jsonl
Verdicts file format
One JSON object per line. target_urns is the list of doc-pol URNs to link. Empty list → requirement is consciously left unlinked.
{"source_urn": "urn:intuitem:risk:req_node:<fw>:<ref>",
"target_urns": ["urn:intuitem:risk:function:doc-pol:pol.access",
"urn:intuitem:risk:function:doc-pol:tech.mfa"],
"confidence": 8,
"rationale": "Access control obligation with explicit MFA — maps to access policy + MFA capability."}
Persist /tmp/<framework>_verdicts.jsonl and append after each section so progress is recoverable if the conversation gets interrupted.
Always read source_urn from the parsed framework JSON's items[].urn — do NOT construct it from ref_id. Ref_ids may use mixed case (e.g. 2.A.1) but the URN suffix is always lowercase (e.g. 2.a.1). Constructing URNs by string concatenation is a known bug trap.
Parsed framework shape (important)
parse_framework.py emits a flat items list, each item carrying section_urn, section_ref_id, section_name — items are not nested inside sections[].items. Iterate parsed["items"], not parsed["sections"][i]["items"]. This differs from common heuristic expectations and has bitten at least one implementation mid-session.
Workflow
Step 1 — confirm the request
Confirm with the user:
- Target framework YAML path (the one being enriched)
- Whether the framework already has a
doc-poldependency — if yes, existingreference_controlson requirements must be preserved (this skill appends, never replaces) - Whether they want the skill to apply in place or emit a review-only pass
Grep the framework for urn:intuitem:risk:function:doc-pol: to check prior linkage. Report coverage before touching anything.
Step 2 — parse both sides
.venv/bin/python .claude/skills/mapping-builder/scripts/parse_framework.py \
backend/library/libraries/<framework>.yaml > /tmp/fw.json
.venv/bin/python .claude/skills/reference-controls-enricher/scripts/parse_controls.py \
backend/library/libraries/key-reference-controls.yaml > /tmp/controls.json
Read both JSONs. Note n_assessable for the framework and the doc-pol prefix breakdown (doc / pol / proc / tech / phys / train).
Size gate: if n_assessable > 500, stop and recommend a chunked or offline approach.
Step 3 — build a section → prefix-family affinity map (DO NOT SKIP)
Read the sections array from the parsed framework (typically 5–30 entries). For each section, reason about which doc-pol prefixes are most likely relevant. doc-pol prefixes group by control-type:
| Prefix | Typical content |
|---|---|
pol.* |
Policies (access, crypto, supplier, malware, vuln, etc.) |
proc.* |
Operational procedures (incident, change, pam, backup, etc.) |
doc.* |
Registers, records and structured documents (RACI, ROPA, asset register) |
tech.* |
Technical capabilities (MFA, SIEM, WAF, DLP, IAM, EDR, etc.) |
phys.* |
Physical and environmental con |
Установить reference-controls-enricher в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
Без ограничений — скилл может использовать любой инструмент.
Вложенные файлы
FAQ
Что делает скилл reference-controls-enricher?
Enrich a CISO Assistant framework YAML by linking each assessable requirement to reference control URNs from the central doc-pol library (CISO Assistant Key Reference Controls). Produces a reviewable xlsx and patches the framework YAML in place. Use when the user asks to "add reference controls to framework X", "link doc-pol controls to requirements", "wire up applied-control suggestions for framework Y", or wants to contribute a reference-control-enriched framework to backend/library/libraries/.
Как установить скилл reference-controls-enricher?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл reference-controls-enricher запускает скрипты?
Да, скилл несёт исполняемые скрипты. Проверь исходник перед установкой.
Похожие скиллы
skill-creator
Create new skills, modify and improve existing skills, and measure skill performance. Use when users want to create a skill from scratch, edit, or optimize an…
от Anthropicdiscernment-nudge
After you give a substantive answer or draft that the user may act on — advice or recommendations, drafted artifacts such as goals, plans, pitches, proposals…
от Anthropicdata-consolidate
Joins the plant's scheduled exports and connector data into one working dataset — ERP items (NetSuite or Infor M3), sales orders, production work orders…
от Anthropicinspection-to-capa
Runs the quality chain end to end: writes the nonconformance against the requirement it violates, searches history at the moment of writing to say whether…
от Anthropic