Skip to content

Build the Vertical Slice

Build Mosaic as a sequence of complete slices. Each slice produces a runnable system and preserves the earlier tests.

Implement:

  • Task, Budget, RunState, and RunError;
  • Model and Verifier traits;
  • scripted model;
  • one structured output;
  • in-memory trace.

Acceptance: a test covers success, invalid output, one repair, and exhausted repair budget.

Add:

  • clap commands;
  • YAML task parsing;
  • JSONL trace persistence;
  • strict replay;
  • cancellation;
  • redaction.

Acceptance: replay reaches the same terminal state with no external calls.

Add content-addressed blobs, text locators, image regions, OCR, and an embedding adapter.

enum EvidenceQuery {
Text(String),
SimilarTo(EvidenceId),
Region { image: EvidenceId, area: NormalizedRegion },
}

Acceptance: a generated claim cannot cite a nonexistent image region.

Add timed transcript spans, sampled frames, shot boundaries, and audio events. Start with external decoders behind traits before optimizing.

Acceptance:

  • no decoded interval escapes source duration;
  • the pipeline is bounded under a large input;
  • cancellation terminates decoding;
  • artifacts retain transform provenance.

Add one remote adapter and one local capability:

  • normalize request/response metadata;
  • protect secrets;
  • record model artifact or provider model ID;
  • support timeout and retry policy;
  • benchmark the local model.

Acceptance: either provider can replace the scripted model without changing program logic.

Add a read-only source tool and a preview-producing transformation tool. Every tool declares effect and capabilities.

let authorized = authorizer.check(actor, run, proposed_call)?;
let receipt = tool_runtime.execute(authorized).await?;
let observed = verifier.observe_effect(&receipt).await?;

Acceptance: a model-generated call cannot bypass authorization, even during replay or retry.

Add Axum, SQLx, workers, object storage, leases, event IDs, and resumable SSE.

Acceptance:

  • worker crash does not duplicate an effect;
  • server restart preserves run state;
  • client reconnect receives missed events;
  • tenant isolation holds at retrieval and tool boundaries.

Add:

  • versioned fixtures;
  • deterministic graders;
  • calibrated model grader;
  • experiment reports;
  • small/local route and strong fallback;
  • quality, latency, and cost thresholds.

Acceptance: release tooling rejects a candidate that improves mean score while increasing severe failures.

Add candidate generation adapters for at least two output modalities—for example image storyboards and speech narration.

Do not begin with final video generation. Use a funnel:

many cheap briefs
→ a few storyboard candidates
→ verified image + narration pairs
→ expensive video finalists
→ human-approved artifact

Acceptance: every output has provenance, safety status, cost, grader results, and approval state.

  • structured traces and metrics;
  • per-tenant quotas;
  • audit log;
  • provider and local model health;
  • data retention and deletion;
  • chaos tests for timeouts and partial failures;
  • canary and rollback;
  • runbook.

Run Signal Room and Cutroom on Mosaic. Then show:

  1. the same evidence primitives support both;
  2. local preprocessing reduces expensive model context;
  3. a small-model path handles routine cases;
  4. verifier failures trigger targeted repair or routing;
  5. held-out evals establish the trade-off;
  6. a risky generated artifact cannot publish without approval.

That demonstration proves you built an AI application platform—not a provider wrapper.