@senda-labs/audit
ARun complete system health audit of DQIII8 — checks DB integrity, agent performance, pipeline connections, error log, and services. Produces a scored Markdown report.
Install
agr install @senda-labs/audit --target claudeWrites 1 file into .claude/skills/, pinned to git-3be020b3.
- .claude/skills/audit/SKILL.md
Document
name: audit description: Run complete system health audit of DQIII8 — checks DB integrity, agent performance, pipeline connections, error log, and services. Produces a scored Markdown report. command: /audit allowed-tools: [Bash, Read, Grep] user-invocable: true auto-invoke:
- when: "7+ days since last audit OR 3+ unresolved errors detected in session" action: "Run /audit automatically to surface problems"
/audit -- System Health Audit
Triggers the auditor agent to analyze database/dqiii8.db and produce a structured health report.
Usage
/audit
/audit --period 30d # analyze last 30 days instead of default 7
/audit --agent python-specialist # scope to one agent
What it does
- Queries all metric tables:
agent_actions,error_log,sessions,skill_metrics - Uses views
agent_performanceanderror_keywords_freq - Computes an overall health score (0-100)
- Writes a Markdown report to
database/audit_reports/audit-YYYY-MM-DD-HH.md - Inserts a summary row in the
audit_reportstable - Prints a one-line summary to the terminal
Output
[AUDIT] Score: 87/100 | Actions: 106 | Success: 100.0% | Failures: 0 | Unresolved errors: 0
Report: database/audit_reports/audit-2026-03-11-14.md
Score interpretation
| Score | Status | Cadencia recomendada |
|---|---|---|
| > 80 | HEALTHY | next audit in 7 days |
| 60-80 | WARNING | next audit in 3 days |
| < 60 | CRITICAL | next audit in 1 day, notify user |
Auto-trigger
The stop.py hook automatically triggers /audit when 7+ days have passed since the last report in audit_reports. Also auto-invoked when errors accumulate during a session.
Agent
Handled by: .claude/agents/auditor.md
Model: claude-sonnet-4-6
Trustgrade A
- passBody integrity
Whether the stored document is plausibly the kind of file the artifact declares, rather than something fetched by mistake.
- passType matchnot applicable to this artifact type
Whether the artifact is really the kind of thing its metadata claims it is.
- passFreshness
How long since the source repository was last pushed to.
- passPrompt injection
Scans the artifact's own text for instructions aimed at your agent rather than at you.
- passLicense
Whether the source repository declares an SPDX license permissive enough to redistribute.
How the grade is calculated
Each check contributes 0 points when it passes, 1 when it warns, and 2 when it fails. The total maps to a letter:
- Aevery check passed
- Bone warning
- Ctwo warnings
- Dprompt injection or body integrity failed, or three warnings
- Fone of those failed, and something else is wrong
These are automated hygiene checks, not a security audit, and not a dependency or vulnerability scan. A grade of A means nothing was flagged — not that the artifact is safe.
Versions
git-3be020b3d0652026-07-31