Skip to content
Back to skills

Data Audit

ASecurity

Report on data completeness for the SPARTA QRA pipeline (Control -> URL -> Knowledge -> QRA). Queries DuckDB to show coverage percentages at each stage.

  • 6 stars
  • 0 votes
  • 0 copies
  • 3 views
  • Added September 11, 2026
devopsgobash

Security analysis

A100/100

Pro scans all 5 files and shows the line behind each finding

Scanned September 11, 2026

npx -y skills add grahama1970/agent-skills --skill data-audit --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Data Audit?

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

Security grade badge for Data Audit
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/grahama1970-data-audit/badge)](https://www.skillsdirectory.com/skills/grahama1970-data-audit)

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: data-audit
description: >
  Report on data completeness for the SPARTA QRA pipeline (Control -> URL -> Knowledge -> QRA).
  Queries DuckDB to show coverage percentages at each stage.
triggers:
  - audit sparta
  - check coverage
  - data completeness
  - pipeline status
metadata:
  short-description: SPARTA data completeness auditor.
  project-path: ${HOME}/workspace/experiments/pi-mono/.agent/skills/data-audit

provides:
  - data-audit
composes:
  - create-figure
  - task-monitor
  - agentic-evals
disciplines:
  - data-engineering
  - evaluation-quality
---

# Data Audit

Audits the SPARTA pipeline data coverage.

## Usage

```bash
# Run full audit
.agent/skills/data-audit/run.sh

# Run for specific run ID (points to specific DB path if needed)
.agent/skills/data-audit/run.sh --run-id <run-id>
```

## Logic

Connects to SPARTA DuckDB and calculates coverage for:

1. **Controls**: Base set.
2. **URLs**: Controls mapped to at least one URL.
3. **Knowledge**: Controls mapped to URLs that have extracted chunks.
4. **QRA**: Controls that have generated QRA pairs.

## Visualization

After generating coverage data, offer to visualize via `/create-figure`:

```bash
# Pipeline coverage as stacked bar chart
create-figure metrics --input audit.json --output coverage.png --type bar --title "SPARTA Pipeline Coverage"

# Coverage heatmap by category
create-figure heatmap --input audit.json --output coverage-heatmap.png
```

**When to offer:** After presenting coverage percentages, ask: "Want me to chart the pipeline coverage?"

## Common Mistakes

### WRONG: Running audit without a DuckDB path when needed
```bash
./run.sh  # may fail if DuckDB path is not configured
```

### RIGHT: Specify run ID or verify default DB path
```bash
./run.sh --run-id <run-id>  # explicit run
```

### WRONG: Reporting raw counts without coverage percentages
```
Controls: 800, URLs: 500, QRAs: 200  # raw numbers are meaningless
```

### RIGHT: Report coverage ratios at each pipeline stage
```
Controls: 800 → URLs: 500 (62.5%) → Knowledge: 350 (43.8%) → QRA: 200 (25.0%)
```

### WRONG: Not visualizing results for stakeholder communication
```bash
./run.sh  # text output only, hard to share
```

### RIGHT: Generate charts via /create-figure after audit
```bash
./run.sh > audit.json
create-figure metrics --input audit.json --output coverage.png --type bar
```

Files in this skill

  • SKILL.md2.3 KB
  • audit.py10.4 KB
  • fixtures/agentic_eval.json488 B
  • pyproject.toml247 B
  • sanity.sh1.8 KB

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.

Comments

Loading comments…

Newsletter

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