agentleFS
pecigonzalopecigonzalo/agent-skills/skills/role-data-engineer/SKILL.md

role-data-engineer

Skill0 starsChanged 4 months agoMITView on GitHub

Use this skill for data pipelines, ETL and ELT design, analytics schemas, event design, warehouse models, data quality checks, batch and streaming jobs, or data migrations and backfills, even when the user only describes moving or aggregating data. Use standards-database for transactional schema, query, and migration mechanics.

1 other project uses a version of this.

Adopted by

Most recently taken up by

The file

We split this skill into the rules it gives an agent

11 rules. About 0 are common, 11 are distinctive, and 0 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈11

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 0

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Prefer idempotent writes and checkpointed progress

    line 14
  2. Distinctive:

    Treat backfills as production changes

    line 16
  3. Distinctive:

    Write the grain down in the schema documentation, then verify it with a uniqueness check on the key that expresses it.

    line 32
  4. Distinctive:

    Event time: when the thing happened in the source system.

    line 38
  5. Distinctive:

    Ingestion time: when the pipeline received it.

    line 39
  6. Distinctive:

    Processing time: when the pipeline wrote it.

    line 40
  7. Distinctive:

    Before shipping, know how to reprocess history: the batch boundaries, the resume point, the expected runtime, and how the backfill …

    line 66
  8. Distinctive:

    Treat a backfill like a production deploy, because it writes to production data.

    line 88
  9. Distinctive:

    Know the correction path: If the backfill writes wrong values, state in advance how to detect it and how to revert.

    line 94
  10. Distinctive:

    Do not run an unbounded backfill against a table that consumers are reading live without an explicit decision to accept that risk.

    line 96
  11. Distinctive:

    Before finalizing data work:

    line 102

≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Provides: Pipeline design workflow, grain and idempotency analysis, data quality check selection, and backfill planning.

Quick Reference

Golden Rule: Data jobs must be reproducible, observable, and safe to rerun

Default Stance:

  • Define grain and source of truth before schema details
  • Prefer idempotent writes and checkpointed progress
  • Make data quality failures visible before consumers find them
  • Treat backfills as production changes

Reference: skill:standards-database for schema, index, and migration mechanics


Design Workflow

1. Establish ownership

Name the source system, the owning team, the downstream consumers, the freshness expectation, and the retention period. A pipeline without a named consumer is a pipeline nobody will notice breaking.

2. Define the grain

State exactly what one row or one event represents. This is the single most common source of silent data bugs: a table whose grain is "one row per order" quietly becoming "one row per order line" doubles every revenue metric downstream.

Write the grain down in the schema documentation, then verify it with a uniqueness check on the key that expresses it.

3. Specify the schema

Decide keys, timestamps, nullability, enums, and versioning. Distinguish the timestamps explicitly:

  • Event time: when the thing happened in the source system.
  • Ingestion time: when the pipeline received it.
  • Processing time: when the pipeline wrote it.

Late-arriving data makes these diverge, and aggregations built on the wrong one will silently drift.

4. Plan ingestion

Decide how the job handles ordering, deduplication, retries, checkpoints, and late data before writing transformation logic:

  • What is the deduplication key, and is it stable across retries?
  • Where does progress get checkpointed, and what happens on resume?
  • How late can a record arrive and still be counted correctly?
  • What happens to records that arrive out of order?

5. Add data quality checks

Cover the four categories that catch most real failures:

  • Volume: row and event counts against an expected range, not just non-zero.
  • Uniqueness: the grain key has no duplicates.
  • Referential integrity: foreign keys resolve to existing dimension rows.
  • Ranges and nullability: values fall inside plausible bounds; required fields are populated.

Decide per check whether a failure should block downstream consumers or only alert. Silently publishing bad data is worse than publishing nothing.

6. Plan backfill and replay

Before shipping, know how to reprocess history: the batch boundaries, the resume point, the expected runtime, and how the backfill interacts with the ongoing incremental job.

7. Add observability

Emit lag, volume, error rate, freshness, and cost per run. Freshness is the metric consumers actually care about, and it is the one most often missing.


Pipeline Review

  • Ingestion is idempotent, or has a stable deduplication key
  • Partial failure resumes without duplicating or losing records
  • Partitioning matches both query patterns and backfill boundaries
  • Late, missing, duplicated, and out-of-order records are handled explicitly
  • Schema changes are additive or versioned, with a consumer migration plan
  • PII is classified, with masking, retention, and access controls defined
  • Reconciliation exists for financial, user-facing, or business-critical metrics

Backfill Safety

Treat a backfill like a production deploy, because it writes to production data.

  1. Bound it. Process a date range or partition at a time, never the full history in one transaction.
  2. Dry run. Compute the output for one partition and compare against the existing values before writing anything.
  3. Make it resumable. Record which partitions completed so an interrupted run does not restart from zero.
  4. Watch the load. A backfill competing with the incremental job for the same warehouse slots can delay fresh data for consumers.
  5. Know the correction path. If the backfill writes wrong values, state in advance how to detect it and how to revert.

Do not run an unbounded backfill against a table that consumers are reading live without an explicit decision to accept that risk.


Checklist

Before finalizing data work:

  • Grain, source of truth, freshness, and retention are explicit
  • Idempotency, retries, checkpoints, and late data are handled
  • Quality checks cover volume, uniqueness, ranges, and relationships
  • Each quality check has a defined failure action: block or alert
  • Backfills are bounded, resumable, observable, and have a correction plan
  • Observability covers lag, volume, error rate, freshness, and cost

Integration with Other Skills

With standards-database: design schemas, indexes, constraints, and migrations.

With standards-observability: instrument pipeline metrics, logs, and alerting.

With role-site-reliability-engineer: assess production backfill risk and warehouse capacity.

With standards-security: handle PII classification, access control, retention, and data sharing.

With standards-api-design: design event payloads and schema versioning for published streams.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.