Agent contract
Surfaces agents should edit; invariants.
This is the editing contract for LLM agents working on Deckard (same intent as repo AGENTS.md).
Prefer these surfaces
- Project shape —
docs/schema/project-v2.json(generatorId+generatorParams) - Load / model —
src/model/Project.tish,ProjectLoad.tish(loadProjectFromTpl), default songprojects/default.deckard.deck - Generators —
src/generators/(docs) - Safe mutators —
src/model/Edits.tish - deck language — grammar, agent subset,
src/deckfile/
Co-DJ
- Agents emit only their lane (track ids prefixed with
actorId, e.g.ai-a_hat) - Master-scope lines (
bpm, version header,master_mix,auto, …) needmaster_mixer— see skills - Prompt composition: roles & skills + agent grammar
Invariants
- Project
version: use2for generator-based projects - Times:
startBeat/durBeatsare quarter-note beats - Preserve channel
idstrings - Do not put sequencing rules in JSX-only UI files — keep logic in
model/, schedule,audio/ - UI is a deck client: edits go through emit/apply, not silent project mutation
Audio / Tish JS
Use new AudioContext() and new Uint8Array(n) on the JS target (see docs/TISH_JS_BUILTINS.md in the repo).