import { m } from "motion/react"; import type { DemoTimelineController } from "../demo/useDemoTimeline.js"; import type { TimelineAgentController } from "../demo/agent/timelineAgent.js"; import type { DemoApprovalActions } from "./demo-approval-actions.js"; import { AgentHandoffScene } from "./authoring/AgentHandoffScene.js"; import { discussionBranches, findBeat, findScene, type PresentationLocation, type SceneDefinition, type SceneBeatDefinition, } from "./storyboard.js"; import { PreparedAuthoringLifecycleScene } from "./authoring/PreparedAuthoringLifecycleScene.js"; import { DemoWorkflowScene } from "./DemoWorkflowScene.js"; import { StageCaption } from "./StageCaption.js"; import { ConclusionScene } from "./conclusion/ConclusionScene.js"; import { DefenseDiscussionIndex } from "./discussion/DefenseDiscussionIndex.js"; import { EvaluationEvidenceScene } from "./evaluation/EvaluationEvidenceScene.js"; import { ArchitectureScene } from "./scenes/ArchitectureScene.js"; import { OpeningThesisScene } from "./opening/OpeningThesisScene.js"; import { ProblemLoopScene } from "./opening/ProblemLoopScene.js"; type SceneBodyProps = { readonly location: PresentationLocation; readonly demo: DemoTimelineController; readonly timelineAgent?: TimelineAgentController | undefined; readonly selectedNodeId: string | null; readonly selectNode: (nodeId: string | null) => void; readonly openEvidence: () => void; readonly openDiscussion: (branchId: string) => void; readonly onFocusPathChange: (path: readonly string[]) => void; readonly motionDisabled: boolean; readonly approvalActions?: DemoApprovalActions | undefined; readonly onPreparedLifecycleAdvance?: (() => void) | undefined; readonly onRunPreparedWorkflow?: (() => Promise) | undefined; }; const workflowDemoSceneIds = new Set([ "prepared-lifecycle", "run-from-deployment", "typed-human-boundary", "resume-output-evidence", ]); const DiscussionLinks = ({ sceneId, openDiscussion, }: { readonly sceneId: string; readonly openDiscussion: (branchId: string) => void; }) => { const branches = discussionBranches.filter((branch) => branch.parentSceneId === sceneId); if (branches.length === 0) return null; return ( ); }; const actForSceneNumber = (sceneNumber: number): string => { if (sceneNumber <= 3) return "I"; if (sceneNumber <= 12) return "II"; if (sceneNumber === 13) return "III"; return "IV"; }; const NarrativeScene = ({ scene, beat }: { scene: SceneDefinition; beat: SceneBeatDefinition }) => ( <>

{beat.caption}

{scene.evidencePointer}

); const choreographyTransition = (motionDisabled: boolean) => ({ duration: motionDisabled ? 0 : 0.34, ease: [0.16, 1, 0.3, 1] as const, }); type ChoreographyProps = { readonly scene: SceneDefinition; readonly beat: SceneBeatDefinition; readonly motionDisabled: boolean; }; const PositioningScene = ({ scene, beat, motionDisabled }: ChoreographyProps) => { const highlightLda = beat.id === "lda-position"; const transition = choreographyTransition(motionDisabled); return ( <>

{beat.caption}

Direct action

Tool loops Fast action, no durable lifecycle Generated scripts Inspectable code, weak deployment records
This thesis lda.chat

Typed lifecycle substrate for external agents and human operators.

  • Lifecycle
  • Validation
  • Persisted records

Adjacent systems

Hosted automation Managed triggers and app integrations Agent graphs Durable planner loops MCP Capability protocol boundary

{scene.evidencePointer}

); }; const boundaryActiveForBeat = (beatId: string): "planner" | "runtime" | "boundary" => { if (beatId === "runtime") return "runtime"; if (beatId === "boundary") return "boundary"; return "planner"; }; const BoundaryScene = ({ scene, beat, motionDisabled }: ChoreographyProps) => { const active = boundaryActiveForBeat(beat.id); const plannerActive = active === "planner" || active === "boundary"; const runtimeActive = active === "runtime" || active === "boundary"; const transition = choreographyTransition(motionDisabled); return ( <>

{beat.caption}

External operator

Planner

  • Proposes workflow structure
  • Revises steps and bindings
  • Chooses tools
CLI / JSON-RPC typed workflow operations lda.chat substrate

Runtime

  • Validates schemas and routes
  • Executes deterministic nodes
  • Records traces and run output
  • Resumes from persisted state

{scene.evidencePointer}

); }; const lifecycleStages = [ { id: "draft", label: "Draft", role: "Mutable authoring state", detail: "Iterate before freezing a workflow definition." }, { id: "artifact", label: "Artifact", role: "Immutable workflow definition", detail: "Save a versioned plan that can be deployed." }, { id: "deployment", label: "Deployment", role: "Source binding", detail: "Bind workflow requirements to configured runtime sources." }, { id: "run", label: "Run", role: "Execution record and trace", detail: "Persist status, outputs, interrupts, and trace evidence." }, ] as const; const LifecycleScene = ({ scene, beat, motionDisabled }: ChoreographyProps) => { const activeIndex = Math.max(0, lifecycleStages.findIndex((stage) => stage.id === beat.id)); const activeStage = lifecycleStages[activeIndex]!; const transition = choreographyTransition(motionDisabled); return ( <>

{beat.caption}

{lifecycleStages.map((stage, i) => ( {i + 1} {stage.label} {stage.role} {i < lifecycleStages.length - 1 && } ))}

{scene.evidencePointer}

); }; const assertNever = (value: never): never => { throw new Error(`Unexpected view: ${value}`); }; export const SceneBody = ({ location, demo, selectedNodeId, selectNode, openEvidence, openDiscussion, onFocusPathChange, motionDisabled, approvalActions, onPreparedLifecycleAdvance, onRunPreparedWorkflow }: SceneBodyProps) => { const sceneId = location.kind === "main" ? location.sceneId : "positioning"; const beatId = location.kind === "main" ? location.beatId : "landscape"; const scene = findScene(sceneId) ?? findScene("thesis")!; const beat = findBeat(sceneId, beatId) ?? scene.beats[0]!; const isWorkflowDemoScene = workflowDemoSceneIds.has(scene.id); const showDiscussionRail = !(scene.id === "conclusion" && beat.id === "questions") && (!isWorkflowDemoScene || scene.id === "prepared-lifecycle"); const discussionLinks = showDiscussionRail ? : null; const content = (() => { switch (scene.view) { case "narrative": if (scene.id === "thesis") return ; if (scene.id === "problem") return ; return ; case "positioning": return ; case "boundary": return ; case "lifecycle": return ; case "architecture": return ( ); case "agent": return ; case "demo-lifecycle": return ( ); case "demo": return ( ); case "evaluation": return ; case "conclusion": return beat.id === "questions" ? : ; default: return assertNever(scene.view); } })(); return ( <> {content} {scene.id === "prepared-lifecycle" ? null : discussionLinks} ); };