Skip to main content

Documentation Index

Fetch the complete documentation index at: https://mintlify.com/buildermethods/design-os/llms.txt

Use this file to discover all available pages before exploring further.

/data-shape

Defines the general shape of your product’s data - the core entities (“nouns”) and how they relate to each other.

Syntax

/data-shape
```bash

## What It Does

Creates or updates a high-level data model that:
- Identifies core entities (things users create, view, or manage)
- Describes what each entity represents
- Defines conceptual relationships between entities
- Establishes consistent naming across all sections

<Note>
This is NOT a detailed database schema - it's a starting point that ensures consistent vocabulary across your product.
</Note>

## Prerequisites

- Requires `/product/product-overview.md`
- Requires `/product/product-roadmap.md`

<Warning>
If you haven't run `/product-vision`, this command will prompt you to do so first.
</Warning>

## Outputs

Creates or updates:
- `/product/data-shape/data-shape.md`

## Workflow (New Data Shape)

<Steps>
  <Step title="Analyze Product">
    Reads your product overview and roadmap to understand what entities are needed.
  </Step>
  
  <Step title="Generate Data Shape">
    Creates entity definitions with:
    - Entity names (singular)
    - Plain-language descriptions
    - Conceptual relationships
  </Step>
  
  <Step title="Confirm">
    Presents the entities and relationships for review.
  </Step>
</Steps>

## Workflow (Updating Existing)

<Steps>
  <Step title="Show Current State">
    Displays current entities and relationships.
  </Step>
  
  <Step title="Gather Feedback">
    Asks what you'd like to change.
  </Step>
  
  <Step title="Update File">
    Immediately updates the data shape based on your feedback.
  </Step>
</Steps>

## Data Shape Format

```markdown
# Data Shape

## Entities

### [EntityName]
[Plain-language description of what this entity represents]

### [AnotherEntity]
[Plain-language description]

## Relationships

- [Entity1] has many [Entity2]
- [Entity2] belongs to [Entity1]
- [Entity3] belongs to both [Entity1] and [Entity2]
```bash

## Guidelines

<Accordion title="What to Include">
- **Entity names:** Singular form (Invoice, not Invoices)
- **Descriptions:** Plain language, user perspective
- **Relationships:** Conceptual, not database structure
- **Minimal detail:** Focus on what entities represent, not every field
</Accordion>

<Accordion title="What NOT to Include">
- Detailed schemas or field definitions
- Database types or validation rules
- Technical implementation details
- Exhaustive field lists
</Accordion>

## Example Output

```markdown
# Data Shape

## Entities

### Invoice
A bill sent to a client for work completed, containing line items, 
amount due, and payment status.

### Client
A person or organization that receives invoices and makes payments.

### LineItem
An individual service or product listed on an invoice with description, 
quantity, and rate.

### Payment
A record of money received for an invoice, including amount, date, 
and payment method.

## Relationships

- Invoice has many LineItem
- LineItem belongs to Invoice
- Invoice belongs to Client
- Client has many Invoice
- Payment belongs to Invoice
- Invoice has many Payment
```bash

## Why Define Data Shape?

Establishing a data shape early:

1. **Consistency:** Ensures the same entity names are used across all sections
2. **Shared Vocabulary:** Creates a common language for the product
3. **Better Sample Data:** Section sample data references global entities
4. **Implementation Clarity:** Gives developers a starting point for data modeling

<Note>
The implementation agent will extend and refine these entities based on technical requirements. This is just the foundation.
</Note>

## Example Session (Creating New)

```bash
User: /data-shape

Assistant: I've created your data shape at 
`/product/data-shape/data-shape.md`.

**Entities defined:**
- Invoice
- Client
- LineItem
- Payment

**Relationships:**
- Invoice has many LineItem
- Invoice belongs to Client
- Payment belongs to Invoice

This provides a shared vocabulary for your screen designs.
```bash

## Example Session (Updating Existing)

```bash
User: /data-shape

Assistant: Your data shape currently defines these entities:

- **Invoice** — A bill sent to a client
- **Client** — A person or organization
- **LineItem** — An item on an invoice

What would you like to change about the entities or relationships?

User: Add a Template entity for reusable invoice templates

Assistant: I've updated the data shape to include Template.
```bash

## Important Notes

- Keep descriptions minimal and user-focused
- Use plain language, not technical jargon
- Relationships are conceptual, not database constraints
- Entity names should match user mental models

## Next Steps

After defining your data shape:

1. Run `/design-tokens` to choose colors and typography
2. Run `/shape-section` to define section specifications
3. When you run `/sample-data`, it will reference these entities for consistency

Build docs developers (and LLMs) love