Schema

Design normalized database schemas, migration plans, and ER diagrams.

Updated Mar 18, 2026
One-click install
npx skills add https://github.com/Dinxeshh/agent-skills --skill schema-dinxeshh
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: Schema
Source: https://github.com/Dinxeshh/agent-skills/tree/main/skills/schema
Command: npx skills add https://github.com/Dinxeshh/agent-skills --skill schema-dinxeshh

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

This Skill handles database schema design, migration planning, and ER diagrams so teams can translate requirements into safe, normalized data models with clear integrity, index, and rollback guidance.

Core Features & Use Cases

  • Model: Document tables, PK/FK, and normalization rationale after analyzing requirements and reference guidance before proposing schema changes.
  • Migrate: Sequence schema operations with rollback notes, lock-risk assessments, and expand-contract staging when needed, honoring constraints from the migration patterns references.
  • Validate: Recommend indexes tied to query patterns, note delete behaviors, and align ORM or visualization handoffs while respecting the schema boundaries provided.
  • Use Case: When launching a new service or changing payloads, Schema ensures the resulting PostgreSQL/MySQL/SQLite/Mongo patterns stay consistent, indexed, and reversible.

Quick Start

Ask Schema to design the normalized tables, foreign keys, indexes, and reversible migration steps for the new billing domain.

Frequently Asked Questions about Schema

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I design a normalized database schema with primary and foreign key constraints?

Designing a normalized database schema involves documenting tables, primary and foreign keys, and normalization rationale after analyzing requirements. This ensures structured data domains maintain integrity through explicit PK/FK constraints and defined delete behaviors.

What is the best way to sequence database migrations and handle rollbacks?

Sequencing database migrations requires ordering schema operations with explicit rollback notes, lock-risk assessments, and expand-contract staging. This approach honors constraints from migration patterns to keep PostgreSQL, MySQL, SQLite, or MongoDB changes reversible.

How do I plan an index strategy tied to specific query patterns?

Planning an index strategy involves recommending indexes tied to query patterns and noting delete behaviors. This aligns ORM or visualization handoffs while respecting schema boundaries to optimize data retrieval for structured domains.

Does this database schema design approach work for both SQL and MongoDB patterns?

Yes, this database schema design approach works for PostgreSQL, MySQL, SQLite, and MongoDB patterns. It translates requirements into safe, normalized data models with clear integrity, index, and rollback guidance across these database systems.

When do I need to use expand-contract staging for database migrations?

You need expand-contract staging for database migrations when changing payloads or schema operations to prevent lock risks. It sequences changes incrementally, ensuring constraints are honored and providing explicit rollback or backup notes.