S16: spike before the swarm (about a day) #36

Open
opened 2026-10-02 04:07:04 +00:00 by jhgaylor · 0 comments
Owner

Blocks: #37, #38, #39, #40

Swarm track: one live view of every pane on every machine. Panes form clusters on their own, and anything that needs you lifts out to a "needs you" rail. Today the page shows one host's tabs at a time, and attention is a four-state badge per tab. This spike measures what the rest of the track needs.


  • Summary cost on the daemon:
    • At M9's benchmark scale (500 panes on geek), what does a per-pane summary cost to keep and to send? The summary is cwd, command, running, attention, current/last command, bytes per second, and last output time.
    • Today every change sends the whole State. Measure that at 500 panes against field-level deltas batched to 1–2 Hz.
    • Measure bytes per second over the M18 relay with 10% of panes busy.
  • Activity signal: what does an output-rate EMA and last_output_ms cost when kept in the PTY reader? Does it wake parked panes (M9)?
  • Previews: what does rendering the last 6 lines of a pane from the VT grid cost (as /api/panes/{id}/capture does), at 1 Hz, for 50 visible panes? Compare that with sending output bytes and rendering on the client.
  • Classification: run heuristics over geek's and jake-mini's real panes, then hand-check them:
    • kind (shell, build, test, agent, server, logs, editor, or a block type) from the foreground command and process tree (procinfo.rs);
    • project from the cwd's git root.
  • Fleet connections: one browser holding summary connections to 5 and to 20 daemons at once, each its own Noise channel (direct, dial-out and relay). Check memory, reconnect storms after a laptop sleeps, and Chrome's Local Network Access prompt for many tailnet hosts.
  • Rendering: the prototype's canvas renderer, measured at 500, 2,000 and 5,000 panes on the laptop and a mid-range phone. Is Canvas 2D enough, or does it need WebGL?

Output: a short write-up in spikes/s16-swarm/, with numbers for each item and go/no-go on delta summaries, server-side previews and Canvas 2D.

**Blocks:** #37, #38, #39, #40 *Swarm track: one live view of every pane on every machine. Panes form clusters on their own, and anything that needs you lifts out to a "needs you" rail. Today the page shows one host's tabs at a time, and attention is a four-state badge per tab. This spike measures what the rest of the track needs.* -------- - **Summary cost on the daemon:** - At M9's benchmark scale (500 panes on geek), what does a per-pane summary cost to keep and to send? The summary is cwd, command, `running`, attention, `current`/`last` command, bytes per second, and last output time. - Today every change sends the whole `State`. Measure that at 500 panes against field-level deltas batched to 1–2 Hz. - Measure bytes per second over the M18 relay with 10% of panes busy. - **Activity signal:** what does an output-rate EMA and `last_output_ms` cost when kept in the PTY reader? Does it wake parked panes (M9)? - **Previews:** what does rendering the last 6 lines of a pane from the VT grid cost (as `/api/panes/{id}/capture` does), at 1 Hz, for 50 visible panes? Compare that with sending output bytes and rendering on the client. - **Classification:** run heuristics over geek's and jake-mini's real panes, then hand-check them: - **kind** (shell, build, test, agent, server, logs, editor, or a block type) from the foreground command and process tree (`procinfo.rs`); - **project** from the cwd's git root. - **Fleet connections:** one browser holding summary connections to 5 and to 20 daemons at once, each its own Noise channel (direct, dial-out and relay). Check memory, reconnect storms after a laptop sleeps, and Chrome's Local Network Access prompt for many tailnet hosts. - **Rendering:** the prototype's canvas renderer, measured at 500, 2,000 and 5,000 panes on the laptop and a mid-range phone. Is Canvas 2D enough, or does it need WebGL? **Output:** a short write-up in `spikes/s16-swarm/`, with numbers for each item and go/no-go on delta summaries, server-side previews and Canvas 2D.
Sign in to join this conversation.
No description provided.