The Spatial Harness: Bringing Agents to the Canvas — Max Drake, tldraw

Max Drake· tldraw18:51

Read the talk

The Spatial Harness: Bringing Agents to the Canvas

Selected presentation frame from The Spatial Harness: Bringing Agents to the Canvas — Max Drake, tldraw at 637 secondsOpen full source frame
The Spatial Harness: Bringing Agents to the Canvas

Max Drake traces tldraw’s canvas agents from spatial perception, through autonomous navigation and visible multi-agent coordination, to dependency graphs and a desktop editor that agents can script against real files and applications.

From a talk by Max Drake

At a glance

Ideas worth remembering

  • Spatial agents need a harness that combines rendered appearance with structured canvas state, then translates model intent back into canvas actions.

  • Autonomy on an infinite canvas requires active perception: the agent must be able to move its viewport, inspect off-screen objects, create intermediate goals, and continue working toward them.

  • Visible agent identity and status are functional interface elements. Fairies let a person distinguish working, waiting, and idle agents without reading every chat transcript.

  • A dependency graph can serve as both project map and execution interface when task nodes let people launch coding agents and return progress or pull requests to the shared canvas.

  • Exposing the desktop editor to an existing coding agent avoids trapping the agent inside a canvas-specific harness and enables temporary spatial interfaces connected to files and desktop applications.

  • The opening agent retrieved the specification, but the requested fluid simulation remained unfinished within the talk. Successful retrieval and completed execution are separate milestones.

The canvas problem returns one layer up

Max Drake, a product engineer working on agents at tldraw, opens by giving an agent a job before the talk has properly begun: find a specification linked from an email and a Notion document, then build it in the local tldraw desktop app. The request quietly contains the whole challenge. The agent must cross applications, recover the right context, translate a written specification into spatial behavior, and keep working while the presentation continues. The result will return near the end—and it will not be a clean demo victory. 0:13

Selected presentation frame from The Spatial Harness: Bringing Agents to the Canvas — Max Drake, tldraw at 96 secondsOpen full source frame
The canvas problem returns one layer up

tldraw is three things here: a free infinite-canvas whiteboard, the London company that makes it, and, most importantly for this story, the SDK underneath it. Selection, resizing, arrows, viewport behavior, and matrix math are difficult enough that teams building a slide designer, whiteboard, or other spatial product can spend their time rebuilding the canvas instead of their actual application. The SDK packages those mechanics so a product can begin above that layer. 1:20

LLM applications reproduced the same trap one level higher. A team could imagine an agent rearranging objects in space, yet still lack established ways to represent the scene, expose useful actions, or show what the agent was doing. tldraw already supplied multiplayer primitives—live synchronization, cursors, selections, and viewports—which suggested that a canvas built for human collaborators could also become a shared place for human and agent work. 3:19

Coding agents provide the contrast. Their prompts, source files, searches, and generated code are largely text, close to the medium on which language models were trained. Two-dimensional editing adds geometry and visual state: which objects exist, where they sit, what is currently visible, and how an action will alter the scene. Even a request to align interface elements can fail unless the surrounding harness translates between model-friendly representations and spatial operations. Drake calls the text-in/text-out account an oversimplification, but it explains why the canvas needs substantial extra engineering. 4:19

Suggest correction

This note stays in this page until you copy or download it. Nothing is submitted; reloading clears the draft.

0:13 · section reference included

Teach gives the model two views of the same canvas

The first project, Teach, tackles perception and action before autonomy. The prompt is simple: “make the mouse blow out the candle.” The canvas does not contain a privileged semantic object called a mouse; it contains ordinary shapes arranged so that a person recognizes one. The system supplies both a screenshot and underlying canvas data, allowing the model to combine visual interpretation with structured information about the objects. 5:20

Selected presentation frame from The Spatial Harness: Bringing Agents to the Canvas — Max Drake, tldraw at 320 secondsOpen full source frame
Teach gives the model two views of the same canvas

The observable change is small but instructive. The model interprets the drawn mouse and candle from the rendered scene and canvas data, then produces actions that add wind and smoke in the appropriate positions. The edit reads as the mouse blowing out the candle. This requires more than recognizing the drawing: the model must connect its canvas actions to their effect on the composition. In this run, wind appears first and smoke follows, with positions Drake considers correct. 5:31

What information has to cross the model–canvas boundary for that edit to work? The diagram makes the paired representation and action flow visible. The screenshot supplies appearance and composition; canvas data supplies explicit object state; the harness turns the model’s intended change back into spatial actions. Teach performs this in one prompt, so it demonstrates grounded editing rather than a persistent agent that can search, plan, and recover over multiple steps.

From canvas state to a visible spatial edit

Existing canvasinput — Ordinary shapes form a mouse and candle.
Screenshotrepresentation — Shows appearance, composition, and spatial relationships.
Canvas datarepresentation — Describes the underlying objects and state.
Model interpretationmodel — Identifies what the shapes represent and chooses an edit.
Canvas actionsoutput — Create and position ordinary wind and smoke shapes.
Changed sceneoutput — The mouse now appears to blow out the candle.
Teach combines rendered appearance with structured canvas data, then converts the model’s intended change into ordinary canvas actions.
Read the diagram as text
  • Existing canvas. input — Ordinary shapes form a mouse and candle.
  • Screenshot. representation — Shows appearance, composition, and spatial relationships.
  • Canvas data. representation — Describes the underlying objects and state.
  • Model interpretation. model — Identifies what the shapes represent and chooses an edit.
  • Canvas actions. output — Create and position ordinary wind and smoke shapes.
  • Changed scene. output — The mouse now appears to blow out the candle.
  • Existing canvas → Screenshot: rendered as.
  • Existing canvas → Canvas data: represented as.
  • Screenshot → Model interpretation: visual context.
  • Canvas data → Model interpretation: structured context.
  • Model interpretation → Canvas actions: produces intended edits.
  • Canvas actions → Changed scene: updates canvas.
Suggest correction

This note stays in this page until you copy or download it. Nothing is submitted; reloading clears the draft.

5:20 · section reference included

From one-shot editing to an agent that can go looking

The tldraw Agent Starter Kit wraps that perception-and-action capability in a harness that supports multi-step work. Drake describes its code as MIT licensed. Instead of responding once, the agent can create goals, maintain todos, change its own viewport, inspect another part of the canvas, and continue toward a result. 6:31

Selected presentation frame from The Spatial Harness: Bringing Agents to the Canvas — Max Drake, tldraw at 415 secondsOpen full source frame
From one-shot editing to an agent that can go looking

The example begins with a cat and a request: somewhere else on the canvas are potential friends; bring one to the cat, whose favorite color is red. The agent needs to look beyond the initial view. It creates intermediate goals and changes its viewport to inspect the area containing potential friends, working toward the request. The demonstrated progress establishes planning and navigation, without confirming that a friend was selected or brought back. Viewport movement becomes the spatial equivalent of a coding agent searching a repository to find where something is defined. 7:01

This changes the role of the harness. Teach translates one instruction into one edit; the Starter Kit supports repeated observation and action through three mechanisms:

  • Planning: The agent creates todos that break the request into intermediate goals.
  • Active perception: It changes its viewport to reveal information elsewhere on the canvas.
  • Execution: The harness gives the agent canvas actions it can use while pursuing those goals.

The model still needs spatial grounding, but it can now seek information beyond the initial frame.

Suggest correction

This note stays in this page until you copy or download it. Nothing is submitted; reloading clears the draft.

6:31 · section reference included

Fairies turn multi-agent state into something you can glance at

The next experiment, Fairies, starts from the canvas’s multiplayer character. People should be able to work alongside agents, and agents should be able to work with one another. Each agent therefore appears as a visible character on the board. A fairy can be grabbed and thrown, assigned a hat or color, and adjusted with an intentionally ridiculous leg slider. The whimsy does real interface work: when several agents share a canvas, appearance provides a quick identity cue. 8:18

Selected presentation frame from The Spatial Harness: Bringing Agents to the Canvas — Max Drake, tldraw at 551 secondsOpen full source frame
Fairies turn multi-agent state into something you can glance at

A single fairy can receive a task such as drawing a cat, but the more important interaction appears when several are selected together. The selection opens a group chat, turning spatial grouping into a way to choose a team. Drake asks the group to prepare a memo containing financial data for fiscal year 2025. One fairy begins planning, while the others become available for assigned work. 9:18

The animations are “cute and funny,” but they also act as status indicators. With ten agents running, a person should not need to open ten chat logs merely to discover that one agent is working, another is waiting, and another is bored. The board makes identity, location, and current state visible at once. This is where the canvas becomes more than a place to display agent output: it becomes an operations interface for supervising concurrent work. 10:18

How does a selected group become coordinated work? One fairy acts as orchestrator: it defines and assigns a task, waits while another fairy performs it, receives a notification when the work finishes, and is prompted to review it. The live demonstration briefly appears stalled by connectivity, then resumes with one fairy having created the task and another working on it. The diagram exposes the handoff that the character states make visible.

Visible orchestration among Fairies

Human collaboratorhuman — Selects several fairies and supplies a group task.
Orchestrator fairyagents — Writes a plan and assigns the task.
Worker fairyagents — Performs the assigned canvas work.
Visible agent statesinterface — Characters show working, waiting, or bored states without requiring chat-log inspection.
Review stepagents — Completion prompts the orchestrator to inspect the work.
Selecting multiple agents creates a group conversation; an orchestrator delegates work, waits, and later reviews the result while each fairy displays its state on the canvas.
Read the diagram as text
  • Human collaborator. human — Selects several fairies and supplies a group task.
  • Orchestrator fairy. agents — Writes a plan and assigns the task.
  • Worker fairy. agents — Performs the assigned canvas work.
  • Visible agent states. interface — Characters show working, waiting, or bored states without requiring chat-log inspection.
  • Review step. agents — Completion prompts the orchestrator to inspect the work.
  • Human collaborator → Orchestrator fairy: group prompt.
  • Orchestrator fairy → Worker fairy: assigns task.
  • Orchestrator fairy → Visible agent states: shows waiting.
  • Worker fairy → Visible agent states: shows working.
  • Worker fairy → Review step: completion notification.
  • Review step → Orchestrator fairy: prompts review.
Suggest correction

This note stays in this page until you copy or download it. Nothing is submitted; reloading clears the draft.

7:48 · section reference included

A dependency graph where the nodes do the work

Fairies reveal their main architectural limitation next: they are “trapped in the canvas.” Building with them requires opting into a canvas-native harness, which makes it harder to reach files, repositories, pull requests, and other systems outside the board. The next experiments preserve the spatial coordination interface while letting existing coding agents perform work in their normal environments. 11:20

Selected presentation frame from The Spatial Harness: Bringing Agents to the Canvas — Max Drake, tldraw at 759 secondsOpen full source frame
A dependency graph where the nodes do the work

The motivation comes from tldraw’s launch process. As deadlines tighten, the team abandons ordinary task tracking and makes a large dependency graph on a regular tldraw board. Arrows show what blocks what; color shows completed work; the whole board exposes what is in progress and what can happen next. Its value comes from combining movable, informal shapes with a high-level view of project topology. 12:20

The Tech Tree app makes each node executable. A task is also a coding agent that can be started and allowed to work autonomously. In the demonstration, one node has finished gesture controls for a multimodal canvas application. Drake opens the resulting pull request, inspects the result briefly, merges it, and the graph marks that task complete. The visible state change—from an active task node to a completed one—comes from repository work performed behind the interface. 13:20

New work can also begin spatially. Drake draws directly on the canvas, wraps the drawing as a task called “facial animation canvas control,” assigns it to Claude, and presses Run. This treats a sketch or selected region as the task’s input rather than requiring the user to translate everything into a separate chat. The graph remains a management layer above the agents: nodes carry work and status, while edges retain dependency information. 14:20

How does a task move from the board into repository work and back? The diagram follows the demonstrated route: a person starts a task node, a coding agent produces a pull request, and merging the result leads to a completed node. Multiplayer makes this a shared project space. A colleague can join, add or edit tasks, and inspect work already in progress, coordinating people with agents through the same graph.

The Tech Tree connects spatial planning to repository work

Shared dependency graphcanvas — Shows tasks, blockers, progress, and completed work.
Runnable task nodecanvas — Contains a task derived from text or a drawing.
Coding agentexecution — Executes the assigned implementation outside the canvas.
Pull requestrepository — Returns an inspectable implementation result.
Completed nodecanvas — The graph updates after the work is accepted.
Human collaboratorhuman — Can join, add tasks, edit the graph, and inspect progress.
Canvas nodes expose task state and dependencies; each node can launch a coding agent and return repository results to the shared graph.
Read the diagram as text
  • Shared dependency graph. canvas — Shows tasks, blockers, progress, and completed work.
  • Runnable task node. canvas — Contains a task derived from text or a drawing.
  • Coding agent. execution — Executes the assigned implementation outside the canvas.
  • Pull request. repository — Returns an inspectable implementation result.
  • Completed node. canvas — The graph updates after the work is accepted.
  • Human collaborator. human — Can join, add tasks, edit the graph, and inspect progress.
  • Shared dependency graph → Runnable task node: represents work and dependencies.
  • Runnable task node → Coding agent: manual assign and run.
  • Coding agent → Pull request: implements change.
  • Pull request → Completed node: merge updates status.
  • Human collaborator → Shared dependency graph: edits and observes.
Suggest correction

This note stays in this page until you copy or download it. Nothing is submitted; reloading clears the draft.

11:20 · section reference included

The desktop editor becomes a scripting environment

The opening demo returns after thirteen minutes without the requested fluid simulation. That miss matters: access to email, a specification, files, and an editor does not guarantee timely completion. Rather than hiding it, Drake uses the unfinished run to explain the mechanism underneath. The tldraw desktop app runs locally and exposes its live editor instance through a server, allowing an agent such as Claude Code to write ordinary JavaScript against the editor. The canvas becomes a programmable environment rather than a sealed agent application. 15:20

This arrangement preserves the agent’s access to the wider computer. In one colleague’s experiment, rectangles drawn in tldraw become controls for arranging real desktop windows. The coding agent creates the canvas geometry and uses an external automation mechanism to move the applications; Drake suggests AppleScript as a possibility but does not establish the implementation. The important connection is supported: the canvas supplies an ephemeral spatial interface, while the coding agent reaches beyond it to operate the desktop. 16:28

The most gleefully excessive example is Pong played with desktop windows. tldraw runs in a corner while actual application windows act as game objects. It is silly in exactly the useful way: it demonstrates that canvas primitives can define an interface without confining the action to canvas shapes. A temporary spatial UI can control files, windows, or other resources available to the external agent. 16:59

What bridge lets a drawing become an action elsewhere on the computer? The editor server exposes programmable canvas state to the coding agent; the agent combines JavaScript against tldraw with whatever computer access its environment provides. The diagram separates those two connections. The editor connection changes canvas geometry, while the computer connection applies external actions. Instead of putting the entire agent harness inside the canvas, the existing agent gains a spatial interface it can script.

The opening agent did make partial progress: it accessed Gmail and found the Notion document and its specification. Implementation remained the intended next step in Drake’s account, and the simulation was still unfinished as the talk ended. The closing claim is an interface direction: the canvas can become a shared place where people and agents inspect one another’s work, coordinate spatially, and connect that visible work to real tools and data. 17:29

From a programmable canvas to desktop effects

tldraw desktop canvasinterface — Provides shapes, layout, selection, and other spatial primitives.
Exposed editor instancebridge — A local server makes the running editor programmable.
Coding agentexecution — Writes JavaScript against the editor and retains access to the computer.
Files and desktop applicationsexternal — Supply specifications, local data, and real windows to manipulate.
Ephemeral spatial interfaceoutput — Canvas geometry controls a window manager or desktop Pong.
The desktop app exposes its editor to an existing coding agent. The agent can script canvas objects and use its broader computer access to connect those objects to files or application windows.
Read the diagram as text
  • tldraw desktop canvas. interface — Provides shapes, layout, selection, and other spatial primitives.
  • Exposed editor instance. bridge — A local server makes the running editor programmable.
  • Coding agent. execution — Writes JavaScript against the editor and retains access to the computer.
  • Files and desktop applications. external — Supply specifications, local data, and real windows to manipulate.
  • Ephemeral spatial interface. output — Canvas geometry controls a window manager or desktop Pong.
  • tldraw desktop canvas → Exposed editor instance: live state.
  • Exposed editor instance → Coding agent: JavaScript interface.
  • Files and desktop applications → Coding agent: files, data, and application access.
  • Coding agent → tldraw desktop canvas: creates and updates geometry.
  • Coding agent → Files and desktop applications: applies external actions.
  • tldraw desktop canvas → Ephemeral spatial interface: defines spatial controls.
  • Files and desktop applications → Ephemeral spatial interface: supplies real windows and effects.
Suggest correction

This note stays in this page until you copy or download it. Nothing is submitted; reloading clears the draft.

14:50 · section reference included

Resources

  • LLMs and Spatial CanvasesArticle

    Drake’s earlier essay develops spatial querying, movable analysis zones, and ways to use canvas organization as input to model operations. It supplies interaction examples behind the talk’s idea of a canvas as a place to work.

Transcript & slides

Loading transcript and slides…

Transcript download