Skip to main content
MRS is built on principles derived from the real requirements of AI-assisted composition and orchestration at professional scale. See: /MRS-Specification-RFC#2-design-principles

Separation of Concerns: Semantic Model vs Representations

MRS is a semantic model plus protocols for safe editing. It may be represented in multiple ways depending on the audience and task. Rationale: The architecture should not depend on a single file format. What matters is stable identity, deterministic application, and human-auditable changes. Reliability consequence: Asking agents to emit complete, valid score fragments creates high failure rates from accidental omissions, calculation errors, and hallucinated references. Typed operations with orchestrator-derived fields eliminate entire error classes.

Orchestrator Authority

The orchestrator is the sole authority for:
  • UUID minting: Agents use temporary IDs; orchestrator assigns final UUIDs
  • Derived field computation: Orchestrator computes :at, :beat-start, etc.
  • Canonical state management: Single source of truth
  • Validation and application: Progressive validation before state mutation
Rationale: Centralized authority eliminates coordination failures. Agents cannot create invalid references or miscalculate derived fields because they don’t manage those concerns.

Stable Identity Over Positional Reference

Every measure, event, and span carries a stable UUIDv7 identifier. Measure numbers are display properties for human navigation, not structural identity.
Rationale: Positional references break when content is inserted or deleted. UUID references survive structural changes, enabling fluid compositional workflows where form evolves during the creative process.

Progressive Validation

Operations are validated in stages before application:
Rationale: Errors caught before state mutation enable specific feedback, partial acceptance, and no silent corruption. This is fundamentally different from “emit fragment, hope it validates.”

Task-Adaptive Context

Agents receive context views tailored to their specific task, not fixed “near/far” rings. Rationale: Fixed rings may include irrelevant content and omit critical content. A countermelody task needs the melody it responds to, not “nearby measures at melodic-skeleton reduction.”

Professional Orchestration Semantics

The Player → Instrument → Staff model supports real-world orchestration:
Rationale: Arrangers and orchestrators work with players and instrument changes constantly. Flute 2 doubling piccolo is not an edge case—it’s standard practice. The model must reflect professional reality.

Explicit Over Implicit

Every musical element has an explicit representation. Position in the measure is stated, not inferred from accumulated durations. Voice assignment is declared, not guessed from stem direction. Rationale: Implicit state creates cascading errors. If an LLM miscounts one duration, all subsequent events are misaligned. Explicit positions are independently verifiable.

Semantic Over Visual

MRS encodes musical meaning, not page layout. A crescendo is marked with semantic anchors (start/end and type), not with graphical coordinates. Rationale: Layout is context-dependent (page size, staff spacing, font). Semantic encoding remains valid across renderers. Practical note: Real-time feedback still matters for musicians. Implementations can render previews by exporting the relevant region to a notation engine, or by using a lightweight preview renderer, without making engraving geometry part of the canonical model.

Predictable Over Clever

The format uses regular patterns even when more compact alternatives exist. Every note uses the same syntax regardless of context. Rationale: LLMs generate more reliably when patterns are consistent. A 10% size reduction is not worth a 50% increase in generation errors.

Canonical Rational Syntax

All temporal positions use exact rationals in a single canonical form:
Rationale: Decimal literals invite floating-point parsing and normalization ambiguity. One canonical form eliminates entire error classes.