database-design

Design relational database schemas with normalization, key, and indexing guidance.

3|2|Updated Feb 27, 2026
One-click install
npx skills add https://github.com/grasberg/sofia --skill database-design-grasberg
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: database-design
Source: https://github.com/grasberg/sofia/tree/main/cmd/sofia/internal/onboard/antigravity-kit/.agent/skills/database-design
Command: npx skills add https://github.com/grasberg/sofia --skill database-design-grasberg

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) components.

What problem does it solve?

This skill helps you design robust, scalable database schemas by providing structured guidance on normalization strategies, keys, relationships, and indexing choices to prevent common data-model pitfalls.

Core Features & Use Cases

  • Guidance on normalization vs denormalization and when to apply each.
  • Decision support for primary keys, foreign keys, timestamps, and relationship modeling.
  • Practical examples for common app domains (e.g., user/post, e-commerce catalog and orders) and guidance on ORM selections.

Quick Start

Describe your data entities, queries, and performance goals, and I will draft a clean, scalable schema with recommended keys and indexes.

Frequently Asked Questions about database-design

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

FAQPage Schema
How do I design a scalable database schema for an e-commerce catalog and orders?

Designing a scalable database schema requires applying principled guidelines for normalization, primary keys, and indexing. This prevents common data-model pitfalls by enforcing practical rules for structuring e-commerce entities like catalogs and orders.

When should I use normalization vs denormalization in data modeling?

Use normalization vs denormalization based on your specific queries and performance goals. This skill provides structured decision support to determine when to apply each strategy, ensuring your relational schema scales without unnecessary complexity.

How do I model one-to-many vs many-to-many relationships in a relational database?

To model one-to-many vs many-to-many relationships, you use appropriate foreign keys and junction tables. The skill enforces practical rules for relationship modeling, ensuring your relational database schema accurately maps data dependencies.

What's the best way to choose indexes and primary keys for database performance?

The best way to choose indexes and primary keys is by analyzing query patterns and performance goals. The skill provides decision support for key choices and indexing strategies, applying practical checks to determine exactly when to index columns.

How do I evolve database schemas safely without breaking existing ORM mappings?

To evolve database schemas safely, you apply practical rules that consider ORM selections and existing data structures. This approach ensures schema changes maintain data integrity and prevent breaking object-relational mapping dependencies.