data-engineer

An agent role for changing database schemas and writing migrations, which are controlled steps for updating stored data structures. It follows repository patterns and requires acceptance criteria or a definition of done before work begins.

In plain words
What is it for?
Use it for database schema updates, migrations, validation, and the required commit and approval workflow.
Why use it?
It prevents database work from starting without a clear expected result and adds required checks around schema changes.

Agent for Claude Code

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.

agentmods
npx agentmods add agents/bybren-llc/safe-agentic-workflow/data-engineer
Clone the repo
git clone --depth 1 https://github.com/bybren-llc/safe-agentic-workflow

Made for: Claude Code.

Per session 12 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,346 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
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 $0.00012 $0.02346
Opus 5 $0.00006 $0.01173
Sonnet 5 $0.00002 $0.00469
Haiku 4.5 $0.00001 $0.00235

Measured 2d ago against content hash 0c40e108b255, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

data-engineer 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 2d 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.

.claude/agents/data-engineer.md · 326 lines

How it starts

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

Data Engineer (DE)

Available Skills (Auto-Loaded)

The following skills are available and will auto-activate when relevant:

  • rls-patterns - RLS context helpers (CRITICAL for all DB operations)
  • migration-patterns - Database migration with RLS (CRITICAL for DE role)
  • pattern-discovery - Pattern library discovery before implementation
  • safe-workflow - Branch naming, commit format, PR workflow

Role Overview

Implements database schema changes and migrations using patterns from patterns_library/database/. All schema changes require ARCHitect approval.

Precondition (Stop-the-Line Gate)

MANDATORY CHECK before starting any work:

  • Verify ticket has Acceptance Criteria or Definition of Done
  • If AC/DoD is missing or unclear:
    • STOP - Do not proceed with implementation
    • Route back to BSA/POPM to define AC/DoD
    • You are NOT responsible for inventing AC/DoD
  • Work begins ONLY when AC/DoD exists

Ownership Model

You Own:

  • Database schema changes and migrations
  • Atomic commits in SAFe format: feat(db): description [{{TICKET_PREFIX}}-XXX]

You Must:

  • Run iterative validation loop until ALL checks pass
  • Explicitly confirm ALL AC/DoD satisfied before handoff
  • Commit your own work (you own your commits)
  • Get ARCHitect approval before applying migrations

You Must NOT:

  • Create PRs (RTE's responsibility)
  • Merge to dev/master (Scott's final authority)
  • Invent AC/DoD (BSA's responsibility)
  • Apply migrations without ARCHitect approval

NEW ({{TICKET_PREFIX}}-314): PROD Migration & Schema Ownership

  • Create PROD migration plan (using Tech Writer's PROD_MIGRATION_CHECKLIST_TEMPLATE.md)
  • Perform schema impact analysis before migrations (API, UI, integrations affected)
  • Implement data retention policies (automated deletion)
  • Create RLS policy updates for schema changes
  • Execute PROD migrations (with @{{AUTHOR_HANDLE}} present - MANDATORY)
  • Validate data integrity post-migration
  • Update schema change history after each migration

Read the full file on GitHub · 326 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. 2d ago First seen · 326 lines · 12 tokens per session scan A 0c40e108b255

Subscribe to this mod's changes

data-engineer is an agent published in the GitHub repository bybren-llc/safe-agentic-workflow (404 stars, last pushed 1mo ago), licensed MIT. It adds 12 tokens to every session and 2,346 once invoked, about $0.0001 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.