Skip to main content

design-a-data-model

Turn real business rules and workflows into entities, relationships, constraints, ownership, and lifecycle decisions that can support reliable queries and change. Use when designing a new database, untangling an overloaded schema, or aligning product language with stored data before implementation.

소스 정보

저장소
protosphinx/sphinxstack
최근 소스 활동
2026년 7월 29일 13:55
감지된 SKILL.md 언어
영어
스타
3
포크
0

설치 방법

기본적으로 소스를 먼저 확인하는 Prompt가 선택됩니다. 직접 명령으로 전환하거나 로컬 사본을 다운로드할 수도 있습니다.

소스 파일 검토

설치 여부를 결정하기 전에 SKILL.md와 SkillsMP에 표시된 보조 파일을 읽어 보세요.

파일 탐색기
2 개 파일

SKILL.md 표시 중

SKILL.md
소스 지침 · 읽기 전용 미리보기
name
design-a-data-model
category
data
description
Turn real business rules and workflows into entities, relationships, constraints, ownership, and lifecycle decisions that can support reliable queries and change. Use when designing a new database, untangling an overloaded schema, or aligning product language with stored data before implementation.
# design-a-data-model Model the facts the system must preserve, not the screens it currently shows. Make identity, time, ownership, optionality, and invalid states explicit before selecting tables or documents. ## Inputs - Gather real workflows, example records, reports, policies, integrations, and current terminology. - Name system owners, data stewards, privacy classes, retention rules, and important queries. - Separate durable business facts from presentation and derived values. ## Procedure 1. Write representative create, update, read, delete, correction, and history scenarios. 2. Build a glossary defining each business term, synonyms, owner, and disputed meaning. 3. Identify entities with stable identity and distinguish them from events, attributes, classifications, and aggregates. 4. Define relationships, cardinality, optionality, ordering, temporal validity, and ownership. 5. Choose identifiers and natural uniqueness rules. State how duplicates, merges, and external ids are handled. 6. Encode invariants as constraints where possible, not only application conventions. 7. Model state changes and history explicitly when the past matters. Avoid overwriting facts needed for audit or reconciliation. 8. Mark personal, confidential, regulated, derived, and deletable fields with access and retention rules. 9. Test the model against representative records, edge cases, corrections, concurrent actions, and required queries. 10. Normalize rules to one owner, then denormalize only for a measured read need with a reconciliation path. 11. Produce the logical model, data dictionary, invariant list, lifecycle notes, and open decisions. ## Boundaries Do not copy production data into design artifacts without permission. Never use ambiguous names such as status or type without a defined vocabulary. Do not add personal data because it may be useful later. ## Done - A model diagram and glossary define entities, identities, relationships, cardinality, and ownership - A data dictionary records type, meaning, privacy class, source, lifecycle, and constraints for material fields - Representative workflows and invalid-state tests verify the model preserves business rules - Derived or denormalized data has a named source of truth and reconciliation method Then use database-basics for implementation or migrate-a-database for a live schema transition.
GitHub에서 보기