database-design

Database design principles and decision-making. Schema design, indexing strategy, ORM selection, serverless databases.

65 stars

Best use case

database-design is best used when you need a repeatable AI agent workflow instead of a one-off prompt.

Database design principles and decision-making. Schema design, indexing strategy, ORM selection, serverless databases.

Teams using database-design should expect a more consistent output, faster repeated execution, less prompt rewriting.

When to use this skill

  • You want a reusable workflow that can be run more than once with consistent structure.

When not to use this skill

  • You only need a quick one-off answer and do not need a reusable workflow.
  • You cannot install or maintain the underlying files, dependencies, or repository context.

Installation

Claude Code / Cursor / Codex

$curl -o ~/.claude/skills/database-design/SKILL.md --create-dirs "https://raw.githubusercontent.com/One-Man-Company/Skills-ContextManager/main/MySkillsHUB/skills/database-design/skill.md"

Manual Installation

  1. Download SKILL.md from GitHub
  2. Place it in .claude/skills/database-design/SKILL.md inside your project
  3. Restart your AI agent — it will auto-discover the skill

How database-design Compares

Feature / Agentdatabase-designStandard Approach
Platform SupportNot specifiedLimited / Varies
Context Awareness High Baseline
Installation ComplexityUnknownN/A

Frequently Asked Questions

What does this skill do?

Database design principles and decision-making. Schema design, indexing strategy, ORM selection, serverless databases.

Where can I find the source code?

You can find the source code on GitHub using the link provided at the top of the page.

SKILL.md Source

# Database Design

> **Learn to THINK, not copy SQL patterns.**

## 🎯 Selective Reading Rule

**Read ONLY files relevant to the request!** Check the content map, find what you need.

| File | Description | When to Read |
|------|-------------|--------------|
| `database-selection.md` | PostgreSQL vs Neon vs Turso vs SQLite | Choosing database |
| `orm-selection.md` | Drizzle vs Prisma vs Kysely | Choosing ORM |
| `schema-design.md` | Normalization, PKs, relationships | Designing schema |
| `indexing.md` | Index types, composite indexes | Performance tuning |
| `optimization.md` | N+1, EXPLAIN ANALYZE | Query optimization |
| `migrations.md` | Safe migrations, serverless DBs | Schema changes |

---

## ⚠️ Core Principle

- ASK user for database preferences when unclear
- Choose database/ORM based on CONTEXT
- Don't default to PostgreSQL for everything

---

## Decision Checklist

Before designing schema:

- [ ] Asked user about database preference?
- [ ] Chosen database for THIS context?
- [ ] Considered deployment environment?
- [ ] Planned index strategy?
- [ ] Defined relationship types?

---

## Anti-Patterns

❌ Default to PostgreSQL for simple apps (SQLite may suffice)
❌ Skip indexing
❌ Use SELECT * in production
❌ Store JSON when structured data is better
❌ Ignore N+1 queries

Related Skills

web-design-guidelines

65
from One-Man-Company/Skills-ContextManager

Review UI code for Web Interface Guidelines compliance. Use when asked to "review my UI", "check accessibility", "audit design", "review UX", or "check my site against best practices".

mobile-design

65
from One-Man-Company/Skills-ContextManager

Mobile-first design thinking and decision-making for iOS and Android apps. Touch interaction, performance patterns, platform conventions. Teaches principles, not fixed values. Use when building React Native, Flutter, or native mobile apps.

game-design

65
from One-Man-Company/Skills-ContextManager

Game design principles. GDD structure, balancing, player psychology, progression.

frontend-design

65
from One-Man-Company/Skills-ContextManager

Design thinking and decision-making for web UI. Use when designing components, layouts, color schemes, typography, or creating aesthetic interfaces. Teaches principles, not fixed values.

webapp-testing

65
from One-Man-Company/Skills-ContextManager

Web application testing principles. E2E, Playwright, deep audit strategies.

vulnerability-scanner

65
from One-Man-Company/Skills-ContextManager

Advanced vulnerability analysis principles. OWASP 2025, Supply Chain Security, attack surface mapping, risk prioritization.

ui-ux-pro-max

65
from One-Man-Company/Skills-ContextManager

UI/UX design intelligence. 50 styles, 21 palettes, 50 font pairings, 20 charts, 9 stacks.

testing-patterns

65
from One-Man-Company/Skills-ContextManager

Testing patterns and principles. Unit, integration, mocking strategies.

tdd-workflow

65
from One-Man-Company/Skills-ContextManager

Test-Driven Development workflow principles. RED-GREEN-REFACTOR cycle.

tailwind-patterns

65
from One-Man-Company/Skills-ContextManager

Tailwind CSS v4 principles. CSS-first configuration, container queries, modern patterns, design token architecture.

systematic-debugging

65
from One-Man-Company/Skills-ContextManager

4-phase systematic debugging methodology with root cause analysis and evidence-based verification. Use when debugging complex issues.

skill-creator

65
from One-Man-Company/Skills-ContextManager

Guide for creating effective skills. This skill should be used when users want to create a new skill (or update an existing skill) that extends Claude's capabilities with specialized knowledge, workflows, or tool integrations.