Repository navigation
Performance baseline: measure current smoothness (help wanted) #356
Description
Why
We do not know how smooth FlyBot actually is. A repo search found no performance baseline or perf issues (only E2E-related #204 and #324). Before optimizing anything, we need measured numbers on real machines. This issue asks for volunteers to measure the current state and report it.
What to measure (personal mode)
Record machine (OS, CPU, RAM), FlyBot version/commit, and model used, then:
- Cold start: launch to the first message being sendable.
- First-message latency: send to first streamed token (with a fast model, to separate FlyBot overhead from model time).
- Streaming: does the input box stay responsive while text streams; does scroll jump?
- Long session: a chat with 500+ messages and many tool calls: scroll smoothness, memory after 30 min, time to reopen it.
- Background tab: hide the page for 5 min, return: does it recover (cf. Timeline panel stays on Loading… in a background tab (hidden page never does the first fetch) #259)?
- Concurrency: run 3 and 6 Bots at once (tree example): total time, CPU/RAM, any stalls.
- Timeline on: enable the plugin and repeat 4 and 6; note the overhead.
- Slow or failing network: throttle or drop the model API: are waiting, timeout and retry messages clear, or is it a blank screen?
What to measure (team mode, two or more instances once available, #352)
- Approval latency: from trigger to the card appearing at the other person.
- Many tasks: 200+ cards on the board ([Feature RFC] Agent inbox board: one place for tasks, approvals and failures (personal first, team second) #349): load time and scroll.
- Cross-instance retry: kill one side mid-task: is work duplicated or lost ([Team] Recover task handoffs without duplicate work #55)?
How to report
Comment with a small table: scenario, number (ms, fps, MB or subjective), machine, and a screen recording or trace for anything that feels slow. Mark each item fine / noticeable / bad. No tokens or personal content in recordings.
Output of this issue
- A baseline table in the issue body, updated from the comments.
- 4-5 key metrics chosen from it, to record on each daily tag (Release cadence: at least one tag per day, small and stable #351) so regressions show up.
- Follow-up issues only for items marked
bad.
Process (2026-10-21)
Implemented by an agent from the spec in the triage comment of 2026-10-21; that comment is the spec of record and wins where it differs from the text above. Reviewed per .github/agent/review-policy.json — no Codex review. The earlier sentence about volunteers measuring manually and "cloud OpenCode with Codex review" is void; it predates the owner decision of 2026-10-19.
Activity
Birfy commentedon Oct 19, 2026
Triage on main
7b9e90b, 2026-10-19 ~12:10 Asia/Shanghai: needs-human, not agent-ready. Question for the owner: which metrics and which machine define the baseline? Without that a measurement cannot be checked.Birfy commentedon Oct 21, 2026
Triage (2026-10-21):
agent-ready. The question that parked this ("which metrics, which machine") is now decided by the owner: measure on the maintenance box itself (Node 24, same container), four metrics only, and ship a reproducible script plus one baseline table. One item at a time — this is the first.Metrics (all on a mock bench via
core/dev/bench.sh,DEEPSEEK_API_KEY=mock-key, no real model)turn/end, from the same session events the activity feed folds (includes the mock delay;MOCK_DELAY_MSfixed).tool/call→tool/resultper call.VmRSSof thedshweb process (pid file in.dsh-test-<name>/web.pid): after ready, after warm-up, at the end; report the peak.dsh web: httpline inweb.log(covers every plugin's install).Acceptance criteria
node core/dev/perf-baseline.mjs <bench-name> <port> --out <file.json>on a freshly reset bench,TZ=UTC, 3 warm-up + 20 measured turns, each turn one message to the Chief's own chat that triggers one tool call. Exits non-zero if the bench is down or a turn times out, and leaves no process of its own behind.{ machine, commit, node, scenarios: [{ metric, unit, samples, p50, p95, peak }] }plus one markdown table row, so two runs diff cleanly.docs/performance-baseline.mdholds each metric's one-sentence definition, the exact command, and one real run on the maintenance box with machine line (OS, CPU, RAM), commit SHA, Node version, date. No thresholds yet: a baseline, not a gate.core/test/perf-baseline.test.jscovers nearest-rank p50/p95 (n=1, odd and even n), the JSON schema and the markdown row, so the numbers are not untested code.core/src/**, no DSH patch, writes only to.dsh-test-<name>/and the paths below.Change scope
core/dev/perf-baseline.mjsdocs/performance-baseline.mddocs/subsystems/ds-bot-core.md(ownscore/dev/, required by the arch-doc check)core/test/perf-baseline.test.jsOut of scope for this pass: the UI smoothness items (items 1–8) and team mode (9–11) — they stay follow-ups until there is a baseline.
Reproduce
Birfy commentedon Oct 21, 2026
Triage spec (2026-10-21, main
16f50984).Acceptance for a PR
core/dev/perf-baseline.mjsruns the measurable scenarios on the existing bench (core/dev/bench.sh+ the scripted model): cold start, first-message latency (model isolated), streaming responsiveness, a 500+ message session reopen, background-tab recovery.fine / noticeable / badmark.docs/performance.mdrecords the machine, the first baseline numbers, and how to rerun.Scope:
core/dev/perf-baseline.mjs(new),docs/performance.md(new), one rootpackage.jsonscript. No product code.Gate: NOT agent-ready yet — the issue asks for numbers on real machines, and a container + mock-model run is a different baseline. Blocking: the owner decides whether the container + mock-model baseline counts as the engineering baseline (real-machine numbers stay welcome as comments). If yes, this becomes the first item for Dev.
Birfy commentedon Oct 21, 2026
Correction to the gate line above (concurrent maintenance call): the maintenance round recorded the owner decision at 09:53 — maintenance box / same container, Node 24, four metrics, reproducible script plus one baseline table. So this is
agent-readyand ordered first for Dev; the "NOT agent-ready yet" sentence is superseded. Keep the acceptance and scope above, run it on the bench, and write the numbers intodocs/performance.mdwithout claiming a real-machine baseline.Birfy commentedon Oct 21, 2026
汇总(2026-10-21):本 issue 现在保持
needs-human,不是agent-ready。core/dev/perf-baseline.mjs、docs/performance-baseline.md、core/test/perf-baseline.test.js、docs/subsystems/ds-bot-core.md)。needs-human;拍板后要么按 (a) 转agent-ready,要么按 (b) 改写测量方案。Dev 侧本期全机 shell 不可用,不催它。Birfy commentedon Oct 21, 2026
Final triage state (Chief decision this round, 2026-10-21):
agent-ready, first in the Dev order. The earlier "needs-human pending the user's a/b choice" is superseded: the Chief fixed option (a) — run on the maintenance box (Node 24, same container) and deliver a reproducible script plus one baseline table. Metrics fixed by the Chief: turn end-to-end p50/p95, tool-call latency, resident RSS, plugin load time. The 09:53 spec is the spec of record; keep the acceptance/scope there. One item at a time: #358, #471, #355 follow.Birfy commentedon Oct 21, 2026
收口(2026-10-21,更正上一条的卡点口径)
bash报 sandbox 后端不可用),要等用户批danger-full-access/bubblewrap;在此之前 Dev 开不了工。docs/performance-baseline.md的基线表不设阈值(是基线,不是门)。needs-human;沙箱放开后再放agent-ready,不提前标。Birfy commentedon Oct 21, 2026
Dev-side blocker (per the Lead):
blocked: host has no usable workspace-write sandbox backend; Dev needs the user to approve danger-full-access (or install bubblewrap) before it can run the script/tests. The issue staysagent-ready; this is environmental, not missing information.Birfy commentedon Oct 21, 2026
Blocked 注记(2026-10-21):本 issue 的规格已定(以 09:53 那条为准,机器 = 维护轮这台、Node 24、同容器,四项指标,基线表不设阈值),当前只卡沙箱:host 没有可用的 sandbox backend(
bash直接报 workspace-write 后端不可用),要等用户批准danger-full-access/bubblewrap。批准前 Dev 只能做只读准备,不放agent-ready。Birfy commentedon Oct 21, 2026
State aligned with the Chief:
needs-humanwhile the user's sandbox authorization card is open — the spec and acceptance above stand. Blocking: the user (approve danger-full-access, or install bubblewrap); the moment the card is approved this flips back toagent-readyand Dev claims it. This is an environment block, not missing information.