@huseynsnmz/pi-board 0.0.0-stage → 0.14.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +256 -0
- package/IMPLEMENTATION_PLAN.md +920 -0
- package/LICENSE +21 -0
- package/PRD.md +484 -0
- package/PROGRESS.md +142 -0
- package/README.md +439 -2
- package/VERIFY.md +115 -0
- package/docs/BATCH_SELECTION_READ_FLOW.md +277 -0
- package/docs/EXPLORATION.md +187 -0
- package/docs/PTY_ATTACH_IMPLEMENTATION_PLAN.md +581 -0
- package/docs/RELEASE.md +148 -0
- package/docs/superpowers/plans/2026-08-15-screenlog-gc.md +704 -0
- package/docs/superpowers/plans/2026-08-16-attach-double-cursor-jiggle-retry.md +499 -0
- package/docs/superpowers/plans/2026-08-21-attach-coldstart-jiggle-rearm.md +797 -0
- package/docs/superpowers/plans/2026-08-21-dashboard-keypress-lag.md +366 -0
- package/docs/superpowers/plans/2026-08-21-issue-14-needs-input-no-auto-done.md +576 -0
- package/docs/superpowers/plans/2026-08-22-jiggle-shrink-and-hold.md +337 -0
- package/docs/superpowers/plans/2026-08-22-launch-cwd-favorites.md +916 -0
- package/docs/superpowers/plans/2026-08-22-question-tool-grouping.md +211 -0
- package/docs/superpowers/plans/2026-08-22-rename-state-labels.md +182 -0
- package/docs/superpowers/plans/2026-08-22-stable-list-order.md +51 -0
- package/docs/superpowers/plans/2026-08-27-locks-acquirelock-spin.md +614 -0
- package/docs/superpowers/plans/2026-08-27-pty-runner-test-flaky.md +32 -0
- package/docs/superpowers/plans/2026-08-29-code-refs-badges.md +223 -0
- package/docs/superpowers/plans/2026-08-30-circular-navigation.md +308 -0
- package/docs/superpowers/plans/2026-08-30-post-exit-timing-fix.md +37 -0
- package/docs/superpowers/plans/2026-08-30-pty-attach-quality-debt.md +311 -0
- package/docs/superpowers/plans/2026-08-30-readme-v2.md +294 -0
- package/docs/superpowers/plans/2026-09-01-attach-detach-gate-cursor-anchor.md +284 -0
- package/docs/superpowers/plans/2026-09-02-attach-detach-editor-state.md +722 -0
- package/docs/superpowers/plans/2026-09-03-code-refs-pr-backlink-narrow.md +551 -0
- package/docs/superpowers/plans/2026-09-03-detach-gate-glyph-fallback.md +146 -0
- package/docs/superpowers/plans/2026-09-04-evidence-outputpreview.md +209 -0
- package/docs/superpowers/plans/2026-09-04-warm-host-reclaim.md +796 -0
- package/docs/superpowers/plans/2026-09-05-issue-13-drainnextfollowup-pty-probe.md +114 -0
- package/docs/superpowers/plans/2026-09-05-issue-38-windows-wezterm-ime-cursor.md +73 -0
- package/docs/superpowers/plans/2026-09-05-issue-39-truncate-codepoint-boundary.md +143 -0
- package/docs/superpowers/plans/2026-09-05-issue-61-mention-fallback-guards.md +226 -0
- package/docs/superpowers/plans/2026-09-05-issue-63-flaky-manual-completion.md +87 -0
- package/docs/superpowers/plans/2026-09-05-issue-64-changelog-release-helper.md +53 -0
- package/docs/superpowers/plans/2026-09-05-pty-host-stacking-sock-race.md +731 -0
- package/docs/superpowers/plans/2026-09-08-attach-ctrl-left-detach.md +30 -0
- package/docs/superpowers/plans/2026-09-08-dashboard-shrink-repaint.md +68 -0
- package/docs/superpowers/plans/2026-09-08-issue-11-attach-runtime-desync-heal.md +917 -0
- package/docs/superpowers/plans/2026-09-08-legacy-stale-host-recovery.md +125 -0
- package/docs/superpowers/plans/2026-09-08-spawn-async-error-swallow.md +56 -0
- package/docs/superpowers/plans/2026-09-08-stale-model-attach-guard.md +96 -0
- package/docs/superpowers/plans/2026-09-09-claimpid-blocks-replace.md +267 -0
- package/docs/superpowers/plans/2026-09-09-harden-runner-architecture.md +603 -0
- package/docs/superpowers/plans/2026-09-09-single-writer-completion.md +252 -0
- package/docs/superpowers/plans/2026-09-10-reader-consistency.md +115 -0
- package/docs/superpowers/plans/2026-09-14-attach-cursor-dectcem-gate.md +469 -0
- package/docs/superpowers/plans/2026-09-14-attach-snapshot.md +92 -0
- package/docs/superpowers/plans/2026-09-14-host-meta-orphan-lock.md +771 -0
- package/docs/superpowers/plans/2026-09-14-issue-106-terminal-frame-cognition.md +299 -0
- package/docs/superpowers/plans/2026-09-14-issue-113-foreground-preview-race.md +609 -0
- package/docs/superpowers/plans/2026-09-14-terminal-model.md +145 -0
- package/docs/superpowers/plans/2026-09-15-coordinator-pipe-root-normalize.md +224 -0
- package/docs/superpowers/plans/2026-09-15-lease-publish-eprem-reclaim.md +341 -0
- package/docs/superpowers/plans/2026-09-18-detach-anchor-reporter-endpoint.md +875 -0
- package/docs/superpowers/plans/2026-09-20-control-lifecycle.md +116 -0
- package/docs/superpowers/plans/2026-09-20-issue-121-perf-gate-out-of-coverage.md +517 -0
- package/docs/superpowers/plans/2026-09-23-a5-mid-stream-assertion.md +25 -0
- package/docs/superpowers/plans/2026-09-23-cwd-browse-tab-drill.md +393 -0
- package/docs/superpowers/plans/2026-09-23-terminal-query-forwarding.md +51 -0
- package/docs/superpowers/plans/2026-09-23-unconditional-detach-key.md +58 -0
- package/docs/superpowers/plans/2026-09-24-control-reconcile-flake.md +698 -0
- package/docs/superpowers/plans/2026-09-24-probe-attached-clients.md +605 -0
- package/docs/superpowers/plans/2026-09-29-issue-145-holding-semantic-state.md +1183 -0
- package/docs/superpowers/plans/2026-09-29-issue-145-user-verification.md +66 -0
- package/docs/superpowers/plans/2026-09-30-board-delete-key-x-y-confirm.md +649 -0
- package/docs/superpowers/plans/2026-09-30-issue-153-runner-stop-boot-window.md +618 -0
- package/docs/superpowers/plans/2026-09-30-issue-95-test-discipline.md +555 -0
- package/docs/superpowers/plans/2026-09-30-publish-dispatch-tag-check.md +259 -0
- package/docs/superpowers/plans/2026-10-06-attach-settle-scheme-delivery.md +751 -0
- package/docs/superpowers/plans/2026-10-09-issue-167-attach-middle-paste.md +509 -0
- package/docs/superpowers/plans/2026-10-09-issue-169-fullscreen-mouse-ownership.md +346 -0
- package/docs/superpowers/plans/2026-10-10-attach-delete-in-place.md +832 -0
- package/docs/superpowers/plans/2026-10-10-issue-174-selection-mirror-paste-source.md +510 -0
- package/docs/superpowers/plans/2026-10-14-issue-170-attach-reply-guard.md +771 -0
- package/docs/superpowers/plans/2026-10-14-issue-178-accept-registration-race.md +1257 -0
- package/docs/superpowers/plans/2026-10-14-issue-184-snapshot-window-contract.md +657 -0
- package/docs/superpowers/plans/2026-10-14-issue-185-attach-wheel-alt-screen.md +47 -0
- package/docs/superpowers/plans/2026-10-14-issue-187-motionless-drag.md +931 -0
- package/docs/superpowers/plans/2026-10-14-issue-189-mixed-input-segments.md +823 -0
- package/docs/superpowers/plans/2026-10-15-issue-188-x10-mouse-release.md +526 -0
- package/docs/superpowers/plans/2026-10-16-issue-198-attach-wheel-forward-fallback.md +32 -0
- package/docs/superpowers/plans/2026-10-18-attach-wheel-replay-pseudo-scrollback.md +437 -0
- package/docs/superpowers/plans/2026-10-19-issue-213-reply-guard-csi-key.md +257 -0
- package/docs/superpowers/plans/2026-10-19-issue-214-attach-forward-alt-modifier.md +202 -0
- package/docs/superpowers/plans/2026-10-21-issue-221-ask-user-question.md +198 -0
- package/docs/superpowers/plans/2026-10-23-issue-222-attach-ready.md +290 -0
- package/docs/superpowers/plans/2026-10-23-issue-225-monotonic-foreground-state.md +450 -0
- package/docs/superpowers/plans/2026-10-23-issue-229-vim-jkl.md +449 -0
- package/docs/superpowers/plans/2026-10-23-issue-232-attach-bg-only-cells.md +153 -0
- package/docs/superpowers/plans/2026-10-23-lease-heartbeat-staleness.md +537 -0
- package/docs/superpowers/plans/2026-10-23-selected-row-highlight.md +405 -0
- package/docs/superpowers/plans/2026-10-24-issue-217-windows-pid-reuse-stopping.md +367 -0
- package/docs/superpowers/plans/2026-10-24-issue-230-warm-host-background-runs.md +806 -0
- package/docs/superpowers/plans/2026-10-24-issue-238-windows-process-identity-token.md +490 -0
- package/docs/superpowers/plans/2026-10-24-issue-241-coordinator-root-exit.md +461 -0
- package/docs/superpowers/plans/2026-10-25-issue-239-coordinator-replacement-identity.md +504 -0
- package/docs/superpowers/plans/2026-10-26-issue-245-key-hints-doc-sync.md +244 -0
- package/docs/superpowers/plans/2026-10-27-issue-172-fullscreen-selection-clear.md +344 -0
- package/docs/superpowers/plans/2026-10-27-issue-252-select-key-hints.md +209 -0
- package/docs/superpowers/plans/2026-10-28-issue-255-coordinator-endpoint-zombie.md +442 -0
- package/docs/superpowers/plans/2026-10-28-issue-257-legacy-pty-runner-endpoint-cleanup.md +256 -0
- package/docs/superpowers/plans/2026-11-03-cwd-favorites-full-pool.md +266 -0
- package/docs/superpowers/specs/2026-08-15-screenlog-gc-design.md +105 -0
- package/docs/superpowers/specs/2026-08-16-attach-double-cursor-jiggle-retry-design.md +142 -0
- package/docs/superpowers/specs/2026-08-21-attach-coldstart-jiggle-rearm-design.md +110 -0
- package/docs/superpowers/specs/2026-08-21-dashboard-keypress-lag-design.md +59 -0
- package/docs/superpowers/specs/2026-08-21-issue-14-needs-input-no-auto-done-design.md +109 -0
- package/docs/superpowers/specs/2026-08-22-cwd-favorites-design.md +131 -0
- package/docs/superpowers/specs/2026-08-22-jiggle-shrink-and-hold-design.md +111 -0
- package/docs/superpowers/specs/2026-08-22-question-tool-grouping-design.md +114 -0
- package/docs/superpowers/specs/2026-08-22-rename-state-labels-design.md +80 -0
- package/docs/superpowers/specs/2026-08-27-locks-acquirelock-spin-design.md +97 -0
- package/docs/superpowers/specs/2026-08-27-pty-runner-test-flaky-design.md +35 -0
- package/docs/superpowers/specs/2026-08-29-code-refs-badges-design.md +128 -0
- package/docs/superpowers/specs/2026-08-30-circular-navigation-design.md +47 -0
- package/docs/superpowers/specs/2026-08-30-eprm-atomicwrite-race-design.md +77 -0
- package/docs/superpowers/specs/2026-08-30-post-exit-timing-fix-design.md +80 -0
- package/docs/superpowers/specs/2026-08-30-pty-attach-quality-debt-design.md +105 -0
- package/docs/superpowers/specs/2026-08-30-readme-v2-design.md +115 -0
- package/docs/superpowers/specs/2026-09-01-attach-detach-gate-cursor-anchor-design.md +78 -0
- package/docs/superpowers/specs/2026-09-02-attach-detach-editor-state-design.md +120 -0
- package/docs/superpowers/specs/2026-09-03-code-refs-pr-backlink-narrow-design.md +92 -0
- package/docs/superpowers/specs/2026-09-03-detach-gate-glyph-fallback-design.md +99 -0
- package/docs/superpowers/specs/2026-09-04-evidence-outputpreview-design.md +50 -0
- package/docs/superpowers/specs/2026-09-04-warm-host-reclaim-design.md +106 -0
- package/docs/superpowers/specs/2026-09-05-issue-13-drainnextfollowup-pty-probe-design.md +64 -0
- package/docs/superpowers/specs/2026-09-05-issue-38-windows-wezterm-ime-design.md +48 -0
- package/docs/superpowers/specs/2026-09-05-issue-39-truncate-codepoint-boundary-design.md +64 -0
- package/docs/superpowers/specs/2026-09-05-issue-61-mention-fallback-design.md +71 -0
- package/docs/superpowers/specs/2026-09-05-issue-63-flaky-manual-completion-design.md +49 -0
- package/docs/superpowers/specs/2026-09-05-issue-64-changelog-helper-design.md +76 -0
- package/docs/superpowers/specs/2026-09-05-pty-host-stacking-sock-race-design.md +510 -0
- package/docs/superpowers/specs/2026-09-07-issue-11-attach-runtime-desync-heal-design.md +130 -0
- package/docs/superpowers/specs/2026-09-08-attach-ctrl-left-detach-design.md +58 -0
- package/docs/superpowers/specs/2026-09-08-dashboard-shrink-repaint-design.md +52 -0
- package/docs/superpowers/specs/2026-09-08-legacy-stale-host-recovery-design.md +87 -0
- package/docs/superpowers/specs/2026-09-08-spawn-async-error-swallow-design.md +56 -0
- package/docs/superpowers/specs/2026-09-08-stale-model-attach-guard-design.md +79 -0
- package/docs/superpowers/specs/2026-09-09-claimpid-blocks-replace-design.md +147 -0
- package/docs/superpowers/specs/2026-09-09-harden-runner-architecture-design.md +304 -0
- package/docs/superpowers/specs/2026-09-14-attach-cursor-dectcem-gate-design.md +114 -0
- package/docs/superpowers/specs/2026-09-14-host-meta-orphan-lock-design.md +120 -0
- package/docs/superpowers/specs/2026-09-14-issue-106-terminal-frame-cognition-design.md +146 -0
- package/docs/superpowers/specs/2026-09-14-issue-113-foreground-preview-race-design.md +116 -0
- package/docs/superpowers/specs/2026-09-15-coordinator-pipe-root-normalize-design.md +84 -0
- package/docs/superpowers/specs/2026-09-15-lease-publish-eprem-reclaim-design.md +92 -0
- package/docs/superpowers/specs/2026-09-18-detach-anchor-reporter-endpoint-design.md +123 -0
- package/docs/superpowers/specs/2026-09-20-issue-121-perf-gate-out-of-coverage-design.md +204 -0
- package/docs/superpowers/specs/2026-09-23-a5-mid-stream-assertion-design.md +43 -0
- package/docs/superpowers/specs/2026-09-23-cwd-browse-tab-drill-design.md +95 -0
- package/docs/superpowers/specs/2026-09-23-terminal-query-forwarding-design.md +63 -0
- package/docs/superpowers/specs/2026-09-23-unconditional-detach-key-design.md +57 -0
- package/docs/superpowers/specs/2026-09-24-control-reconcile-flake-design.md +98 -0
- package/docs/superpowers/specs/2026-09-24-probe-attached-clients-design.md +190 -0
- package/docs/superpowers/specs/2026-09-29-issue-145-holding-semantic-state-design.md +394 -0
- package/docs/superpowers/specs/2026-09-30-board-delete-key-x-y-confirm-design.md +86 -0
- package/docs/superpowers/specs/2026-09-30-issue-153-runner-stop-boot-window-design.md +75 -0
- package/docs/superpowers/specs/2026-09-30-issue-95-test-discipline-design.md +226 -0
- package/docs/superpowers/specs/2026-09-30-publish-dispatch-tag-check-design.md +129 -0
- package/docs/superpowers/specs/2026-10-06-attach-settle-scheme-delivery-design.md +196 -0
- package/docs/superpowers/specs/2026-10-09-issue-167-attach-middle-paste-design.md +125 -0
- package/docs/superpowers/specs/2026-10-09-issue-169-fullscreen-mouse-ownership-design.md +130 -0
- package/docs/superpowers/specs/2026-10-10-attach-delete-in-place-design.md +224 -0
- package/docs/superpowers/specs/2026-10-10-issue-174-selection-mirror-paste-source-design.md +154 -0
- package/docs/superpowers/specs/2026-10-14-issue-170-attach-reply-guard-design.md +195 -0
- package/docs/superpowers/specs/2026-10-14-issue-178-accept-registration-race-design.md +287 -0
- package/docs/superpowers/specs/2026-10-14-issue-184-snapshot-window-contract-design.md +288 -0
- package/docs/superpowers/specs/2026-10-14-issue-185-attach-wheel-alt-screen-design.md +126 -0
- package/docs/superpowers/specs/2026-10-14-issue-187-motionless-drag-design.md +269 -0
- package/docs/superpowers/specs/2026-10-14-issue-189-mixed-input-segments-design.md +369 -0
- package/docs/superpowers/specs/2026-10-15-issue-188-x10-mouse-release-design.md +252 -0
- package/docs/superpowers/specs/2026-10-16-issue-198-attach-wheel-forward-fallback-design.md +67 -0
- package/docs/superpowers/specs/2026-10-18-attach-wheel-replay-pseudo-scrollback-design.md +250 -0
- package/docs/superpowers/specs/2026-10-19-issue-213-reply-guard-csi-key-design.md +165 -0
- package/docs/superpowers/specs/2026-10-19-issue-214-attach-forward-alt-modifier-design.md +131 -0
- package/docs/superpowers/specs/2026-10-20-issue-221-ask-user-question-design.md +270 -0
- package/docs/superpowers/specs/2026-10-22-issue-225-monotonic-foreground-state-design.md +225 -0
- package/docs/superpowers/specs/2026-10-23-issue-222-attach-ready-design.md +204 -0
- package/docs/superpowers/specs/2026-10-23-issue-229-vim-jkl-design.md +90 -0
- package/docs/superpowers/specs/2026-10-23-issue-232-attach-bg-only-cells-design.md +146 -0
- package/docs/superpowers/specs/2026-10-23-lease-heartbeat-staleness-design.md +271 -0
- package/docs/superpowers/specs/2026-10-23-selected-row-highlight-design.md +191 -0
- package/docs/superpowers/specs/2026-10-24-issue-217-windows-pid-reuse-stopping-design.md +334 -0
- package/docs/superpowers/specs/2026-10-24-issue-230-warm-host-background-runs-design.md +283 -0
- package/docs/superpowers/specs/2026-10-24-issue-238-windows-process-identity-token-design.md +286 -0
- package/docs/superpowers/specs/2026-10-24-issue-241-coordinator-root-exit-design.md +381 -0
- package/docs/superpowers/specs/2026-10-25-issue-239-coordinator-replacement-identity-design.md +331 -0
- package/docs/superpowers/specs/2026-10-26-issue-245-key-hints-doc-sync-design.md +72 -0
- package/docs/superpowers/specs/2026-10-27-issue-172-fullscreen-selection-clear-design.md +248 -0
- package/docs/superpowers/specs/2026-10-27-issue-252-select-key-hints-design.md +95 -0
- package/docs/superpowers/specs/2026-10-28-issue-255-coordinator-endpoint-zombie-design.md +380 -0
- package/docs/superpowers/specs/2026-10-28-issue-257-legacy-pty-runner-endpoint-cleanup-design.md +197 -0
- package/docs/superpowers/specs/2026-11-03-cwd-favorites-full-pool-design.md +106 -0
- package/index.ts +6 -0
- package/package.json +84 -4
- package/runner/job-runner-legacy.mjs +68 -0
- package/runner/job-runner.mjs +834 -0
- package/runner/pty-runner-legacy.mjs +50 -0
- package/runner/pty-runner.mjs +2156 -0
- package/runner/state-coordinator.mjs +673 -0
- package/runner/state-runner.mjs +203 -0
- package/runner/title-runner.mjs +80 -0
- package/scripts/budget-audit.mjs +135 -0
- package/scripts/patch-vulns.mjs +59 -0
- package/scripts/release.mjs +446 -0
- package/scripts/release_helper.mjs +309 -0
- package/scripts/run-perf-gate.mjs +40 -0
- package/scripts/run-tests.mjs +375 -0
- package/src/commands/agent-board.ts +363 -0
- package/src/commands/attach-decision.mjs +66 -0
- package/src/commands/attach-flow.ts +247 -0
- package/src/commands/bg.ts +80 -0
- package/src/core/atomic.mjs +184 -0
- package/src/core/attach-delete.mjs +24 -0
- package/src/core/attach-frame-proof.mjs +862 -0
- package/src/core/attach-frame-reporter.mjs +648 -0
- package/src/core/attach-frame-stream.mjs +266 -0
- package/src/core/attach-view-proof.mjs +709 -0
- package/src/core/auto-state.mjs +377 -0
- package/src/core/background-runs.mjs +273 -0
- package/src/core/code-refs-store.mjs +315 -0
- package/src/core/code-refs.mjs +913 -0
- package/src/core/control-protocol.mjs +482 -0
- package/src/core/coordinator-client.mjs +633 -0
- package/src/core/coordinator-journal.mjs +282 -0
- package/src/core/coordinator-protocol.mjs +14 -0
- package/src/core/cwd-stats.mjs +114 -0
- package/src/core/dashboard-render.mjs +10 -0
- package/src/core/derive.mjs +117 -0
- package/src/core/diagnostics.mjs +133 -0
- package/src/core/double-press.mjs +22 -0
- package/src/core/editor-state-reporter.mjs +112 -0
- package/src/core/events.mjs +286 -0
- package/src/core/evidence.mjs +245 -0
- package/src/core/follow-up-queue.mjs +211 -0
- package/src/core/foreground-preview-cache.mjs +117 -0
- package/src/core/foreground-projection-cache.mjs +99 -0
- package/src/core/frame-witness-update.mjs +35 -0
- package/src/core/heuristics.mjs +313 -0
- package/src/core/host-coordination.mjs +300 -0
- package/src/core/host-crash.mjs +79 -0
- package/src/core/host-probe.mjs +207 -0
- package/src/core/host-protocol.mjs +73 -0
- package/src/core/ids.mjs +35 -0
- package/src/core/ime-cursor-coalesce.mjs +193 -0
- package/src/core/invocation.mjs +43 -0
- package/src/core/launch-options.mjs +418 -0
- package/src/core/launch.mjs +157 -0
- package/src/core/locks.mjs +530 -0
- package/src/core/paths.mjs +183 -0
- package/src/core/pid.mjs +75 -0
- package/src/core/prewarm-schedule.mjs +41 -0
- package/src/core/process-identity-probe.mjs +228 -0
- package/src/core/prompt-transport.mjs +13 -0
- package/src/core/pty-attach-jiggle-controller.mjs +356 -0
- package/src/core/pty-attach-jiggle-retry.mjs +109 -0
- package/src/core/pty-attach-reconnect.mjs +61 -0
- package/src/core/pty-attach-render.mjs +229 -0
- package/src/core/pty-links.mjs +71 -0
- package/src/core/pty-scroll.mjs +522 -0
- package/src/core/pty-support.mjs +327 -0
- package/src/core/repo.mjs +103 -0
- package/src/core/rows.mjs +378 -0
- package/src/core/screen-log-gc.mjs +198 -0
- package/src/core/screen-log.mjs +160 -0
- package/src/core/session-view.mjs +174 -0
- package/src/core/state-commands.mjs +757 -0
- package/src/core/status-consistency.mjs +98 -0
- package/src/core/steering-prompts.mjs +34 -0
- package/src/core/steering.mjs +133 -0
- package/src/core/stop-latch.mjs +41 -0
- package/src/core/store.mjs +523 -0
- package/src/core/terminal-attach-client.mjs +981 -0
- package/src/core/terminal-attach-protocol.mjs +460 -0
- package/src/core/terminal-model.mjs +222 -0
- package/src/core/terminal-query-sequences.mjs +239 -0
- package/src/core/terminal-reply-guard.mjs +222 -0
- package/src/core/terminal-snapshot.mjs +440 -0
- package/src/core/test-knobs.mjs +28 -0
- package/src/core/title.mjs +43 -0
- package/src/core/types.mjs +414 -0
- package/src/core/warm-host-sweeper.mjs +168 -0
- package/src/core/worktree.mjs +65 -0
- package/src/index.ts +274 -0
- package/src/runtime/service.mjs +3183 -0
- package/src/ui/chrome.ts +20 -0
- package/src/ui/dashboard-decisions.mjs +55 -0
- package/src/ui/dashboard-evidence.mjs +85 -0
- package/src/ui/dashboard.ts +2141 -0
- package/src/ui/double-left.ts +36 -0
- package/src/ui/pty-attach.ts +3091 -0
package/README.md
CHANGED
|
@@ -1,3 +1,440 @@
|
|
|
1
|
-
#
|
|
1
|
+
# pi-board
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
<p align="center">
|
|
4
|
+
<img src="https://raw.githubusercontent.com/huseynsnmz/pi-board/main/assets/banner.png" alt="Pi Agent Board" width="100%" />
|
|
5
|
+
</p>
|
|
6
|
+
|
|
7
|
+
<p align="center">
|
|
8
|
+
<a href="https://github.com/huseynsnmz/pi-board/blob/main/assets/demo.mp4"><strong>30s demo</strong></a>
|
|
9
|
+
| <a href="https://pi.dev/packages?name=@huseynsnmz/pi-board">Pi package gallery</a>
|
|
10
|
+
| <a href="https://www.npmjs.com/package/@huseynsnmz/pi-board">npm</a>
|
|
11
|
+
</p>
|
|
12
|
+
|
|
13
|
+
pi-board is a full-screen TUI dashboard for [Pi](https://github.com/earendil-works/pi-mono) that manages durable background Pi sessions. Use one global board to dispatch work across projects, watch progress, triage summaries and evidence, reply without opening a transcript, and attach to a real interactive session when hands-on work is needed.
|
|
14
|
+
|
|
15
|
+
It started as a fork of [`@zhuxixi/pi-agent-board`](https://github.com/zhuxixi/pi-agent-board) 0.13.1, so the design and most of the code are theirs, under the MIT license. The command is still `/agent-board`.
|
|
16
|
+
|
|
17
|
+
## What It Does
|
|
18
|
+
|
|
19
|
+
- Run several Pi tasks at once without losing track of their current state.
|
|
20
|
+
- Keep each task as a real, resumable Pi session that survives `/reload`, closing Pi, or restarting the terminal.
|
|
21
|
+
- Triage the latest output, blockers, evidence, and diagnostics before opening a full transcript.
|
|
22
|
+
- Reply to a session without attaching; replies sent while a session is busy are preserved for later delivery.
|
|
23
|
+
- Fall back to a JSON runner for eligible background work when live PTY support is unavailable.
|
|
24
|
+
|
|
25
|
+
> **Write-safety note:** Worktree isolation is currently disabled. Multiple sessions in the same repository may run concurrently, so avoid overlapping writes or provide your own isolation.
|
|
26
|
+
|
|
27
|
+
## Requirements
|
|
28
|
+
|
|
29
|
+
- [Pi](https://github.com/earendil-works/pi-mono) installed and working.
|
|
30
|
+
- Node.js 20 or newer.
|
|
31
|
+
- Working Pi provider authentication for real model execution. Agent Board does not have a separate login or credential store.
|
|
32
|
+
- PTY support from `node-pty` for live attach and **start & attach**. Background work can use a JSON-runner fallback when PTY support is unavailable.
|
|
33
|
+
|
|
34
|
+
If rows remain in `Running`, first verify that Pi itself can complete a one-shot model call:
|
|
35
|
+
|
|
36
|
+
```bash
|
|
37
|
+
pi --mode json -p --no-session "Reply with exactly: DONE"
|
|
38
|
+
```
|
|
39
|
+
|
|
40
|
+
A healthy command emits an assistant `message_end`, then an `agent_end` event, and exits. See [VERIFY.md](VERIFY.md) for the complete no-auth, provider-auth, and PTY checks.
|
|
41
|
+
|
|
42
|
+
## Install
|
|
43
|
+
|
|
44
|
+
### Published package
|
|
45
|
+
|
|
46
|
+
```bash
|
|
47
|
+
pi install npm:@huseynsnmz/pi-board
|
|
48
|
+
```
|
|
49
|
+
|
|
50
|
+
Start Pi normally and run `/agent-board`, or use one of the startup entry points below.
|
|
51
|
+
|
|
52
|
+
### Local checkout
|
|
53
|
+
|
|
54
|
+
```bash
|
|
55
|
+
npm install
|
|
56
|
+
pi install "$(pwd)"
|
|
57
|
+
```
|
|
58
|
+
|
|
59
|
+
This installs the current checkout as a Pi package. Remove that path installation with:
|
|
60
|
+
|
|
61
|
+
```bash
|
|
62
|
+
pi remove "$(pwd)"
|
|
63
|
+
```
|
|
64
|
+
|
|
65
|
+
### Development auto-discovery
|
|
66
|
+
|
|
67
|
+
To have Pi load the checkout directly while developing:
|
|
68
|
+
|
|
69
|
+
```bash
|
|
70
|
+
ln -s "$(pwd)" ~/.pi/agent/extensions/agent-board
|
|
71
|
+
pi
|
|
72
|
+
```
|
|
73
|
+
|
|
74
|
+
Remove the symlink when you no longer want Pi to auto-load the checkout:
|
|
75
|
+
|
|
76
|
+
```bash
|
|
77
|
+
rm ~/.pi/agent/extensions/agent-board
|
|
78
|
+
```
|
|
79
|
+
|
|
80
|
+
## Quick Start
|
|
81
|
+
|
|
82
|
+
Open the board with `/agent-board` inside Pi, or press `Left` twice on an empty prompt, then:
|
|
83
|
+
|
|
84
|
+
1. Press `i` to enter INSERT mode.
|
|
85
|
+
2. Type a task.
|
|
86
|
+
3. Press `Enter`. It starts right away in the current folder, with this session's model and thinking level.
|
|
87
|
+
|
|
88
|
+
To choose the folder, model or thinking level first, press `Ctrl+N` while typing. With an empty input, `Enter` attaches/resumes the selected session. The row starts in `Queued`, then moves through `Running` to a terminal state such as `Needs answer`, `Needs instructions`, `Done`, `Failed`, or `Stopped`.
|
|
89
|
+
|
|
90
|
+
From the board:
|
|
91
|
+
|
|
92
|
+
- Press `Space` to peek at the selected session's summary, blocker, and latest output.
|
|
93
|
+
- In Peek, press `r` to reply without attaching.
|
|
94
|
+
- Press `v` for a read-only transcript, or `e` for evidence and diagnostics.
|
|
95
|
+
- Press `Enter`, `Right`, or `>` to attach to the real Pi session.
|
|
96
|
+
- In PTY attach mode, press `Ctrl+Left` to return to the board at any time (even mid-draft), or `Ctrl+\` — the unconditional escape: it detaches regardless of editor state on any terminal that forwards the raw 0x1c byte (raw, kitty, and modifyOtherKeys keyboard modes all work). `Left` detaches only while the child Pi reports an empty editor; otherwise (draft, or unknown editor state) it is forwarded to the child. `Ctrl+]` is not a detach key — it is passed through to the child Pi editor. When the host is disconnected, `Left` always exits. `Ctrl+\` caveats: on keyboard layouts where `\` sits on AltGr (e.g. German) the chord may never produce the byte — use `Ctrl+Left` there; in legacy keyboard modes `Ctrl+4` emits the same byte and also detaches; and the key is captured from the child while attached, so the child's own `Ctrl+\` binding (e.g. the vim terminal-mode prefix) is unavailable. Automatic themes also resolve correctly in attach sessions: the child's background probe (OSC 11) and color-scheme change notifications are forwarded to your real terminal, replies flow back to the child when your terminal answers, and attach re-probes the background once when it settles so the theme is right from the first frame. Set `AGENT_BOARD_FORWARD_TERMINAL_QUERIES=0` to disable this (default on); keyboard-protocol negotiation (kitty/DA) is not forwarded — it happens once at child spawn, before attach exists. `Ctrl+X` opens an in-place delete confirm: press `y` (or Enter) to archive the row and return to the board with the next row selected — any other key cancels and is passed through to the session. While attached, the child Pi's own `Ctrl+X` bindings (copy in `/tree` and fullscreen, clear-all in the models dialog) are captured by this gesture.
|
|
97
|
+
|
|
98
|
+
## Dashboard Workflow
|
|
99
|
+
|
|
100
|
+
The dashboard has two input modes:
|
|
101
|
+
|
|
102
|
+
- **Normal mode** owns dashboard shortcuts such as navigation, peek, attach, and filtering.
|
|
103
|
+
- **INSERT mode** owns text editing. Press `i` before typing or pasting a task; `/` is literal while editing a prompt.
|
|
104
|
+
|
|
105
|
+
When you press `Ctrl+N` while typing a task, the **Start session** dialog lets you review:
|
|
106
|
+
|
|
107
|
+
- `cwd`: an existing-directory picker with usage-ranked favorites, filesystem browsing, and Tab completion;
|
|
108
|
+
- `model`: models available to Pi, including models scoped by the current directory's Pi settings;
|
|
109
|
+
- `thinking`: a level supported by the selected model;
|
|
110
|
+
- `action`: **start in background** or **start & attach**.
|
|
111
|
+
|
|
112
|
+
Launch preferences are persisted and reused for later sessions. **Start & attach** requires PTY support; if PTY is unavailable, Agent Board launches the session in the background and shows a warning instead.
|
|
113
|
+
|
|
114
|
+
Session actions are deliberately confirmation-aware:
|
|
115
|
+
|
|
116
|
+
- `d` confirms moving an inactive session to **Done**. Manual completion is the default.
|
|
117
|
+
- `h` toggles the on-hold state (manual verdict — automated writers are fenced).
|
|
118
|
+
- Press `x`, then `y` to confirm deleting the selected row. `Ctrl+X` twice quickly still deletes without confirmation. Archiving removes the row from the board but preserves its underlying Pi session file.
|
|
119
|
+
- `X` archives inactive rows in the selected state; live work is skipped.
|
|
120
|
+
- `m` enters multi-select mode; see [Multi-select](#multi-select) for its keys.
|
|
121
|
+
|
|
122
|
+
## Views and Actions
|
|
123
|
+
|
|
124
|
+
Shortcuts are scoped to the view where they are available:
|
|
125
|
+
|
|
126
|
+
### Main list
|
|
127
|
+
|
|
128
|
+
| Key | Action |
|
|
129
|
+
| --- | --- |
|
|
130
|
+
| `Up` / `Down` / `j` / `k` | Move the selection. |
|
|
131
|
+
| `i` | Enter INSERT mode for a new task. |
|
|
132
|
+
| `Enter` | Start a draft right away, or attach/resume when the input is empty. |
|
|
133
|
+
| `Right` / `>` / `l` | Attach to the selected session. |
|
|
134
|
+
| `Space` | Open Peek. |
|
|
135
|
+
| `v` | Open the read-only transcript. |
|
|
136
|
+
| `e` | Open Evidence / Diagnostics. |
|
|
137
|
+
| `/` | Enter filter mode. |
|
|
138
|
+
| `Ctrl+N` | Enter INSERT mode with a pre-filled `hello` prompt. |
|
|
139
|
+
| `Left` twice | From an empty Pi prompt, open the board. |
|
|
140
|
+
| `Ctrl+R` | Rename the selected session. |
|
|
141
|
+
| `Ctrl+T` | Pin or unpin the selected session. |
|
|
142
|
+
| `Ctrl+S` | Stop the selected active session. |
|
|
143
|
+
| `d` | Confirm marking the selected inactive session Done. |
|
|
144
|
+
| `h` | Hold or unhold the selected inactive session. |
|
|
145
|
+
| `x`, then `y` | Archive/delete the selected row (confirmation prompt). |
|
|
146
|
+
| `Ctrl+X` twice quickly | Archive/delete the selected row without confirmation. |
|
|
147
|
+
| `X` | Delete inactive rows in the selected state. |
|
|
148
|
+
| `m` | Enter multi-select mode. |
|
|
149
|
+
| `!` | Open node-pty diagnostics and fix steps. |
|
|
150
|
+
| `?` | Open the help overlay. |
|
|
151
|
+
| `Esc` | Clear a draft, or exit when the input is empty. |
|
|
152
|
+
|
|
153
|
+
### Multi-select
|
|
154
|
+
|
|
155
|
+
Press `m` in the main list to act on several sessions at once.
|
|
156
|
+
|
|
157
|
+
| Key | Action |
|
|
158
|
+
| --- | --- |
|
|
159
|
+
| `Up` / `Down` / `j` / `k` | Move the selection. |
|
|
160
|
+
| `Space` | Toggle the current row. |
|
|
161
|
+
| `a` | Select all visible rows. |
|
|
162
|
+
| `u` | Clear the selection. |
|
|
163
|
+
| `d` | Confirm marking the selected inactive rows Done. |
|
|
164
|
+
| `Ctrl+X` | Delete the selected Done rows (confirmation prompt). |
|
|
165
|
+
| `m` / `Esc` / `Ctrl+C` | Leave multi-select mode. |
|
|
166
|
+
| `?` | Open the help overlay. |
|
|
167
|
+
| `!` | Open node-pty diagnostics and fix steps. |
|
|
168
|
+
|
|
169
|
+
### Peek
|
|
170
|
+
|
|
171
|
+
Peek shows the selected session's summary, blocker or question, latest output, and available issue/PR references.
|
|
172
|
+
|
|
173
|
+
| Key | Action |
|
|
174
|
+
| --- | --- |
|
|
175
|
+
| `r` or `Enter` | Enter reply mode; type a follow-up and press `Enter` to send it without attaching. |
|
|
176
|
+
| `a`, `Right`, `>`, or `l` | Attach to the session. |
|
|
177
|
+
| `v` | Open the read-only transcript. |
|
|
178
|
+
| `e` | Open Evidence / Diagnostics. |
|
|
179
|
+
| `d` | Confirm marking the inactive session Done. |
|
|
180
|
+
| `h` | Hold or unhold the session. |
|
|
181
|
+
| `!` | Open node-pty diagnostics and fix steps. |
|
|
182
|
+
| `Up` / `Down` / `j` / `k` | Move to the previous or next session. |
|
|
183
|
+
| `Esc` | Return to the main list. |
|
|
184
|
+
|
|
185
|
+
When a Pi question or questionnaire tool is pending, inline reply is rejected; attach to answer that interactive question in the real Pi session.
|
|
186
|
+
|
|
187
|
+
### Transcript
|
|
188
|
+
|
|
189
|
+
The `v` view is a read-only projection of the durable Pi session JSONL. It does not interrupt a running worker.
|
|
190
|
+
|
|
191
|
+
| Key | Action |
|
|
192
|
+
| --- | --- |
|
|
193
|
+
| `Up` / `Down` / `j` / `k` | Scroll one line. |
|
|
194
|
+
| `PageUp` / `PageDown` | Scroll one page. |
|
|
195
|
+
| `Space` | Open Peek. |
|
|
196
|
+
| `r` | Enter reply mode. |
|
|
197
|
+
| `Enter` or `a` | Attach to the session. |
|
|
198
|
+
| `e` | Open Evidence / Diagnostics. |
|
|
199
|
+
| `d` | Confirm marking the inactive session Done. |
|
|
200
|
+
| `h` | Hold or unhold the session. |
|
|
201
|
+
| `!` | Open node-pty diagnostics and fix steps. |
|
|
202
|
+
| `Left` / `Esc` / `<` | Return to the main list. |
|
|
203
|
+
|
|
204
|
+
### Evidence / Diagnostics
|
|
205
|
+
|
|
206
|
+
The `e` view shows durable session evidence, including changed files, commands and their outcomes, command output previews, assistant evidence, errors, diagnostics, and artifact paths. Press `x` to clear diagnostics while preserving the evidence artifacts.
|
|
207
|
+
|
|
208
|
+
| Key | Action |
|
|
209
|
+
| --- | --- |
|
|
210
|
+
| `Up` / `Down` / `j` / `k` | Scroll one line. |
|
|
211
|
+
| `PageUp` / `PageDown` | Scroll one page. |
|
|
212
|
+
| `r` | Enter reply mode. |
|
|
213
|
+
| `v` | Open the read-only transcript. |
|
|
214
|
+
| `Enter`, `a`, `Right`, or `l` | Attach to the session. |
|
|
215
|
+
| `x` | Clear diagnostics; evidence is preserved. |
|
|
216
|
+
| `Left` / `Esc` / `<` | Return to the main list. |
|
|
217
|
+
|
|
218
|
+
### PTY attach
|
|
219
|
+
|
|
220
|
+
PTY attach opens the real interactive Pi session. `Ctrl+Left` detaches and returns to the board regardless of editor state, and `Ctrl+\` is the unconditional escape — a single raw ASCII byte (0x1c) that terminals forward unchanged in raw mode (kitty CSI-u and modifyOtherKeys encodings included), honored no matter what the child editor reports. `Left` detaches only while the child Pi reports an empty editor; while you are editing text — or when the child's editor state is unknown (e.g. the child extension is missing) — `Left` is forwarded to the Pi editor. A disconnected host can always be exited with `Left`. `Ctrl+]` is not a detach key — it is passed through to the child Pi editor. `Ctrl+\` caveats: on keyboard layouts where `\` sits on AltGr (e.g. German) the chord may never produce the byte — use `Ctrl+Left` there; in legacy keyboard modes `Ctrl+4` emits the same byte and also detaches; and the key is captured from the child while attached, so the child's own `Ctrl+\` binding (e.g. the vim terminal-mode prefix) is unavailable. While attached, `PageUp`, `PageDown`, `Home`, `End`, and the mouse wheel scroll local scrollback; whenever that viewport cannot move — the session holds the alternate screen (pi's fullscreen default), or there is no local history to travel — the wheel is forwarded to the session instead, which scrolls its own transcript: the same fallback the paging keys use. The attach viewport only scrolls scrollback the hosted session actually produced: rows that a snapshot hydration had to scroll out of the local window are not history, and the wheel is forwarded to the session instead of consuming those rows. Mouse drag or double-click selects and copies text, clicks open detected links, and middle-click paste is available on systems with the required X11 tooling. `Ctrl+X` opens an in-place delete confirm: press `y` (or Enter) to archive the row and return to the board with the next row selected — any other key cancels and is passed through to the session. While attached, the child Pi's own `Ctrl+X` bindings (copy in `/tree` and fullscreen, clear-all in the models dialog) are captured by this gesture.
|
|
221
|
+
|
|
222
|
+
Automatic light/dark themes work in attach sessions too. The child Pi's background-color probe (OSC 11) and its color-scheme change notification switch are forwarded to your real terminal; replies and notifications flow back to the child when your terminal answers — a terminal that never answers keeps the dark fallback. Attach also re-probes the background once when it settles, so the theme is correct from the first frame without re-selecting it in `/settings`. All of this is on by default; set `AGENT_BOARD_FORWARD_TERMINAL_QUERIES=0` to disable it. Not covered: keyboard-protocol negotiation (kitty flags / DA1) is not forwarded — the child negotiates once at spawn, before any attach client exists, and forwarding it would retune the shared real-terminal keyboard stack — so modifier-key encoding can still differ from a directly-run Pi (the modifyOtherKeys fallback applies).
|
|
223
|
+
|
|
224
|
+
The attach surface can forward terminal clipboard and image/file passthrough sequences. These behaviors can be disabled individually in [Configuration](#configuration). Cold hosts may briefly show a loading/reconnect surface while their PTY becomes ready.
|
|
225
|
+
|
|
226
|
+
## States, Grouping, and Filters
|
|
227
|
+
|
|
228
|
+
Agent Board separates a session's semantic task state from whether a worker process is currently alive. An exited worker can therefore leave a durable row that is still resumable or attachable.
|
|
229
|
+
|
|
230
|
+
| Display state | Meaning |
|
|
231
|
+
| --- | --- |
|
|
232
|
+
| **Queued** | A run has been scheduled but has not started processing. |
|
|
233
|
+
| **Running** | The session is actively processing. |
|
|
234
|
+
| **Needs answer** | The session is waiting for user input or an answer to a question. |
|
|
235
|
+
| **Needs instructions** | The run ended without being marked complete and needs the next directive. |
|
|
236
|
+
| **On hold** | The user parked this session intentionally (manual verdict, `h` to toggle). Automated writers can't push it to Done; queued follow-ups do not wake it. |
|
|
237
|
+
| **Done** | The user marked the inactive session complete; this is the default completion path. |
|
|
238
|
+
| **Failed** | The worker or host ended with an error. |
|
|
239
|
+
| **Stopped** | The user stopped the active work. |
|
|
240
|
+
|
|
241
|
+
Rows are grouped by state. When a state contains sessions from multiple directories, rows are grouped by folder within that state. Pinned rows and folders come first, then creation order remains stable; activity does not reshuffle the list. New agent activity is marked unread with stronger row glyphs and header/footer counts. Replies sent while a session is busy enter a durable FIFO follow-up queue and are delivered when the session is ready; a `qN` badge shows queued follow-ups.
|
|
242
|
+
|
|
243
|
+
Press `/` to enter filter mode. Filter tokens are case-insensitive and can be combined with free-text terms:
|
|
244
|
+
|
|
245
|
+
```text
|
|
246
|
+
s:running
|
|
247
|
+
s:hold
|
|
248
|
+
review:ready
|
|
249
|
+
diag:stalled
|
|
250
|
+
evidence:error
|
|
251
|
+
queued:true
|
|
252
|
+
steer:awaiting-approval
|
|
253
|
+
```
|
|
254
|
+
|
|
255
|
+
- `s:<state>` matches a state prefix, including display-label aliases such as `needs-answer`.
|
|
256
|
+
- `review:ready` finds sessions with review-ready evidence.
|
|
257
|
+
- `evidence:error` finds sessions whose evidence contains errors.
|
|
258
|
+
- `queued:true` (also `yes` or `1`) finds sessions with queued follow-ups.
|
|
259
|
+
- `steer:<state>` filters by a persisted steering state.
|
|
260
|
+
- Bare words match name, summary, and working directory; multiple words use AND matching.
|
|
261
|
+
|
|
262
|
+
`diag:stalled` can consume persisted stalled diagnostics, but the current runner does not provide a general provider-stall detector. It should not be read as a complete automatic stall-detection feature.
|
|
263
|
+
|
|
264
|
+
## Evidence and Code References
|
|
265
|
+
|
|
266
|
+
Evidence is collected locally from session events. Agent Board can extract issue and pull-request references from that evidence and show badges such as `#40` or `▸#45` on rows; Peek includes the provider, confidence, source, and URL when available. Built-in GitHub/GitLab-style providers are available, and an optional per-store `providers.json` can extend the provider rules. The `AGENT_BOARD_CODE_REFS=off` setting disables extraction.
|
|
267
|
+
|
|
268
|
+
For internal code platforms (non-github/gitlab hosts) or custom CLIs, add a per-store `providers.json` so claim/action rules exist and sessions stop depending on the low-confidence mention fallback. Example — an internal CLI (`acli`) with claim-strength issue rules:
|
|
269
|
+
|
|
270
|
+
```json
|
|
271
|
+
{
|
|
272
|
+
"providers": [
|
|
273
|
+
{
|
|
274
|
+
"name": "acode",
|
|
275
|
+
"hosts": ["acode.internal.example.com"],
|
|
276
|
+
"rules": [
|
|
277
|
+
{ "pattern": "acli\\s+issue\\s+update\\s+#?(\\d+)(?=[\\s\\S]*--assignee)", "kind": "issue", "strength": "claim" },
|
|
278
|
+
{ "pattern": "acli\\s+issue\\s+(?:note|comment|close)\\s+#?(\\d+)", "kind": "issue", "strength": "action" },
|
|
279
|
+
{ "pattern": "acli\\s+issue\\s+(?:show|view)\\s+#?(\\d+)", "kind": "issue", "strength": "view" }
|
|
280
|
+
]
|
|
281
|
+
}
|
|
282
|
+
]
|
|
283
|
+
}
|
|
284
|
+
```
|
|
285
|
+
|
|
286
|
+
`hosts` matches the repo's remote host; rules follow the same `pattern`/`kind`/`strength` shape as the built-in `gh`/`glab` tables (`strength`: `claim` > `action` > `view`), and the `#N` capture group supplies the number. Validation errors from a broken file surface in the diagnostics panel and never break extraction — an invalid file is simply ignored.
|
|
287
|
+
|
|
288
|
+
## Attach and Fallback Behavior
|
|
289
|
+
|
|
290
|
+
When PTY support is healthy, Agent Board uses an interactive PTY host for attach and start-and-attach. If PTY support is unavailable, eligible managed sessions can still run in the background through the JSON runner; start-and-attach falls back to background launch with a warning. Adopted external foreground sessions require PTY to continue safely. Press `!` in the dashboard for diagnosis and fix steps.
|
|
291
|
+
|
|
292
|
+
On Windows, PTY host control uses a named pipe and spawned child console windows are hidden. Terminal behavior can still vary between terminal emulators.
|
|
293
|
+
|
|
294
|
+
## Entry Points
|
|
295
|
+
|
|
296
|
+
| Entry point | What it does |
|
|
297
|
+
| --- | --- |
|
|
298
|
+
| `/agent-board` | Opens the dashboard from an interactive Pi session. Use this command path to attach to managed sessions. |
|
|
299
|
+
| `pi /agent-board` | Starts Pi by invoking the dashboard command. Quitting the standalone dashboard shuts down Pi instead of dropping into a normal chat session. |
|
|
300
|
+
| `pi --agent-board` | Opens the dashboard through the extension startup flag. This startup path cannot attach to a managed session; use `/agent-board` from a normal Pi session for attach. |
|
|
301
|
+
| `/bg [prompt]` | Adopts the current interactive Pi session into Agent Board. An optional prompt is added to its follow-up queue before the dashboard opens. |
|
|
302
|
+
|
|
303
|
+
The board is global across projects by default. Rows are stored under `~/.pi/agent/agent-board/`; archiving a row removes it from the board but preserves the underlying Pi session file.
|
|
304
|
+
|
|
305
|
+
## Persistence, Safety, and Limitations
|
|
306
|
+
|
|
307
|
+
Agent Board stores its durable roster and per-session artifacts under `~/.pi/agent/agent-board/` by default. Set `AGENT_BOARD_ROOT` to use another location. The store includes the roster, launch preferences, per-session metadata and state, Pi session JSONL, run status/events, evidence, diagnostics, and (for PTY hosts) a replayable screen log.
|
|
308
|
+
|
|
309
|
+
Rows and session history survive Pi reloads, Pi restarts, and worker exits. When the dashboard opens, it reconciles stale runner or host records and keeps resumable sessions visible. Archiving a row removes it from the board but does not delete its underlying Pi session file.
|
|
310
|
+
|
|
311
|
+
> **Worktree isolation is currently disabled.** Agent Board does not automatically create or manage Git worktrees. Multiple sessions in the same repository may run concurrently, so avoid overlapping writes or provide your own isolation before starting parallel coding tasks.
|
|
312
|
+
|
|
313
|
+
Other current limitations:
|
|
314
|
+
|
|
315
|
+
- Agent Board runs locally; it does not provide cloud execution, multi-user coordination, or shared dashboards.
|
|
316
|
+
- Real model output still depends on Pi provider authentication and network access.
|
|
317
|
+
- The `--agent-board` startup path opens the dashboard but cannot attach to a managed session; use `/agent-board` from a normal Pi session for attach.
|
|
318
|
+
- Pending Pi question or questionnaire tools must be answered in the attached interactive session; inline reply is rejected while one is pending.
|
|
319
|
+
- PTY-dependent features require a working `node-pty` installation. Background work can use the JSON-runner fallback when PTY is unavailable, but start & attach then becomes background-only.
|
|
320
|
+
|
|
321
|
+
## Configuration
|
|
322
|
+
|
|
323
|
+
Set these variables before starting Pi. Model-backed features fall back gracefully where noted, so disabling them does not prevent the core dashboard from working.
|
|
324
|
+
|
|
325
|
+
| Variable | Default / values | Purpose |
|
|
326
|
+
| --- | --- | --- |
|
|
327
|
+
| `AGENT_BOARD_ROOT` | `~/.pi/agent/agent-board/` | Override the durable store location. |
|
|
328
|
+
| `AGENT_BOARD_AUTO_STATE` | enabled; `off` disables | Enable automatic terminal-state refinement after a turn. |
|
|
329
|
+
| `AGENT_BOARD_AUTO_STATE_MODEL` | `gpt-4o`; `off` uses heuristics | Model for classifying the terminal state of a finished turn. |
|
|
330
|
+
| `AGENT_BOARD_AUTO_STATE_NO_DONE` | unset = manual Done; `0`, `false`, `off`, or `no` restores auto-Done | Keep completion manual by default, or restore automatic `Done` classification. |
|
|
331
|
+
| `AGENT_BOARD_SUMMARY_MODEL` | `gpt-4o`; `off` disables | Generate short row summaries. Heuristic summaries remain available as a fallback. |
|
|
332
|
+
| `AGENT_BOARD_TITLE_MODEL` | `openai-codex/gpt-5.5`; `off` disables | Generate a short session title after dispatch. The initial slug remains if generation fails. |
|
|
333
|
+
| `AGENT_BOARD_TITLE_THINKING_LEVEL` | `low`; `off` omits the option | Thinking level used by title generation. |
|
|
334
|
+
| `AGENT_BOARD_CODE_REFS` | enabled; `off` disables | Extract issue/PR badges from session evidence. |
|
|
335
|
+
| `AGENT_BOARD_DISABLE_PTY` | unset; `1` disables | Disable PTY host and attach mode. |
|
|
336
|
+
| `AGENT_BOARD_FORCE_PTY` | unset; `1` forces the PTY path | Force the PTY availability path when diagnosing or controlling fallback behavior. |
|
|
337
|
+
| `AGENT_BOARD_ATTACH_MOUSE` | enabled; `0`, `off`, or `false` disables | Disable attach-view mouse handling and use terminal-native selection instead. |
|
|
338
|
+
| `AGENT_BOARD_ENABLE_MOUSE_SCROLL` | enabled; `0` disables | Compatibility switch to disable attach-view mouse scrolling. |
|
|
339
|
+
| `AGENT_BOARD_WHEEL_LINES` | `1`, clamped to `1..50` | Lines scrolled per mouse-wheel notch in the attach view (regular TUI mode; in fullscreen the TUI's own wheel accelerator decides the line count). |
|
|
340
|
+
| `AGENT_BOARD_MAX_WARM_HOSTS` | `4`, clamped to `0..50` | Maximum number of idle PTY hosts retained for faster attach. |
|
|
341
|
+
| `AGENT_BOARD_WARM_HOST_TTL_MS` | `600000` (10 minutes); `0` disables TTL eviction | How long an idle warm host may remain before it is evicted. |
|
|
342
|
+
| `AGENT_BOARD_ATTACH_NATIVE_PASTE` | enabled; `0` disables | Disable X11 PRIMARY selection copy and middle-click paste integration. |
|
|
343
|
+
| `AGENT_BOARD_FORWARD_OSC52` | enabled; `0` disables | Disable OSC 52 clipboard sequence forwarding from an attached session. |
|
|
344
|
+
| `AGENT_BOARD_FORWARD_IMAGES` | enabled; `0` disables | Disable terminal image/file passthrough forwarding from an attached session. |
|
|
345
|
+
| `AGENT_BOARD_IME_FIX` | enabled; `0` disables | Disable the attach-view IME cursor coalescer if your terminal has compatibility problems. |
|
|
346
|
+
| `AGENT_BOARD_TERMINAL_SNAPSHOT` | enabled; `0` forces legacy | Force the pre-phase-4 attach path (screen.log replay + jiggle); escape hatch / rollback switch for the snapshot+subscribe attach protocol. |
|
|
347
|
+
| `AGENT_BOARD_REPLY_GUARD` | enabled; `0`, `off`, or `false` disables | Discard terminal reply fragments (device attributes, kitty flags, cell size, DCS) that pi-tui delivers as input, and forward color replies whole. While a reply head is open, up to 64 bytes / 250ms of following input is absorbed. |
|
|
348
|
+
|
|
349
|
+
`AGENT_BOARD_TERMINAL_SNAPSHOT=0` routes attach onto the legacy fallback family: the screen.log replay tail plus the shrink-and-hold jiggle redraw. These paths exist only for pre-protocol runners and as a rollback hatch — they are not part of the snapshot+subscribe protocol path (issue #91 phase 4). They will be retired once the installed runner fleet is on the snapshot protocol baseline (detectable on the wire via hello protocol fields).
|
|
350
|
+
|
|
351
|
+
Older `AGENT_VIEW_*` names are still read in selected compatibility paths. Prefer `AGENT_BOARD_*` for new setups. Internal child markers are managed by Agent Board and are not user settings.
|
|
352
|
+
|
|
353
|
+
The `providers.json` file under the configured store root can extend the built-in issue/PR reference providers; see the [Evidence and Code References](#evidence-and-code-references) section for the feature overview.
|
|
354
|
+
|
|
355
|
+
## Troubleshooting
|
|
356
|
+
|
|
357
|
+
### Rows stay in `Running`
|
|
358
|
+
|
|
359
|
+
First verify that Pi itself can complete a one-shot model call:
|
|
360
|
+
|
|
361
|
+
```bash
|
|
362
|
+
pi --mode json -p --no-session "Reply with exactly: DONE"
|
|
363
|
+
```
|
|
364
|
+
|
|
365
|
+
The command should emit an assistant reply, then an `agent_end` event, and exit. If it hangs before the assistant reply, fix Pi provider authentication or network access first. Agent Board cannot produce live model results until Pi works independently.
|
|
366
|
+
|
|
367
|
+
### `node-pty unavailable`
|
|
368
|
+
|
|
369
|
+
Press `!` in the dashboard to open the diagnostic panel and follow its fix steps. Common causes include a missing native `node-pty` binary, a Node/architecture mismatch, a missing or non-executable macOS `spawn-helper`, or macOS quarantine. You can temporarily set `AGENT_BOARD_DISABLE_PTY=1` to use background JSON-runner behavior where supported.
|
|
370
|
+
|
|
371
|
+
### Attach is slow or keeps reconnecting
|
|
372
|
+
|
|
373
|
+
A cold PTY host may briefly show a loading or reconnecting surface while it starts. Check the PTY status in the dashboard with `!`; stale hosts are diagnosed separately from active task workers. If the host never becomes healthy, repair `node-pty` or use background mode for eligible managed sessions.
|
|
374
|
+
|
|
375
|
+
### IME candidate window is stuck at the window edge (Windows WezTerm)
|
|
376
|
+
|
|
377
|
+
On Windows WezTerm with a WSL2 backend, the IME candidate window may stay pinned to the right edge instead of following the text cursor in an attached session. Windows WezTerm only tracks the IME candidate position from the visible hardware cursor, and Pi hides the hardware cursor by default — the block cursor you see in the editor is drawn content, not the hardware cursor. Linux terminals are not affected.
|
|
378
|
+
|
|
379
|
+
Make the hardware cursor visible, either way:
|
|
380
|
+
|
|
381
|
+
```bash
|
|
382
|
+
export PI_HARDWARE_CURSOR=1 # machine-local, e.g. ~/.zshrc.local
|
|
383
|
+
```
|
|
384
|
+
|
|
385
|
+
or set `"showHardwareCursor": true` in Pi's `settings.json` (syncs across machines if the config is version-controlled; harmless on Linux).
|
|
386
|
+
|
|
387
|
+
Trade-off: the real terminal cursor becomes visible inside the TUI. This is cosmetic only.
|
|
388
|
+
|
|
389
|
+
### Start & attach falls back to background
|
|
390
|
+
|
|
391
|
+
Start & attach requires PTY support. When PTY is unavailable, the task is still dispatched in the background and the dashboard displays a warning. Repair PTY and retry attach from the normal `/agent-board` command path.
|
|
392
|
+
|
|
393
|
+
### Inline reply is rejected
|
|
394
|
+
|
|
395
|
+
A pending Pi question or questionnaire requires the real interactive session. Attach to the row and answer it there; ordinary replies can be sent from Peek and are queued while a session is busy.
|
|
396
|
+
|
|
397
|
+
### Sessions in the same repository conflict
|
|
398
|
+
|
|
399
|
+
Worktree isolation is not enabled. Stop overlapping writers, separate their working directories, or create and manage Git worktrees yourself before running concurrent coding tasks.
|
|
400
|
+
|
|
401
|
+
See [VERIFY.md](VERIFY.md) for no-auth checks, extension loading checks, provider checks, persistence checks, and the manual dashboard flow.
|
|
402
|
+
|
|
403
|
+
## Development
|
|
404
|
+
|
|
405
|
+
For local development:
|
|
406
|
+
|
|
407
|
+
```bash
|
|
408
|
+
npm install
|
|
409
|
+
npm run verify
|
|
410
|
+
```
|
|
411
|
+
|
|
412
|
+
`npm run verify` runs typecheck, the perf gate (`npm run test:perf`), tests, coverage, and a package dry-run. The A11 perf assertions are opt-in — they skip under `npm test` / `npm run test:coverage` and only measure via `npm run test:perf` (issue #121). The same checks run in CI on Node 22 and Node 24. See [VERIFY.md](VERIFY.md) for the full verification checklist and known environment-dependent limitations.
|
|
413
|
+
|
|
414
|
+
## Publishing
|
|
415
|
+
|
|
416
|
+
Releases run through `scripts/release.mjs` and are published by CI when a GitHub Release is created. The flow checks the parts that are easy to get wrong — the changelog range, tag ancestry against `main`, and drift from a late merge — instead of assuming them. See [docs/RELEASE.md](docs/RELEASE.md) for the full process, the one-time npm trusted-publisher setup, and failure recovery.
|
|
417
|
+
|
|
418
|
+
```bash
|
|
419
|
+
node scripts/release.mjs precheck # gate: clean main, nothing in flight
|
|
420
|
+
node scripts/release.mjs prepare minor # changelog + verify + bump + tag + release branch
|
|
421
|
+
node scripts/release.mjs open-pr 0.9.0 # push the branch and tag, open the release PR
|
|
422
|
+
# merge the PR with a merge commit, then:
|
|
423
|
+
node scripts/release.mjs finish 0.9.0 # GitHub Release → CI publishes to npm
|
|
424
|
+
```
|
|
425
|
+
|
|
426
|
+
After publishing, users install the scoped package with:
|
|
427
|
+
|
|
428
|
+
```bash
|
|
429
|
+
pi install npm:@huseynsnmz/pi-board
|
|
430
|
+
```
|
|
431
|
+
|
|
432
|
+
The Pi package gallery uses the `pi.video` and `pi.image` URLs from `package.json`.
|
|
433
|
+
|
|
434
|
+
## Further Reading
|
|
435
|
+
|
|
436
|
+
- [Manual verification](VERIFY.md) — static checks, Pi loading, provider authentication, persistence, and dashboard flows.
|
|
437
|
+
- [Release process](docs/RELEASE.md) — release commands, trusted publishing setup, and failure recovery.
|
|
438
|
+
- [Product requirements](PRD.md) — original product scope and design context.
|
|
439
|
+
- [Progress log](PROGRESS.md) — implementation checkpoints and known environment notes.
|
|
440
|
+
- [Exploration notes](docs/EXPLORATION.md) — Pi API and integration research.
|
package/VERIFY.md
ADDED
|
@@ -0,0 +1,115 @@
|
|
|
1
|
+
# Manual Verification
|
|
2
|
+
|
|
3
|
+
Steps you can run yourself to check the extension. Grouped from "no auth needed" to
|
|
4
|
+
"needs pi provider auth". Commands assume you're in the repo root.
|
|
5
|
+
|
|
6
|
+
---
|
|
7
|
+
|
|
8
|
+
## 0. Static checks (no auth, fast)
|
|
9
|
+
|
|
10
|
+
```bash
|
|
11
|
+
npm install # dev + runtime deps
|
|
12
|
+
npm run typecheck # expect: 0 errors
|
|
13
|
+
npm run test:perf # expect: `burst:`/`paced:` value lines, pass 3 / skipped 0 — the ONLY path that measures perf assertions; they skip under npm test (issue #121)
|
|
14
|
+
npm test # expect: 0 failures (the 3 A11 perf tests skip here, reason points at `npm run test:perf`)
|
|
15
|
+
npm run pack:dry # expect: pi-agent-board-<version>.tgz contents only include deploy files
|
|
16
|
+
```
|
|
17
|
+
|
|
18
|
+
`npm test` includes a hermetic integration test that runs the **real detached runner** against
|
|
19
|
+
a fake pi worker (`test-support/fake-pi.mjs`) — it proves dispatch → events → status/state →
|
|
20
|
+
finalize (completed / needs_input / failed / stopped) without any model/network.
|
|
21
|
+
|
|
22
|
+
## 1. Does the extension load in pi? (no auth)
|
|
23
|
+
|
|
24
|
+
```bash
|
|
25
|
+
pi --list-models -e "$(pwd)/src/index.ts"
|
|
26
|
+
```
|
|
27
|
+
Expect a normal model table and **exit 0** (the extension factory ran without throwing). If you
|
|
28
|
+
see an error mentioning `index.ts` / jiti / a missing import, that's a load problem.
|
|
29
|
+
|
|
30
|
+
## 2. CRITICAL: can pi reach a model at all? (needs pi auth)
|
|
31
|
+
|
|
32
|
+
This is the thing that was blocked in the dev sandbox. The background worker is just
|
|
33
|
+
`pi --mode json -p --session <file> "<prompt>"`, so first confirm a plain one-shot works:
|
|
34
|
+
|
|
35
|
+
```bash
|
|
36
|
+
# Should print a JSON event stream that ENDS WITH a line of type "agent_end", then exit
|
|
37
|
+
# within a few seconds. Watch for an "assistant" message_end before agent_end.
|
|
38
|
+
pi --mode json -p --no-session "Reply with exactly: DONE" | tail -n 20
|
|
39
|
+
```
|
|
40
|
+
- ✅ **Healthy:** you see `...message_end (assistant)...`, then `agent_end`, and the command exits.
|
|
41
|
+
- ❌ **Hang:** it prints up to a `message_end` for the **user** message then sits idle (no
|
|
42
|
+
assistant reply, never exits). That means pi has no working provider auth / network here.
|
|
43
|
+
Fix pi's auth first:
|
|
44
|
+
```bash
|
|
45
|
+
pi # then run /login inside pi, or set the provider key pi expects, e.g.
|
|
46
|
+
# export ANTHROPIC_API_KEY=... (or OPENAI_API_KEY=... for gpt-4o summaries)
|
|
47
|
+
```
|
|
48
|
+
Re-run the one-shot above until it ends in `agent_end`. The dashboard cannot show live results
|
|
49
|
+
until this works — it's a pi setup step, independent of this extension.
|
|
50
|
+
|
|
51
|
+
## 3. Install the extension for normal use
|
|
52
|
+
|
|
53
|
+
For a local checkout, install it as a Pi package:
|
|
54
|
+
```bash
|
|
55
|
+
pi install "$(pwd)"
|
|
56
|
+
```
|
|
57
|
+
Or symlink the repo into pi's global extensions dir (auto-discovered via the top-level `index.ts`):
|
|
58
|
+
```bash
|
|
59
|
+
ln -s "$(pwd)" ~/.pi/agent/extensions/agent-board
|
|
60
|
+
```
|
|
61
|
+
After publish, install with:
|
|
62
|
+
```bash
|
|
63
|
+
pi install npm:@zhuxixi/pi-agent-board
|
|
64
|
+
```
|
|
65
|
+
Then start pi normally:
|
|
66
|
+
```bash
|
|
67
|
+
pi
|
|
68
|
+
```
|
|
69
|
+
|
|
70
|
+
## 4. Drive the dashboard
|
|
71
|
+
|
|
72
|
+
Inside pi:
|
|
73
|
+
1. Type `/agent-board`, or start with `pi /agent-board` → the full-screen dashboard opens.
|
|
74
|
+
- With `pi /agent-board`, quitting the dashboard exits Pi instead of dropping you into a normal chat session.
|
|
75
|
+
- The startup path should feel cleaner than `/agent-board`: no normal Pi header/footer chrome and no dispatch notifications above the dashboard.
|
|
76
|
+
2. Press **i** to enter INSERT mode, then type a task in the bottom input (e.g. `list the files in this repo and summarize the README`) and press **Enter**.
|
|
77
|
+
- A **Start session** dialog opens with **Start session** focused by default.
|
|
78
|
+
- Press **Enter** again to launch immediately, or move with **↑/↓** to change **cwd**, **model**, or **thinking** first.
|
|
79
|
+
- With automatic Done disabled by default, a successful run settles in **Needs instructions** until you review it and press **d** to confirm **Done**. Set `AGENT_BOARD_AUTO_STATE_NO_DONE=0` to restore automatic Done classification for this verification path.
|
|
80
|
+
3. **space** = peek when the input is empty (summary, blocker, latest output); in peek **r** = reply, **a** = attach.
|
|
81
|
+
**→** / **>** = open a full-screen live session view without interrupting; **←** / **<** returns.
|
|
82
|
+
4. **enter** on an empty input = attach to the selected full session (confirms first if it's still running).
|
|
83
|
+
You're now in the real Pi session; run `/agent-board` again to return.
|
|
84
|
+
5. Other keys: **/** filter (`s:running`, or free text), **Ctrl+R** rename, **Ctrl+T** pin, **Ctrl+S** stop,
|
|
85
|
+
**x** then **y** delete (confirm prompt; archives the row, keeps the session file), **Ctrl+X** ×2 quick delete (no confirm),
|
|
86
|
+
**?** help, **Esc** clears input / quits when empty.
|
|
87
|
+
|
|
88
|
+
## 5. Inspect the durable store on disk
|
|
89
|
+
|
|
90
|
+
```bash
|
|
91
|
+
ls -R ~/.pi/agent/agent-board
|
|
92
|
+
cat ~/.pi/agent/agent-board/roster.json
|
|
93
|
+
cat ~/.pi/agent/agent-board/views/*/state.json
|
|
94
|
+
cat ~/.pi/agent/agent-board/views/*/runs/*/status.json
|
|
95
|
+
# raw worker event stream for a run:
|
|
96
|
+
cat ~/.pi/agent/agent-board/views/*/runs/*/events.jsonl
|
|
97
|
+
```
|
|
98
|
+
|
|
99
|
+
## 6. Recovery / persistence
|
|
100
|
+
|
|
101
|
+
- Start a dispatch, then quit pi (or `/reload`). Re-open pi and `/agent-board` — the row is still
|
|
102
|
+
there with its last state (rehydrated from disk). If a run's runner died without finishing,
|
|
103
|
+
the dashboard reconciles it to `failed (runner exited)` on open.
|
|
104
|
+
|
|
105
|
+
## 7. Same-repo session launches
|
|
106
|
+
|
|
107
|
+
- Dispatch one task in a git repo, then (while it's running) dispatch a second in the
|
|
108
|
+
**same repo**. Both launches should be allowed. The extension never creates a git worktree on
|
|
109
|
+
its own.
|
|
110
|
+
|
|
111
|
+
## 8. Summary model
|
|
112
|
+
|
|
113
|
+
Default summary model is **gpt-4o** (override `AGENT_BOARD_SUMMARY_MODEL=<model>`, disable with
|
|
114
|
+
`AGENT_BOARD_SUMMARY_MODEL=off`; legacy `AGENT_VIEW_SUMMARY_MODEL` is also honored). It needs OpenAI auth; without it the row keeps its heuristic
|
|
115
|
+
summary (e.g. the first sentence of the agent's last message or the active tool).
|