ia-database-guardian

ia-database-guardian is an agent for Claude Code from iliaal/whetstone. It costs 41 tokens per session (2,802 once invoked), scanned A, original, MIT.

A database review agent that checks schemas, constraints, migrations, data mappings, and persistent-data changes for safety. A migration is a change to a database's structure or stored data.

In plain words
What is it for?
Use it to review database migrations, models, ID conversions, enum changes, backfills, constraints, transaction boundaries, and data-privacy handling.
Why use it?
It helps catch changes that could corrupt data, break production assumptions, or leave privacy-related copies without deletion or export paths.

Agent for Claude Code

Written for Claude Code: a Claude Code subagent (agents/*.md). Also seen: model in frontmatter.

Part of the whetstone plugin — 3 commands, 19 agents, 1 MCP server shipped together

Good fit Use it to review database migrations, models, ID conversions, enum changes, backfills, constraints, transaction boundaries, and data-privacy handling.

Compare 6 agents from other repositories ↓
Install with agentmods
npx agentmods add agents/iliaal/whetstone/ia-database-guardian
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/iliaal/whetstone

Made for: Claude Code.

Or install whetstone, the plugin that ships this one along with the rest of its 3 commands, 19 agents, 1 MCP server.

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 ia-database-guardian

README.md
[![agentmods](https://agentmods.dev/badge/agents/iliaal/whetstone/ia-database-guardian.svg)](https://agentmods.dev/agents/iliaal/whetstone/ia-database-guardian)
Your own site
<a href="https://agentmods.dev/agents/iliaal/whetstone/ia-database-guardian"><img src="https://agentmods.dev/badge/agents/iliaal/whetstone/ia-database-guardian.svg" alt="Measured on agentmods" height="20"></a>
Per session 41 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 2,802 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.00041 $0.02802
Opus 5 $0.00020 $0.01401
Sonnet 5 $0.00008 $0.00560
Haiku 4.5 $0.00004 $0.00280

Measured 8d ago against content hash 5879716e1e69, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-07, from the pricing page.

Security

Grade A, and why

ia-database-guardian 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 8d 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.

plugins/whetstone/agents/ia-database-guardian.md · 215 lines

How it starts

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

Protect data integrity, ensure migration safety, validate migration code against production reality, and check that the schema supports the data-privacy obligations it is subject to (GDPR, CCPA) -- classification, retention, and a deletion and export path that reaches every copy. Process-level privacy compliance (consent capture, DPAs, vendor sharing) is out of scope; see Phase 1 section 6.


Phase 1: Schema & Constraints Review

Review the structural rules that protect data. Focus on schema design, constraints, transaction boundaries, and privacy compliance.

Read the full file on GitHub · 215 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. 8d ago First seen · 215 lines · 41 tokens per session scan A 5879716e1e69

Subscribe to this mod's changes

ia-database-guardian is an agent published in the GitHub repository iliaal/whetstone (33 stars, last pushed yesterday), licensed MIT. It adds 41 tokens to every session and 2,802 once invoked, about $0.0002 per session on Opus 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-30.

Related

Other agents, from other repositories

data-engineer

Adversarial data and database engineer who assumes the design is mis-normalized and indexed for a workload that does not exist. Audits schemas, migrations, queries, ORM code, document shapes, stream contracts, and pipelines against normalization, dimensional modeling, key-value access patterns, columnar and…

testdouble/han · 216 tokens

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

reviewer-data-integrity

Use this agent when you need to review database migrations, data models, or any code that manipulates persistent data. This includes checking migration safety, validating data constraints, ensuring transaction boundaries are correct, and verifying that referential integrity and privacy requirements are maintained.…

wsauret/flywheel · 253 tokens

verifier

Use this agent when verifying that implementation meets success criteria, validating phase completion, checking plan coverage before execution, or performing pre-ship validation. Examples: Context: A phase has been fully built and reviewed, and needs final verification before moving on. user: "Verify that the database…

lgbarn/shipyard · 278 tokens