Skip to content
Back to skills

Traceability Export

ASecurity

Export the REQ↔DES↔TEST traceability matrix for a feature in csv or markdown format. Phase D ships csv + markdown; Phase E (Assured) extends with standard-specific formats.

  • 41 stars
  • 0 votes
  • 0 copies
  • 2 views
  • Added September 19, 2026
toolspythonbash

Security analysis

A100/100

Scanned September 19, 2026

npx -y skills add SteveGJones/ai-first-sdlc-practices --skill traceability-export --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Traceability Export?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Traceability Export
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/stevegjones-traceability-export/badge)](https://www.skillsdirectory.com/skills/stevegjones-traceability-export)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: traceability-export
description: Export the REQ↔DES↔TEST traceability matrix for a feature in csv or markdown format. Phase D ships csv + markdown; Phase E (Assured) extends with standard-specific formats.
disable-model-invocation: false
argument-hint: "<format> <feature-id> [output-path]"
---
<!-- implements: DES-programme-skills-005 -->

# Export Traceability Matrix

Produce an audit-friendly REQ↔DES↔TEST traceability matrix.

## Arguments

- `<format>` — `csv` or `markdown`
- `<feature-id>` — short slug for the feature
- `[output-path]` — optional. Defaults to `docs/specs/<feature-id>/traceability.<ext>` where `.ext` is `.csv` or `.md`.

## Steps

```bash
FORMAT="$1"
FEATURE_ID="$2"
OUTPUT_PATH="${3:-}"

if [ -z "$FORMAT" ] || [ -z "$FEATURE_ID" ]; then
    echo "Usage: traceability-export <format> <feature-id> [output-path]" >&2
    exit 1
fi

case "$FORMAT" in
    csv|markdown) ;;
    *)
        echo "format must be one of: csv, markdown" >&2
        exit 1
        ;;
esac

FEATURE_DIR="docs/specs/$FEATURE_ID"

if [ -z "$OUTPUT_PATH" ]; then
    case "$FORMAT" in
        csv) OUTPUT_PATH="$FEATURE_DIR/traceability.csv" ;;
        markdown) OUTPUT_PATH="$FEATURE_DIR/traceability.md" ;;
    esac
fi

python3 << PYEOF
from pathlib import Path
from sdlc_programme_scripts.programme.traceability import (
    TraceabilityError, export_csv, export_markdown,
)

format = "$FORMAT"
feature_id = "$FEATURE_ID"
feature_dir = Path("$FEATURE_DIR")
output_path = Path("$OUTPUT_PATH")

try:
    if format == "csv":
        text = export_csv(feature_dir, feature_id)
    elif format == "markdown":
        text = export_markdown(feature_dir, feature_id)
except TraceabilityError as e:
    print(f"ERROR: {e}", flush=True)
    raise SystemExit(1)

output_path.parent.mkdir(parents=True, exist_ok=True)
output_path.write_text(text)
print(f"Wrote {format} traceability matrix to {output_path}")
PYEOF
```

## Done

Report:

- Format used (csv or markdown)
- Output path
- Number of REQ rows in the matrix
- Any orphan REQs (declared but no DES/TEST satisfying them) — these are coverage gaps the team should resolve

## Model selection

This skill runs deterministic Python helpers. Smaller models are sufficient.

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

View all in tools →

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.