Review a coding agent's output inside thurbox and send it numbered feedback — the herdr-annotate idea, wired into thurbox's own panes. It comes in two tiers, like herdr:
- Full — press a key on any session and its terminal output opens in
plannotator-tui: drag to
select a line, comment on it, and press
E. The comments are delivered straight back into that agent's composer as a numbered list — as if you had typed the review yourself. - Lite — no external program. Drag to select a line in the agent, press
F2, type a comment; repeat to build a list, then send it all back withE. A single small pane, entirely in Lua.
Either tier delivers the same thing: a numbered review typed into the agent's composer. Full renders the source as a document to annotate; Lite is a lighter in-terminal notepad against the live selection.
F5 opens the review, c comments on the flawed line, E sends it — and the
numbered feedback lands in the agent's composer, which echoes it straight back.
| Pane | Slot | What it draws |
|---|---|---|
plugins/40_annotate.lua |
center (switch) |
Full tier. A program pane hosting plannotator-tui on the selected session's captured output. Brought forward by its Review pill or F5; delivers feedback with session send. |
plugins/41_notes.lua |
center (switch) |
Lite tier. A notes pane: the selection (from thurbox.selection, or — over a tracking agent — the system clipboard, which needs the run capability), a comment on it, an accumulating list you classify (c), delete (x) and archive (a/Tab/u). Comment with F2 (a global chord, so it fires from the focused agent); send the list with E. No external program. |
Both share the center slot with the agent pane and draw nothing until you bring
one forward, so they add no column and need no layout.lua edit. Install
only the tier you want — the two are independent.
A thurbox pane cannot spawn a process with a custom environment, so the herdr contract is assembled by two small shipped scripts instead:
bin/pt-launch.sh— the pane runs this as its program. It captures the session's output (thurbox-cli session capture) into a markdown file, sets theHERDR_*/PLANNOTATOR_TUI_*environment plannotator-tui reads, andexecs it on that file.bin/pt-deliver.sh— plannotator-tui delivers a review by running$HERDR_BIN_PATH agent prompt <pane> <feedback>. This shim is that binary; it translates the call intothurbox-cli session send <pane> <feedback>, which types the feedback into the target session as one bracketed paste.
scripts/install-plannotator.sh # downloads + checksums the release binary → ~/.local/binIt is a standalone MIT program; nothing is built here. ~/.local/bin must be on
the PATH thurbox is started with, so the launcher can find it.
thurbox-cli plugin install git+https://github.com/spscream/thurbox-annotate --as plugins/40_annotate.luaThis clones the repository into ~/.config/thurbox/ui/thurbox-annotate/ — the
pane, the launcher and the shim together — and writes one plugins.toml entry.
No layout.lua edit is needed. thurbox-cli plugin check should then list
annotate beside the panes thurbox ships.
40_annotate.lua declares program, because plannotator-tui is a program it
runs. Grant it per file in settings → Interface (Ctrl+, → ] → select
annotate → t); until then the pane draws an honest "trust me" state instead
of a terminal.
- Select a session in the list.
- Press
F5(or its Review pill) — plannotator-tui opens on that agent's captured output. - Drag to select a line, comment, repeat.
- Press
E— the numbered feedback lands in that agent's composer. F5again closes the review and hands focus back.
plugins/41_notes.lua is the whole tier — no binary. Install it the same way:
thurbox-cli plugin install git+https://github.com/spscream/thurbox-annotate --as plugins/41_notes.luaThen:
- Drag to select a line of the agent's output.
- Press
F2— the pane comes forward with that line quoted and a comment field. Type the comment, pressEnterto save it. The chord is global, so it fires while the agent is focused; the selection is grabbed at the keypress. Long comments wrap and follow the caret vertically. UseShift+Enter(orAlt+Enter) for a line break, arrows to move, andEscapeto cancel editing.F2while editing returns to the previous pane and keeps the draft;F2from that pane resumes it.Enterstill saves the complete comment. - Repeat to build the list, then manage it — a cursor moves with
j/k;ccycles the selected note's classification (Issue / Suggestion / Note / Praise);xdeletes it;aarchives it andTabshows the archive, whereurestores.dclears the current list. This mirrors herdr-annotate'sCtrl+B Mmanager, minus the clipboard export the Lua sandbox cannot reach. From either notes list,EscapeorF2returns to the previous pane (normally the agent).Alt+Nopens/toggles the list without capturing a new selection; use it to manage saved notes. - Press
E— the active notes are typed into the selected session's composer as numbered, classified feedback ([Issue] > quote), the same delivery the Full tier uses. A single-line quote stays inline after>; a multi-line selection travels verbatim in a fenced block, so its line breaks and indentation reach the agent as selected. The archive stays behind; only the review is sent.
Lite gets the quote through two channels, the way herdr-annotate does — because the same obstacle applies here: a pane cannot read another terminal program's selection state.
- What thurbox selected arrives instantly through the published
thurbox.selectionfield (thurbox ≥ v2.25.0, #1151). This is a drag over a pane that does not track the mouse — a plain shell, static output. No capability, no wait. - What the agent selected arrives through the system clipboard. A mouse
drag over a tracking agent (Claude Code and the like) is forwarded to that
program, so thurbox never sees the selection — but the agent's own
copy-on-select has already put the text on the clipboard, and Lite reads it
from there, exactly as herdr-annotate does. This needs the
runcapability: grant it per file in settings → Interface (Ctrl+,→]→ select notes →t). Until thenF2over an agent says so. The read is asynchronous, so the compose row showsreading clipboard…for a moment. The clipboard tool is chosen by platform (PowerShell under WSL/Windows,wl-paste/xclip/xselon Linux,pbpasteon macOS); a remote session's clipboard lives on the remote, the same limit herdr notes.
- Lua and shell —
seleneagainstthurbox.yml(the plugin VM's real standard library, so a pane reaching for something the sandbox withholds is a lint failure);stylua --check;shellcheckon the two scripts. - Interface loads —
ci/assemble-interface.shbuilds the directory a real install produces (thurbox'sui/as the base, this repository cloned beside it) and runsthurbox-cli plugin check. A pane that loads but that nothing places exits non-zero.
Both run against the release named by THURBOX_TAG in the workflow. Locally:
git clone --depth 1 --branch v2.25.0 https://github.com/Thurbeen/thurbox .thurbox
cp .thurbox/thurbox.yml . # what selene.toml's `std = "thurbox"` resolves to
selene plugins && stylua --check plugins && shellcheck bin/*.sh scripts/*.sh
ci/assemble-interface.sh .thurbox build/ui
THURBOX_UI_DIR=$PWD/build/ui thurbox-cli plugin checkMIT. plannotator-tui is a separate MIT project; this repository ships none of its code, only downloads its released binary.
The test uses thurbox's LuaHost, real text-input library, node conversion and ratatui TestBackend, with synthetic text only. It asserts that the native caret is inside the editor and checks multiline/soft-wrap tails, Cyrillic, resize, navigation, save/cancel and the native focus-toggle commands emitted by the list. It does not drive a live terminal or prove a particular installed layout's focus history. In a disposable thurbox checkout at the CI tag:
ci/assemble-interface.sh "$THURBOX_CHECKOUT" build/ui
cp tests/native_notes.rs "$THURBOX_CHECKOUT/tests/annotate_notes.rs"
ANNOTATE_UI="$PWD/build/ui" cargo test --manifest-path "$THURBOX_CHECKOUT/Cargo.toml" \
--test annotate_notes -- --nocaptureAfter merge, update the installed thurbox-annotate entries using the normal
thurbox-cli plugin update command, run thurbox-cli plugin check, then use
F10 if the watcher has not reloaded. Opening a PR alone does not update the
running interface. To roll back, install the same plugin source pinned to the
previous commit with the normal plugin installer; keep the existing grants and
layout. Never edit the installed Git working copy or plugins.lock by hand.
