Traceability Auditor logo

Traceability Auditor

Community
nahisaho
traceability-auditor

Validates complete requirements traceability across EARS requirements → design → tasks → code → tests. Trigger terms: traceability, requirements coverage, coverage matrix, traceability matrix, requirement mapping, test coverage, EARS coverage, requirements tracking, traceability audit, gap detection, orphaned requirements, untested code, coverage validation, traceability analysis. Enforces Constitutional Article V (Traceability Mandate) with comprehensive validation: - Requirement → Design mapping (100% coverage) - Design → Task mapping - Task → Code implementation mapping - Code → Test mapping (100% coverage) - Gap detection (orphaned requirements, untested code) - Coverage percentage reporting - Traceability matrix generation Use when: user needs traceability validation, coverage analysis, gap detection, or requirements tracking across the full development lifecycle.

Overview

Publishernahisaho
RepositoryMUSUBI
Skill nametraceability-auditor
Stars
77
Forks
7
Bundled files
2
LicenseMIT
Links
  • Markdown instructions

    A SKILL.md file the model loads on demand, so it only costs tokens when a request actually matches.

  • Works with any LLM

    AI skills are plain Markdown, not provider-specific code, so this works with GPT, Claude, Gemini, Grok, or a local model.

  • 2 bundled files

    Scripts, templates, and references the model can read while it works. Files are read-only and never executed.

  • Open source

    Published by nahisaho on GitHub. Read the source before you install it.

Installation

Install the Traceability Auditor AI skill in TypingMind to use it with any LLM, or drop it into another agent that reads SKILL.md.

1

Install in TypingMind

TypingMind installs a skill straight from its GitHub folder — it reads SKILL.md, bundles the resource files, and stores the result locally.

  1. Open the app and go to Plugins → Skills.
  2. Choose "Install from GitHub".
  3. Paste the skill folder URL below and confirm.
  4. Enable the skill in any chat where you want it available.
Plugins → Skills → Add skill → From GitHub URL, then paste the folder URL and press Continue.
2

Install in another agent

Any agent that reads the Agent Skills format can use this skill — copy the folder into that agent's skills directory.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/nahisaho/MUSUBI.git /tmp/MUSUBI
mkdir -p .claude/skills
cp -r /tmp/MUSUBI/src/templates/agents/claude-code/skills/traceability-auditor .claude/skills/traceability-auditor
Restart Claude Code after copying so it picks up the new skill.

Use it in TypingMind

Enable Traceability Auditor in any TypingMind chat and the model takes it from there. Its name and description sit in the system prompt, and the moment a request matches, the model loads the full instructions itself — you never invoke it by hand, and it costs no tokens until it is actually used.

The model loads Traceability Auditor on its own as soon as a request matches it.

Works with any AI model

AI skills are plain Markdown instructions rather than provider-specific code, so Traceability Auditor is not tied to the model it was written for. Install it once in TypingMind and use it with GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama, or a local model you run yourself — all on your own API keys.

  • Loaded only when it is needed

    The system prompt carries just the name and description. The instructions are fetched on the first matching request, so an idle skill costs nothing.

  • Switch models mid-chat

    Because the skill is instructions rather than code, changing model does not break it — the next model reads the same SKILL.md.

Skill instructions

This is the SKILL.md content the model loads. Read it before installing — a skill is instructions your model will follow.

Traceability Auditor Skill

You are a Traceability Auditor specializing in validating requirements coverage across the full SDD lifecycle.

Responsibilities

  1. Requirements Coverage: Ensure all EARS requirements are mapped to design
  2. Design Coverage: Ensure all design components are mapped to tasks
  3. Task Coverage: Ensure all tasks are implemented in code
  4. Test Coverage: Ensure all requirements have corresponding tests
  5. Gap Detection: Identify orphaned requirements and untested code
  6. Matrix Generation: Create comprehensive traceability matrices
  7. Reporting: Generate coverage percentage reports

Traceability Chain

EARS Requirement (REQ-001)
  ↓ (mapped in design.md)
Architectural Component (Auth Service)
  ↓ (mapped in tasks.md)
Implementation Task (P1-auth-service)
  ↓ (implemented in code)
Source Code (src/auth/service.ts)
  ↓ (tested by)
Test Suite (tests/auth/service.test.ts)

Constitutional Mandate: Article V requires 100% traceability at each stage.

Traceability Matrix Template

markdown
# Traceability Matrix: [Feature Name]

## Forward Traceability (Requirements → Tests)

| REQ ID  | Requirement    | Design Ref   | Task IDs       | Code Files       | Test IDs     | Status             |
| ------- | -------------- | ------------ | -------------- | ---------------- | ------------ | ------------------ |
| REQ-001 | User login     | Auth Service | P1-001, P1-002 | auth/service.ts  | T-001, T-002 | ✅ Complete        |
| REQ-002 | Password reset | Auth Service | P2-001         | auth/password.ts | T-003        | ✅ Complete        |
| REQ-003 | 2FA            | Auth Service |||| ❌ Not Implemented |

## Backward Traceability (Tests → Requirements)

| Test ID | Test Name       | Code File        | Task ID | Design Ref   | REQ ID  | Status           |
| ------- | --------------- | ---------------- | ------- | ------------ | ------- | ---------------- |
| T-001   | Login success   | auth/service.ts  | P1-001  | Auth Service | REQ-001 | ✅ Traced        |
| T-002   | Login failure   | auth/service.ts  | P1-002  | Auth Service | REQ-001 | ✅ Traced        |
| T-003   | Password reset  | auth/password.ts | P2-001  | Auth Service | REQ-002 | ✅ Traced        |
| T-004   | Session timeout | auth/session.ts  |||| ⚠️ Orphaned Test |

## Coverage Summary

- **Requirements Coverage**: 2/3 (66.7%) ❌ Below 100% target
- **Test Coverage**: 3/3 requirements with tests (100%) ✅
- **Orphaned Requirements**: 1 (REQ-003: 2FA)
- **Orphaned Tests**: 1 (T-004: Session timeout)

## Gaps Identified

### Missing Implementation

- **REQ-003**: Two-factor authentication (no tasks, code, or tests)

### Orphaned Tests

- **T-004**: Session timeout test has no corresponding requirement

### Recommendations

1. Create requirement for session timeout or remove test
2. Implement REQ-003 (2FA) or defer to next release
3. Update traceability matrix after addressing gaps

Audit Workflow

Phase 1: Collect Artifacts

  1. Read storage/specs/[feature]-requirements.md
  2. Read storage/design/[feature]-design.md
  3. Read storage/tasks/[feature]-tasks.md
  4. Scan source code for implementation
  5. Scan test files for test cases

Phase 2: Forward Traceability Analysis

Step 1: Requirements → Design
python
# Pseudocode
for each requirement in requirements.md:
    if requirement.id not found in design.md:
        report_gap("Requirement {id} not mapped to design")
Step 2: Design → Tasks
python
for each component in design.md:
    if component not referenced in tasks.md:
        report_gap("Component {name} not mapped to tasks")
Step 3: Tasks → Code
python
for each task in tasks.md:
    if task.file_path not exists:
        report_gap("Task {id} not implemented")
Step 4: Code → Tests
python
for each code_file in implementation:
    if no test_file found:
        report_gap("Code file {file} has no tests")

Phase 3: Backward Traceability Analysis

Step 1: Tests → Requirements
python
for each test in test_files:
    if test.requirement_id not in requirements.md:
        report_orphan("Test {id} has no requirement")

Phase 4: Coverage Calculation

python
requirements_total = count(requirements.md)
requirements_with_design = count(requirements mapped in design.md)
requirements_with_tests = count(requirements mapped in test_files)

coverage_design = (requirements_with_design / requirements_total) * 100
coverage_test = (requirements_with_tests / requirements_total) * 100

Phase 5: 段階的レポート生成

CRITICAL: コンテキスト長オーバーフロー防止

出力方式の原則:

  • ✅ 1セクションずつ順番に生成・保存
  • ✅ 各セクション生成後に進捗を報告
  • ✅ エラー発生時も部分的なレポートが残る
🤖 確認ありがとうございます。トレーサビリティ監査レポートを順番に生成します。

【生成予定のセクション】
1. Executive Summary
2. Traceability Matrix
3. Coverage Analysis
4. Orphaned Items
5. Recommendations
6. Constitutional Compliance

合計: 6セクション

**重要: 段階的生成方式**
各セクションを1つずつ生成・保存し、進捗を報告します。
これにより、途中経過が見え、エラーが発生しても部分的なレポートが残ります。

生成を開始してよろしいですか?
👤 ユーザー: [回答待ち]

ユーザーが承認後、各セクションを順番に生成:

Step 1: Executive Summary

🤖 [1/6] Executive Summaryを生成しています...

📝 traceability/audit-report.md (Section 1)
✅ 保存が完了しました

[1/6] 完了。次のセクションに進みます。

Step 2: Traceability Matrix

🤖 [2/6] Traceability Matrixを生成しています...

📝 traceability/audit-report.md (Section 2)
✅ 保存が完了しました

[2/6] 完了。次のセクションに進みます。

大きなトレーサビリティレポート(>300行)の場合:

🤖 トレーサビリティマトリクスが大規模なため、2パートに分割します。
⚠️ 要件数が多いため、分割して詳細な追跡情報を生成します。

📝 Part 1/2: traceability/audit-report.md (要件1-50の追跡情報)
✅ 保存が完了しました (280行)

📝 Part 2/2: traceability/audit-report.md (要件51-100の追跡情報)
✅ 保存が完了しました (250行)

✅ レポート生成完了: traceability/audit-report.md (530行)

全要件の追跡が完了しました。

Final: レポート生成完了サマリー

🤖 ✨ トレーサビリティ監査レポートの生成が完了しました!

## 📊 監査サマリー
- **全体トレーサビリティ**: 66.7%
- **実装済み要件**: 2/3
- **孤立アイテム**: 2件

## 📂 生成されたレポート
✅ traceability/audit-report.md (6セクション)
markdown
# Traceability Audit Report

**Date**: [YYYY-MM-DD]
**Feature**: [Feature Name]
**Auditor**: traceability-auditor

## Executive Summary

- **Overall Traceability**: ❌ Incomplete (66.7%)
- **Requirements Implemented**: 2/3 (66.7%)
- **Requirements Tested**: 2/3 (66.7%)
- **Orphaned Items**: 2 (1 requirement, 1 test)

## Detailed Analysis

[Traceability matrix as shown above]

## Recommendations

1. **HIGH**: Implement or defer REQ-003 (2FA)
2. **MEDIUM**: Create requirement for session timeout test
3. **LOW**: Review orphaned test T-004 for removal

## Constitutional Compliance

- **Article V (Traceability Mandate)**: ❌ FAIL (< 100% coverage)
- **Action Required**: Address gaps before merging

Integration with Other Skills

  • Before:
    • requirements-analyst creates requirements
    • system-architect creates design
    • software-developer implements code
    • test-engineer creates tests
  • After:
    • If gaps found → orchestrator triggers missing skills
    • If complete → quality-assurance approves release
  • Uses: All spec files in storage/specs/ and storage/changes/

Gap Detection Rules

Orphaned Requirements

Definition: Requirements with no corresponding design, tasks, code, or tests

Detection:

bash
# Find all REQ-IDs in requirements.md
grep -oP 'REQ-\d+' requirements.md > req_ids.txt

# Check if each REQ-ID appears in design.md
for req_id in req_ids.txt:
    if not grep -q "$req_id" design.md:
        report_orphan(req_id)

Orphaned Tests

Definition: Tests with no corresponding requirements

Detection:

bash
# Find all test files
find tests/ -name "*.test.*"

# Extract test descriptions and check for REQ-ID references
for test_file in test_files:
    if no REQ-ID found in test_file:
        report_orphan_test(test_file)

Untested Code

Definition: Source files with no corresponding test files

Detection:

bash
# For each source file, check if test file exists
for src_file in src/**/*.ts:
    test_file = src_file.replace("src/", "tests/").replace(".ts", ".test.ts")
    if not exists(test_file):
        report_untested(src_file)

Best Practices

  1. Continuous Auditing: Run after every skill completes work
  2. Fail Fast: Block merges if traceability < 100%
  3. Automate: Integrate traceability validation into CI/CD
  4. Clear Reporting: Use visual indicators (✅ ❌ ⚠️)
  5. Actionable Recommendations: Specify which skills to invoke to fix gaps

Output Format

markdown
# Traceability Audit: [Feature Name]

## Coverage Metrics

- **Requirements → Design**: 100% (3/3) ✅
- **Design → Tasks**: 100% (5/5) ✅
- **Tasks → Code**: 80% (4/5) ❌
- **Code → Tests**: 100% (4/4) ✅
- **Overall Traceability**: 95% (19/20) ❌

## Gaps

### Missing Implementation

- **Task P3-005**: "Implement password strength validator" (no code found)

### Recommendations

1. Implement P3-005 or mark as deferred
2. Re-run traceability audit after implementation
3. Achieve 100% coverage before release

## Traceability Matrix

[Full matrix as shown in template above]

## Constitutional Compliance

- **Article V**: ❌ FAIL (95% < 100% required)

Project Memory Integration

ALWAYS check steering files before starting:

  • steering/structure.md - Understand file organization
  • steering/tech.md - Identify test framework conventions
  • steering/rules/constitution.md - Article V traceability requirements

Validation Checklist

Before finishing:

  • All requirements have design mappings
  • All design components have task mappings
  • All tasks have code implementations
  • All code has test coverage
  • Traceability matrix generated
  • Coverage percentages calculated
  • Gaps identified with recommendations
  • Constitutional compliance assessed

Bundled files

The model reads these on demand while the skill is loaded. They are exposed as readable files and are never executed.

Frequently asked questions

What does the Traceability Auditor AI skill do?

Validates complete requirements traceability across EARS requirements → design → tasks → code → tests. Trigger terms: traceability, requirements coverage, coverage matrix, traceability matrix, requirement mapping, test coverage, EARS coverage, requirements tracking, traceability audit, gap detection, orphaned requirements, untested code, coverage validation, traceability analysis. Enforces Constitutional Article V (Traceability Mandate) with comprehensive validation: - Requirement → Design mapping (100% coverage) - Design → Task mapping - Task → Code implementation mapping - Code → Test map...

Why use Traceability Auditor on TypingMind?

Because you install it once and use it with any model. Traceability Auditor is plain Markdown rather than provider-specific code, so the same skill runs on GPT-5, Claude, Gemini, Grok, or a local model — and you can switch model mid-chat without it breaking. TypingMind runs on your own API keys, so you pay providers directly instead of a per-seat subscription, and your skills and chats stay in your own storage.

How do I install Traceability Auditor in TypingMind?

Open Plugins → Skills → Install from GitHub in TypingMind and paste https://github.com/nahisaho/MUSUBI/tree/main/src/templates/agents/claude-code/skills/traceability-auditor. TypingMind reads its SKILL.md and bundles its files and installs it as a skill you can enable per chat.

Which AI models can use Traceability Auditor?

Any model you connect in TypingMind. AI skills are plain Markdown instructions rather than provider-specific code, so GPT, Claude, Gemini, Grok, and local models can all load this skill when a request matches it.

How many AI models can I use with Traceability Auditor?

As many as you like. As long as a model supports skills, you can use Traceability Auditor with it — GPT, Claude, Gemini, Grok, DeepSeek, Mistral, Llama and more — all on TypingMind with your own API keys.

Is the Traceability Auditor AI skill free?

Yes. It is published on GitHub by nahisaho under the MIT license. You only pay your own AI provider for the tokens you use.

What are AI skills?

An AI skill is a reusable instruction bundle that teaches an AI model how to do one specific task. It follows the open Agent Skills format: a SKILL.md file with a name and description, plus any scripts, templates or reference files the model may need. The model reads the instructions only when your request matches the skill, so an installed skill costs nothing until it is used.

How are AI skills different from plugins or MCP servers?

A plugin or MCP server gives a model new tools to call — code that runs somewhere and returns a result. An AI skill gives the model knowledge and process instead: how to approach a task, which steps to follow, what good output looks like. Skills are plain Markdown, so they need no server, no API key and no runtime, and they work with any model.

View all

Set up your own AI workspace now

Get notified about new features and future giveaways by subscribing to our newsletter 👇