A kit is a reusable .dog spec template. Users run dotdog kit init <name> and dotdog copies the kit into specs/<name>/ so they can start from a complete domain model instead of a blank project.
Built-in kits live in:
packages/dotdog/kits/<name>/
Every built-in kit must include:
SPEC.dog
constitution.dog
data-model.dog
Use a short lowercase directory name:
packages/dotdog/kits/dao/
SPEC.dog
constitution.dog
data-model.dog
SPEC.dog describes the product, user flows, screens, and user stories. Keep it concrete enough that a new user can understand what the kit scaffolds.
constitution.dog defines rules, constraints, and invariants. These are the promises the generated project should preserve.
data-model.dog defines entities, properties, states, lifecycles, and relationships. This file is what agents query most often after dotdog compile.
Use a heading, a short description, and a fenced YAML block:
### Entity: Proposal
A governance proposal that members can vote on.
```yaml
entity: Proposal
type: entity
properties:
id:
type: string
required: true
title:
type: string
required: true
status:
type: enum
required: true
states: [draft, active, passed, rejected, executed]
lifecycle: draft → active → passed → executed
```
Rules:
entity: value exactly.states and lifecycle when the entity changes over time.Proposal, Vote, and Member over implementation names.Use the Unicode arrow → in relationship headings:
### Relationship: Member → Vote
```yaml
relationship: Member → Vote
verb: casts
cardinality: 1:N
required: true
```
Rules:
1:1, 1:N, N:1, or N:N for cardinality.dotdog compile before opening a PR; broken relationships fail compilation.From the repo root, initialize the kit in a temporary directory:
tmp=$(mktemp -d)
cd "$tmp"
bun /path/to/dotdog/packages/dotdog/src/cli.ts kit init dao
bun /path/to/dotdog/packages/dotdog/src/cli.ts validate
bun /path/to/dotdog/packages/dotdog/src/cli.ts compile
From inside the dotdog repo, run the full test suite too:
bun test
bun packages/dotdog/src/cli.ts validate
bun packages/dotdog/src/cli.ts compile
The CLI test suite initializes every built-in kit and verifies that each generated project contains SPEC.dog, constitution.dog, and data-model.dog, then runs validate.
SPEC.dog, constitution.dog, and data-model.dog are present..dog file parses.dotdog validate passes after dotdog kit init <name>.dotdog compile passes after dotdog kit init <name>.See packages/dotdog/kits/dao/ for a minimal community-governance kit with members, proposals, votes, and treasury allocations.