Communitygithub.com

YepAPI/skills

스키마 정규화, 인덱싱 전략 및 마이그레이션 패턴

skills란 무엇인가요?

이 스킬은 데이터베이스 설계를 위한 포괄적인 가이드를 제공합니다. 개발자에게 스키마 정규화(기본적으로 3NF), 인덱싱 전략(기본 키, 외래 키, 자주 필터링/정렬되는 컬럼), 버전 제어된 마이그레이션(up + down, 설명적 이름), 시드 데이터(현실적인 테스트 데이터), 소프트 삭제 사용자 대상 레코드 및 하드 삭제 임시 데이터, 공개 ID용 UUID와 내부 관계용 자동 증가 정수, 서버리스용 연결 풀링(PgBouncer, Prisma Accelerate, Supabase pooler), 자동 일일 백업 및 복원 테스트와 같은 백업 전략, EXPLAIN ANALYZE를 사용한 쿼리 최적화 및 SELECT * 회피 등 모범 사례를 설명합니다. Claude Code, Cursor와 같은 AI 에이전트 플랫폼에서 유용하며, SKILL.md 문서에 명시된 규칙을 따릅니다.

지원 대상~Claude Code~Codex CLI~Cursor
npx skills add https://github.com/YepAPI/skills/tree/HEAD/skills/database

즐겨 사용하는 AI에게 물어보기

이 에이전트 스킬이 미리 로드된 새 채팅을 엽니다.

문서

데이터베이스 설계

규칙

  • 기본적으로 3NF로 정규화 — 측정된 성능 요구 사항이 있을 때만 비정규화
  • 인덱스 전략: 기본 키(자동), 외래 키, 자주 필터링/정렬되는 컬럼
  • 마이그레이션: 버전 관리, up + down, 설명적 이름
  • 개발용 시드 데이터 — foo/bar가 아닌 실제 테스트 데이터
  • 사용자 대상 레코드에 대해 소프트 삭제(deletedAt) — 정말 일시적인 데이터는 하드 삭제
  • 공개 ID에는 UUID — 내부 관계에는 자동 증가 정수
  • 서버리스용 연결 풀링 — PgBouncer, Prisma Accelerate 또는 Supabase pooler
  • 백업 전략: 자동화된 일일 백업, 복원 프로세스 테스트
  • 쿼리 최적화: EXPLAIN ANALYZE, SELECT * 회피, 특정 컬럼 사용

Individual skills in this repo

This repo contains 20 individual skills — each has its own dedicated page.

YepAPI/skills

WCAG 2.1 AA — semantic HTML, keyboard navigation, screen readers.

YepAPI/skills

Experiment setup, variant splitting, statistical significance, and feature flag integration.

YepAPI/skills

CRUD generators, data tables, user management, role-based access, and bulk operations.

YepAPI/skills

Monitor what ChatGPT and Gemini say about your brand using YepAPI.

YepAPI/skills

Queue workers with BullMQ/Inngest/Trigger.dev, job retries, dead letter queues, concurrency.

YepAPI/skills

Commander.js, interactive prompts with Clack, spinners, colors, config files, exit codes, and npm publishing.

YepAPI/skills

cmdk integration, Cmd+K trigger, fuzzy search, grouped actions, keyboard navigation, and dynamic action registration.

YepAPI/skills

Content planning with trend and sentiment data from YepAPI.

YepAPI/skills

Content calendar, keyword-driven planning, and content briefs.

YepAPI/skills

Theme switching with CSS variables, system preference detection, next-themes, and persistence.

YepAPI/skills

Threaded comments, @mentions, reactions, moderation queue, optimistic UI, and cursor pagination.

YepAPI/skills

Competitive analysis between domains using YepAPI.

YepAPI/skills

Layout grids, KPI cards, data tables with sorting/filtering, sidebar navigation, and responsive breakpoints.

YepAPI/skills

Data encryption — TLS everywhere, AES-256-GCM for PII, bcrypt passwords, encrypted backups.

YepAPI/skills

Chart patterns with Recharts/Nivo/D3, responsive containers, color scales, and accessibility.

YepAPI/skills

Drizzle schema definition, push vs migrate, type-safe queries, relations, transactions, and prepared statements.

YepAPI/skills

Upload handling, resize/compress, CDN delivery, blur placeholders, and next/image patterns.

YepAPI/skills

Local business and Google Maps research using YepAPI.

YepAPI/skills

Cursor-based pagination, IntersectionObserver, virtualized lists with @tanstack/react-virtual, and scroll position restoration.

YepAPI/skills

Chat UI components, streaming responses with AI SDK, context window management, and RAG patterns.

관련 스킬