Skip to content

slight76/data-standards

v1.0.1MIT

Team data standards for developers and AI agents: database design, naming, Postgres, migrations, persistence, caching, backup and restore

data-standards

Team data standards for developers and AI agents: database design, naming, PostgreSQL, migrations, persistence, caching, backup and restore. The reference stack is PostgreSQL with .NET and EF Core, hosted on Fly.io.

Part of the Slight76 standards handbooks indexed at standards-marketplace. Written for a small team and its AI agents.

Documents

DocumentCoversRule prefixes
Database architectureStore ownership, logical/physical design scope, migrations, least-privilege identities, RPO/RTO and restore evidenceDB
Logical and physical database designStorage selection, naming and types, constraints, tenant and lifecycle design, derived stores, design evidenceDB
Database naming conventionssnake_case identifiers, plural tables, column and constraint/index name patterns, timestamps, enums, schemas, EF Core mappingNAME
PostgreSQL anti-patterns and preferred alternativesReview checklist: column types, missing FK indexes, soft delete, JSONB, N+1, SELECT *, IN lists, OFFSET pagination, long transactions, locking migrationsPGX
Schema delivery and recoveryMigration workflow, expand/contract, rollback versus recovery, backup strategy and restore exercises, runbook stepsMIG, DR
Persistence, transactions, and query behaviorEF Core defaults, transactions and isolation, concurrency tokens, query discipline, parameterization, integration tests on the real engineDATA
Cache selection, ownership, and invalidationWhen to add a cache, key scoping, invalidation and stampede control, failure behavior, Redis for non-cache dutiesCACHE
Backup verification and restore runbookpg_dump/pg_restore and Fly Postgres commands, quarterly restore drill, cadence, evidence record, production restore steps(verifies DB, DR)

Read by task

See skills/data-standards/SKILL.md.

Install as an agent skill

AgentCommand
Copilot CLIcopilot plugin marketplace add Slight76/standards-marketplace then copilot plugin install data-standards@slight76-standards
GitHub CLI (any agent)gh skill install Slight76/data-standards data-standards --scope user --pin v1.0.0
Claude Code/plugin marketplace add Slight76/standards-marketplace then /plugin install data-standards@slight76-standards

Layout

PathPurpose
docs/Standards documents (frontmatter, applies-when, rule table)
catalog/catalog.jsonMachine-readable rules; externalDecisions points at historic ADRs
adr/Decisions local to this handbook
skills/data-standards/Agent skill and references
CHANGELOG.mdRelease notes, including where each moved document came from

Validation: py ../standards-marketplace/tooling/validate.py --root .. License: MIT.