data-integrity

data-integrity is an agent for Claude Code from vindm/dotclaude. It costs 74 tokens per session (1,478 once invoked), scanned A, original, MIT.

A read-only database audit agent that checks the actual stored data for broken relationships, incomplete records, stuck processing states, and tenant-isolation problems. It reports healthy areas, gaps, critical findings, examples, possible causes, and severity.

In plain words
What is it for?
Auditing production records for incomplete enrichment, orphaned references, stale state-machine rows, cross-tenant data leaks, and writes that appeared successful but were not saved.
Why use it?
It catches data problems that may remain hidden even when the code, tests, and visible user experience appear correct.

Agent for Claude Code

Written for Claude Code: effort in frontmatter. Also seen: model in frontmatter.

Good fit Auditing production records for incomplete enrichment, orphaned references, stale state-machine rows, cross-tenant data leaks, and writes that appeared successful but were not saved.

Compare 6 agents from other repositories ↓
Install with agentmods
npx agentmods add agents/vindm/dotclaude/data-integrity
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Clone the repo
git clone --depth 1 https://github.com/vindm/dotclaude

Made for: Claude Code.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for data-integrity

README.md
[![agentmods](https://agentmods.dev/badge/agents/vindm/dotclaude/data-integrity/github.svg)](https://agentmods.dev/agents/vindm/dotclaude/data-integrity)
Your own site
<a href="https://agentmods.dev/agents/vindm/dotclaude/data-integrity"><img src="https://agentmods.dev/badge/agents/vindm/dotclaude/data-integrity/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for data-integrity

Your own site · 80×15
<a href="https://agentmods.dev/agents/vindm/dotclaude/data-integrity"><img src="https://agentmods.dev/badge/agents/vindm/dotclaude/data-integrity.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 74 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 1,478 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00074 $0.01478
Opus 5.5 $0.00030 $0.00591
Sonnet 5.5 $0.00015 $0.00296
Haiku 4.5 $0.00007 $0.00148

Measured 1mo ago against content hash 40e11f65af95, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

data-integrity scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 1mo ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

deferred/agents/data-integrity.md · 76 lines

How it starts

The opening of the file, as written. The whole thing — 76 lines — stays where its author put it; the contents beside it link to each section on GitHub.

You catch the bugs where the code is correct and the data is wrong — latent corruption, drift, and orphans that accumulate over time in the actual production store. These don't surface in code review (the diff is fine), in unit tests (the test data is clean), or in user testing (the affected user doesn't notice, or quietly stops using a feature). They surface in a periodic data audit — or in a support ticket six months later. The classes you find: stuck-job orphans (a multi-stage pipeline row sitting at stage 3 with stage 4's marker missing), incomplete enrichment (records that should have N populated fields and have N−1 because a downstream step failed silently), orphaned references (a child row pointing at a deleted parent), cross-tenant leaks (a row owned by one tenant readable by another), stale state-machine markers (an "in-progress" row whose started_at is months old and nothing reaps it), and silent no-op writes (a write that returned success-shaped but never persisted — the audit catches the resulting absence).

Discover the project's DB access at runtime — FIRST

Before any query, determine how this project reaches its store, and use the cheapest path with explicit row caps:

  • Look for a connection string or DB config in the environment, the manifest, or config files (a psql-style URL, a database config block, an ORM connection).
  • Prefer the project's own DB CLI run via Bash — a psql-style client, the project's migration/query tool, or an ORM-backed script. Run read-only queries with explicit LIMIT bounds. Avoid any path that dumps large unbounded JSON.
  • Read the schema from migration files / schema definitions to learn the actual table and column names, which tables have pipelines or state machines, and how tenancy is enforced (row-level policies, query-time filtering, separate databases). Every query you run uses THIS project's real schema — never a query copied from elsewhere that references tables this project doesn't have.

If you cannot find a working DB access method, say so plainly and fall back to auditing what the schema/migration files reveal statically rather than guessing.

Read the full file on GitHub · 76 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 1mo ago First seen · 76 lines · 74 tokens per session scan A 40e11f65af95

Subscribe to this mod's changes

data-integrity is an agent published in the GitHub repository vindm/dotclaude (1 stars, last pushed 1mo ago), licensed MIT. It adds 74 tokens to every session and 1,478 once invoked, about $0.0003 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.

Related

Other agents, from other repositories

db-migration-reviewer

Database migration safety specialist. Activates when migrations/ files are detected in a PR or feature branch. Checks lock duration, rollback strategy, zero-downtime patterns, PII column handling, and index creation safety. Writes docs/migrations/MIGRATE-{slug}.md. Blocks deploy if no rollback path exists.

avelikiy/great_cto · 69 tokens

infra-provisioner

Provisions the real backing infrastructure for a Product-Builder product so it reaches a live URL — managed Postgres (Neon default), the hosting project (Vercel default), env/secret wiring, and the custom domain + DNS + TLS. Pairs with devops (which does preview/staging only and refuses prod/real-domain). Runs after…

avelikiy/great_cto · 137 tokens

app-scaffolder

Project-scaffolding builder that stands up a working base application from the pinned stack-baseline so senior-dev implements FEATURES, not boilerplate. Creates the Next.js + TypeScript + Tailwind/shadcn skeleton, wires Drizzle + Postgres, Auth.js (to the auth-engineer contract), env template, folder structure, CI…

avelikiy/great_cto · 137 tokens

refactor-expert

Code refactoring specialist focused on clean architecture, SOLID principles, and technical debt reduction. Use proactively for code quality improvements and architectural refactoring.

alirezarezvani/claude-code-tresor · 34 tokens

performance-tuner

Performance engineering specialist for application profiling, optimization, and scalability. Use proactively for performance issues, bottleneck analysis, and optimization tasks.

alirezarezvani/claude-code-tresor · 30 tokens

security-auditor

Security specialist for vulnerability assessment, secure authentication, and OWASP compliance. Use proactively for security reviews, auth flows, and vulnerability analysis.

alirezarezvani/claude-code-tresor · 32 tokens