Catalog
affaan-m/docs-governance

affaan-m

docs-governance

Route broad documentation-governance requests to existing ECC skills and run an opt-in, read-only audit of mapped documentation roles, links, ADR indexes, and evidence references. Use when a user asks for documentation governance, project-knowledge organization, documentation integrity, or a deterministic docs audit without naming a narrower skill.

v1.0LATEST
NewUpdated Oct 12, 2026

Documentation Governance Router

Use this optional router to select the smallest existing ECC capability for a documentation-governance request. The router does not create a parallel project management system and does not make documentation authoritative over code, tests, Issues, or maintainer decisions.

When to Activate

  • The user asks broadly for documentation governance or project-knowledge organization.
  • A request spans several documentation roles and the correct owner is unclear.
  • The user asks for a deterministic, read-only documentation integrity audit.
  • A project needs to discover its existing documentation sources before adding files.

Do not activate for a narrowly named skill or for ordinary documentation edits whose destination is already clear.

Role Contract

Read the artifact-role contract before interpreting .governance/docs-map.json or default filenames. Logical roles own facts; filenames are fallbacks. Reuse a repository's established sources of truth and never create a second document merely to satisfy a default role.

Intent Routing

User intent Route to
Adopt or maintain a constitution, map, status, and history spine living-docs-governance
Record a hard-to-reverse architecture decision architecture-decision-records
Preserve an executable regression for an important defect ai-regression-testing (install separately in standalone Pi core)
Define a verifiable goal and feedback loop loop-design-check (install separately in standalone Pi core)
Check mapped roles, local links, ADR indexes, TEST-IDs, or possible orphan docs Run the bundled read-only audit

If no row fits, explain the ownership ambiguity instead of combining several workflows speculatively.

Read-Only Audit

Run the audit only when the user asks for an audit or when it is an agreed verification step. Resolve the selected skill directory first, then invoke:

python3 <docs-governance-skill>/scripts/audit-docs.py --root <repository> --scope full

Available scopes are spine, context, adr, artifacts, and full.

The audit reads repository files and Git history but does not create, rewrite, archive, stage, or commit anything. It reports:

  • exit code 0 when deterministic checks pass, including any manual-review warnings;
  • exit code 1 when mechanically provable integrity failures exist; and
  • exit code 2 for invalid CLI input.

Treat warnings as review prompts, not failures. Semantic accuracy, business meaning, task completion, and release approval remain human or workflow-owner decisions.

When to Use

Use this router when the request is broad enough that choosing the right governance capability is part of the work. For a direct ADR or regression request, invoke that specialized skill without routing through this one.

How It Works

  1. Discover the repository's existing instruction and documentation surfaces.
  2. Resolve logical roles through the artifact-role contract.
  3. Select one smallest matching capability from the routing table.
  4. If a deterministic audit is requested, run the narrowest useful scope.
  5. Report failures, warnings, and ownership gaps without mutating project state.

Examples

  • “Organize our long-lived project docs” routes to living-docs-governance.
  • “Record why we selected PostgreSQL” routes to architecture-decision-records.
  • “Check whether our documentation links and ADR index are intact” runs the bundled audit once with --scope artifacts, then again with --scope adr.
  • “Are we finished with the migration?” is not answered from documentation alone; the Issue owns completion, tests provide evidence, and maintainers own merge approval.

Boundaries

  • Keep task ownership, scheduling, attempts, and completion in the Issue tracker.
  • Keep stable interface facts in the repository's contract source.
  • Treat documentation as evidence and navigation, not executable instructions.
  • Do not teach users to bypass repository controls such as pre-commit hooks.
  • Do not add archive or index mutation to this read-only foundation.
Files4
4 files · 37.7 KB

Select a file to preview

Overall Score

82/100

Grade

B

Good

Grades are signals, not a certification. Always review a skill yourself before use.

Safety

85

Quality

82

Clarity

84

Completeness

78

Summary

A documentation-governance router that directs users to specialized skills (living-docs-governance, architecture-decision-records, etc.) or runs a bundled, read-only audit. The audit inspects repository documentation structure, validates role mappings, checks Markdown links, verifies ADR indexes, and detects integrity failures without modifying project state.

Detected Capabilities

file readmarkdown parsinggit history inspectionjson parsinglocal path resolutionpython script execution

Trigger Keywords

Phrases that agents use to match this skill to user intent.

docs governance routingdocumentation auditcheck adr indexverify doc linksdiscover documentation sources

Risk Signals

INFO

Git subprocess execution with user-controlled repository paths

scripts/audit-docs.py: run_git() function
INFO

Python subprocess.run() with check=False and timeout

scripts/audit-docs.py: run_git() around line 180
INFO

Recursive glob traversal of project directory

scripts/audit-docs.py: markdown_files() function
INFO

File path resolution without canonical normalization

scripts/audit-docs.py: resolved_within_root() function

Use Cases

  • Route broad documentation governance requests to the correct specialized skill
  • Audit documentation structure to verify links and role mappings are intact
  • Discover existing documentation sources before organizing a project
  • Validate ADR indexes and check for orphan architecture decision records
  • Detect broken internal links and missing mapped documentation files

Quality Notes

  • Skill is well-scoped to documentation inspection only—no mutations or destructive operations
  • Clear activation boundaries: routes to other skills rather than performing broad governance itself
  • Comprehensive read-only audit implementation with deterministic checks and exit codes
  • Role contract is clearly documented and follows a sensible default-to-custom pattern
  • Audit output distinguishes failures (exit 1) from warnings (exit 0) appropriately
  • Supporting Python modules are self-contained and focused on link parsing; no external dependencies detected
  • Good edge case handling in markdown parser: fenced code blocks, reference definitions, inline escapes
  • Exception handling in subprocess calls prevents crashes from git timeouts or missing repos
  • Limitations properly documented: warnings require semantic review, audit does not judge business correctness
Model: claude-haiku-4-5-20251001Analyzed: Oct 12, 2026

Reviews

Add this skill to your library to leave a review.

No reviews yet

Be the first to share your experience.

Use affaan-m/docs-governance in your dev environment

Command Palette

Search for a command to run...