docs: remove manual paragraph line wraps (#6131)
* docs: remove manual paragraph line wraps * docs: preserve GitHub alert marker line breaks
This commit is contained in:
1 parent
36c36a1324
commit
50256940be
58 files changed
+848
-3130
No files matched your search
+15
-75
@@ -11,100 +11,40 @@ bun run --cwd tui build
|
||||
|
||||
## Source layout
|
||||
|
||||
Code under `src/` is grouped by responsibility: `app/` coordinates the retained UI, `client/`
|
||||
owns gateway transport and API projections, `composer/` owns draft and queue state, `menus/` and
|
||||
`views/` own interactive surfaces, `rendering/` owns transcript presentation, and `platform/`
|
||||
contains host-specific integration. Unit and component tests stay beside the feature they cover;
|
||||
cross-module behavior tests live with the owning `app/` or `client/` boundary. The production
|
||||
build still starts from `src/index.ts`, so colocated `*.test.ts` files are not part of the compiled
|
||||
executable.
|
||||
Code under `src/` is grouped by responsibility: `app/` coordinates the retained UI, `client/` owns gateway transport and API projections, `composer/` owns draft and queue state, `menus/` and `views/` own interactive surfaces, `rendering/` owns transcript presentation, and `platform/` contains host-specific integration. Unit and component tests stay beside the feature they cover; cross-module behavior tests live with the owning `app/` or `client/` boundary. The production build still starts from `src/index.ts`, so colocated `*.test.ts` files are not part of the compiled executable.
|
||||
|
||||
`nanobot` (or the explicit `nanobot agent` form) launches this client, leases the shared local gateway or starts it on demand, and passes the local bootstrap endpoint through environment variables. The client paints before gateway readiness, retries bootstrap in the background, and obtains fresh WebSocket and REST credentials for each connection. Other terminals and the WebUI keep that gateway alive; the final interactive launcher to exit releases the on-demand process. `/detach` closes the TUI after promoting the gateway to persistent background mode, keeping any active agent turn running without clients; the restored terminal prints the exact stop command for that config and explicit workspace. `nanobot gateway --background` can start or promote it persistently before opening a client. Source checkouts automatically align dependencies with `bun.lock` before launch; released installs use a version-matched, checksum-verified archive that keeps the executable together with its licenses, notices, corresponding application source, source offer, and relinking instructions. Startup fails explicitly if the native client is unavailable. The legacy Python prompt is selected with `nanobot --classic` or `nanobot agent --classic`.
|
||||
|
||||
The TUI uses OpenTUI's retained full-screen layout: the transcript reflows with the terminal while the composer stays fixed at the bottom. Mouse and keyboard scrolling operate inside the transcript, and leaving the TUI restores the previous terminal screen.
|
||||
|
||||
Assistant math written with `$...$`, `$$...$$`, `\\(...\\)`, or `\\[...\\]` is presented as
|
||||
Unicode plain text so formulas remain readable in terminals without a math renderer. Currency and
|
||||
LaTeX inside inline or fenced code remain literal.
|
||||
Assistant math written with `$...$`, `$$...$$`, `\\(...\\)`, or `\\[...\\]` is presented as Unicode plain text so formulas remain readable in terminals without a math renderer. Currency and LaTeX inside inline or fenced code remain literal.
|
||||
|
||||
Automatic theme selection follows the terminal's OSC 10/11 responses. Until a response
|
||||
arrives, the TUI uses the terminal's default foreground and background without semantic
|
||||
colors or color animations. Terminals that do not answer keep this readable fallback.
|
||||
Use `nanobot --theme light` or `nanobot --theme dark` to select a color palette explicitly.
|
||||
Automatic theme selection follows the terminal's OSC 10/11 responses. Until a response arrives, the TUI uses the terminal's default foreground and background without semantic colors or color animations. Terminals that do not answer keep this readable fallback. Use `nanobot --theme light` or `nanobot --theme dark` to select a color palette explicitly.
|
||||
|
||||
## Herdr pane titles
|
||||
|
||||
When Herdr supplies `HERDR_ENV=1` and `HERDR_PANE_ID`, nanobot keeps the same full-screen layout, controls, and navigation available in any other terminal. Its only host-specific behavior is reporting the latest user task as the Herdr pane title through the supported pane CLI. Creating a new chat, switching to a chat without a task, and exiting the TUI clear that title. Nanobot does not report agent lifecycle, session, model, Git branch, workspace, or action metadata to Herdr.
|
||||
|
||||
The model preset and workspace access labels above the composer are live controls. Click either
|
||||
label, then click a choice; arrow keys, `Enter`, and `Esc` provide the same flow without a mouse.
|
||||
Changes reuse the gateway's normal model command and workspace policy checks.
|
||||
The model preset and workspace access labels above the composer are live controls. Click either label, then click a choice; arrow keys, `Enter`, and `Esc` provide the same flow without a mouse. Changes reuse the gateway's normal model command and workspace policy checks.
|
||||
|
||||
When you scroll away from the latest output, the scrollbar and `Ctrl+End` hint appear only until
|
||||
you return to the bottom. Large pastes are represented by a short editable placeholder in the
|
||||
composer; nanobot sends the original text unchanged. Press `Ctrl+V` or `Alt+V` while the composer
|
||||
is focused to attach an image from the system clipboard. Image bytes stay behind removable
|
||||
`[Image #n]` placeholders until the message is sent; each placeholder behaves as one unit, and
|
||||
deleting it removes its image.
|
||||
When you scroll away from the latest output, the scrollbar and `Ctrl+End` hint appear only until you return to the bottom. Large pastes are represented by a short editable placeholder in the composer; nanobot sends the original text unchanged. Press `Ctrl+V` or `Alt+V` while the composer is focused to attach an image from the system clipboard. Image bytes stay behind removable `[Image #n]` placeholders until the message is sent; each placeholder behaves as one unit, and deleting it removes its image.
|
||||
|
||||
While nanobot is working, the composer prompt becomes
|
||||
`Enter send now Tab send next`; narrow terminals shorten it to `Enter now Tab next`.
|
||||
The footer shows progress and elapsed time without repeating the latest tool activity already
|
||||
visible in the transcript.
|
||||
While nanobot is working, the composer prompt becomes `Enter send now Tab send next`; narrow terminals shorten it to `Enter now Tab next`. The footer shows progress and elapsed time without repeating the latest tool activity already visible in the transcript.
|
||||
|
||||
Type `/` to discover slash commands published by the connected gateway. Use the arrow keys
|
||||
to move, `Tab` to complete, and `Esc` to close the menu.
|
||||
Type `/` to discover slash commands published by the connected gateway. Use the arrow keys to move, `Tab` to complete, and `Esc` to close the menu.
|
||||
|
||||
Type `@` to complete installed CLI apps, configured MCP servers, or saved sessions through the
|
||||
same gateway metadata used by the WebUI. While nanobot is working, `Enter` sends immediately,
|
||||
`Tab` waits until the current response is finished, and `Option+Up` on macOS (`Alt+Up` on
|
||||
Windows/Linux) returns the latest waiting message to the composer for editing. Waiting messages
|
||||
stay visible above the composer. `/goal <task>` follows the same keys: `Enter` sends the goal
|
||||
into the running conversation, while `Tab` waits for the current response to finish.
|
||||
Use `Shift+Enter` for a newline; `Ctrl+J` is the universal fallback when a terminal cannot
|
||||
distinguish modified Enter keys. `Alt+Enter` and `Ctrl+Enter` are also accepted when distinguishable.
|
||||
Unsent prompts return to the composer if the turn stops or fails.
|
||||
Type `@` to complete installed CLI apps, configured MCP servers, or saved sessions through the same gateway metadata used by the WebUI. While nanobot is working, `Enter` sends immediately, `Tab` waits until the current response is finished, and `Option+Up` on macOS (`Alt+Up` on Windows/Linux) returns the latest waiting message to the composer for editing. Waiting messages stay visible above the composer. `/goal <task>` follows the same keys: `Enter` sends the goal into the running conversation, while `Tab` waits for the current response to finish. Use `Shift+Enter` for a newline; `Ctrl+J` is the universal fallback when a terminal cannot distinguish modified Enter keys. `Alt+Enter` and `Ctrl+Enter` are also accepted when distinguishable. Unsent prompts return to the composer if the turn stops or fails.
|
||||
|
||||
Use `/sessions` to search and switch persisted conversations without leaving the terminal.
|
||||
`/new-chat` preserves the current conversation and starts another one; nanobot's existing `/new`
|
||||
command keeps its cross-channel behavior and resets the current chat. Each launch starts a new
|
||||
session using the launch directory as its workspace; `--session` selects an existing session and
|
||||
`--workspace` overrides the launch directory. On exit, the restored terminal prints a ready-to-run
|
||||
`nanobot agent --session ...` command that resumes the current session. When earlier transcript
|
||||
pages exist, press `PageUp` at the top to load them in place.
|
||||
Use `/sessions` to search and switch persisted conversations without leaving the terminal. `/new-chat` preserves the current conversation and starts another one; nanobot's existing `/new` command keeps its cross-channel behavior and resets the current chat. Each launch starts a new session using the launch directory as its workspace; `--session` selects an existing session and `--workspace` overrides the launch directory. On exit, the restored terminal prints a ready-to-run `nanobot agent --session ...` command that resumes the current session. When earlier transcript pages exist, press `PageUp` at the top to load them in place.
|
||||
|
||||
The native client accepts bare WebSocket chat IDs or `websocket:<id>` selectors. Use
|
||||
`nanobot agent --classic --session <channel:id>` to resume a session owned by another channel;
|
||||
the TUI never silently maps one channel's identity into the WebSocket namespace.
|
||||
The native client accepts bare WebSocket chat IDs or `websocket:<id>` selectors. Use `nanobot agent --classic --session <channel:id>` to resume a session owned by another channel; the TUI never silently maps one channel's identity into the WebSocket namespace.
|
||||
|
||||
Sessions are live across clients: if two terminals or the WebUI attach to the same session, an
|
||||
accepted user message and the resulting agent/tool stream appear on every attached client while
|
||||
the gateway executes the input only once.
|
||||
Sessions are live across clients: if two terminals or the WebUI attach to the same session, an accepted user message and the resulting agent/tool stream appear on every attached client while the gateway executes the input only once.
|
||||
|
||||
`/branch` creates a new saved conversation from a completed reply without changing the source
|
||||
session. The picker uses durable history indices, so paginated transcripts branch at the selected
|
||||
turn rather than the currently visible row.
|
||||
`/branch` creates a new saved conversation from a completed reply without changing the source session. The picker uses durable history indices, so paginated transcripts branch at the selected turn rather than the currently visible row.
|
||||
|
||||
`/context` explains the session-owned material available for the next agent turn: the compacted
|
||||
summary, replayable raw suffix, and an estimated token count. It deliberately does not expose
|
||||
private reasoning and does not pretend to be the complete model prompt; workspace instructions,
|
||||
memory, and skills are assembled separately by the Python runtime.
|
||||
`/context` explains the session-owned material available for the next agent turn: the compacted summary, replayable raw suffix, and an estimated token count. It deliberately does not expose private reasoning and does not pretend to be the complete model prompt; workspace instructions, memory, and skills are assembled separately by the Python runtime.
|
||||
|
||||
`/usage` shows the latest measured context occupancy and up to eight recent logical model
|
||||
rounds from the latest history page, matching the WebUI usage chart. Bar heights represent input
|
||||
tokens; orange indicates uncached input, teal indicates cached input, and gray means cache usage
|
||||
is unknown. Use `Left`/`Right` to inspect a round's input, output, cache hit rate, generation time,
|
||||
and estimated-usage indicator; `Esc` closes the panel. Details collapse in short terminals.
|
||||
The panel refreshes when a turn ends while open. Missing usage is not treated as zero, and a
|
||||
successful compaction hides the old context meter until a later request reports context usage.
|
||||
Bar heights and cache boundaries are rounded independently to eighths of a character row;
|
||||
positive input always occupies at least one eighth. Mixed full cells use both foreground and
|
||||
background colors. If a partial top cell contains empty space and both token categories, it
|
||||
keeps its height and uses the larger category's color because a terminal cell has only two colors.
|
||||
Use the numeric details for exact token counts; the chart remains a grid approximation.
|
||||
`/usage` shows the latest measured context occupancy and up to eight recent logical model rounds from the latest history page, matching the WebUI usage chart. Bar heights represent input tokens; orange indicates uncached input, teal indicates cached input, and gray means cache usage is unknown. Use `Left`/`Right` to inspect a round's input, output, cache hit rate, generation time, and estimated-usage indicator; `Esc` closes the panel. Details collapse in short terminals. The panel refreshes when a turn ends while open. Missing usage is not treated as zero, and a successful compaction hides the old context meter until a later request reports context usage. Bar heights and cache boundaries are rounded independently to eighths of a character row; positive input always occupies at least one eighth. Mixed full cells use both foreground and background colors. If a partial top cell contains empty space and both token categories, it keeps its height and uses the larger category's color because a terminal cell has only two colors. Use the numeric details for exact token counts; the chart remains a grid approximation.
|
||||
|
||||
`/diff` opens the latest turn's file changes in a full-screen unified diff. Use `Left`/`Right`
|
||||
to switch edits, `PageUp`/`PageDown` or `Home`/`End` to navigate, and `Esc` to return to chat.
|
||||
The gateway remains the source of the patch; the TUI never rereads workspace files to rebuild it.
|
||||
The footer reports provider token/cache usage when available, and tool activity uses compact,
|
||||
tool-specific summaries while retaining the full event history behind `Ctrl+O`.
|
||||
`/diff` opens the latest turn's file changes in a full-screen unified diff. Use `Left`/`Right` to switch edits, `PageUp`/`PageDown` or `Home`/`End` to navigate, and `Esc` to return to chat. The gateway remains the source of the patch; the TUI never rereads workspace files to rebuild it. The footer reports provider token/cache usage when available, and tool activity uses compact, tool-specific summaries while retaining the full event history behind `Ctrl+O`.
|
||||
+7
-19
@@ -1,25 +1,15 @@
|
||||
# Native TUI corresponding source and relinking
|
||||
|
||||
The nanobot TUI release archive contains the executable, its complete JavaScript/TypeScript
|
||||
application source, dependency lockfile, build scripts, and third-party notices. It is built with
|
||||
Bun 1.3.13 and OpenTUI 0.5.11. See `SOURCE_OFFER.md` for the corresponding-source
|
||||
offer that accompanies the executable. The archive also contains the complete LGPL 2.0 and
|
||||
LGPL 2.1 license texts.
|
||||
The nanobot TUI release archive contains the executable, its complete JavaScript/TypeScript application source, dependency lockfile, build scripts, and third-party notices. It is built with Bun 1.3.13 and OpenTUI 0.5.11. See `SOURCE_OFFER.md` for the corresponding-source offer that accompanies the executable. The archive also contains the complete LGPL 2.0 and LGPL 2.1 license texts.
|
||||
|
||||
Corresponding upstream source:
|
||||
|
||||
- nanobot TUI: the `tui/` and `packages/client-events/` directories in the GitHub release tag that contains this archive
|
||||
- Bun 1.3.13 (`bf2e2cecf27e800962b1e7f03d66278f9d5d2e79`):
|
||||
<https://github.com/oven-sh/bun/tree/bun-v1.3.13>
|
||||
- Bun's patched WebKit (`4d5e75ebd84a14edbc7ae264245dcd77fe597c10`):
|
||||
<https://github.com/oven-sh/WebKit/tree/4d5e75ebd84a14edbc7ae264245dcd77fe597c10>
|
||||
- OpenTUI 0.5.11: <https://www.npmjs.com/package/@opentui/core/v/0.5.11>
|
||||
(source: <https://github.com/anomalyco/opentui/tree/6b9863ea7c5fae22bfebb23c242ddcc4c2b0aa0e>)
|
||||
- Bun 1.3.13 (`bf2e2cecf27e800962b1e7f03d66278f9d5d2e79`): <https://github.com/oven-sh/bun/tree/bun-v1.3.13>
|
||||
- Bun's patched WebKit (`4d5e75ebd84a14edbc7ae264245dcd77fe597c10`): <https://github.com/oven-sh/WebKit/tree/4d5e75ebd84a14edbc7ae264245dcd77fe597c10>
|
||||
- OpenTUI 0.5.11: <https://www.npmjs.com/package/@opentui/core/v/0.5.11> (source: <https://github.com/anomalyco/opentui/tree/6b9863ea7c5fae22bfebb23c242ddcc4c2b0aa0e>)
|
||||
|
||||
To rebuild against a modified JavaScriptCore/WebKit, first build Bun 1.3.13 from its complete
|
||||
source checkout together with the WebKit revision above by following Bun's pinned license and
|
||||
build instructions. Then unpack
|
||||
`nanobot-tui-source.tar.gz` from the release archive and run the resulting Bun executable:
|
||||
To rebuild against a modified JavaScriptCore/WebKit, first build Bun 1.3.13 from its complete source checkout together with the WebKit revision above by following Bun's pinned license and build instructions. Then unpack `nanobot-tui-source.tar.gz` from the release archive and run the resulting Bun executable:
|
||||
|
||||
```bash
|
||||
cd nanobot-tui-source/tui
|
||||
@@ -27,8 +17,6 @@ cd nanobot-tui-source/tui
|
||||
/path/to/modified/bun run build -- <target>
|
||||
```
|
||||
|
||||
Supported targets are `darwin-arm64`, `darwin-x64`, `linux-arm64`, `linux-x64`, and `win32-x64`.
|
||||
The resulting executable is written to `dist/`.
|
||||
Supported targets are `darwin-arm64`, `darwin-x64`, `linux-arm64`, `linux-x64`, and `win32-x64`. The resulting executable is written to `dist/`.
|
||||
|
||||
Questions about source availability can be reported at
|
||||
<https://github.com/HKUDS/nanobot/issues>.
|
||||
Questions about source availability can be reported at <https://github.com/HKUDS/nanobot/issues>.
|
||||
+3
-9
@@ -2,14 +2,8 @@
|
||||
|
||||
This offer applies to the native nanobot TUI executable distributed in the same release archive.
|
||||
|
||||
For at least three years after the release date, HKUDS offers any third party a
|
||||
complete machine-readable copy of the corresponding source and relinking materials required for
|
||||
the LGPL-covered libraries incorporated through Bun, for no more than the reasonable physical
|
||||
cost of conveying that copy.
|
||||
For at least three years after the release date, HKUDS offers any third party a complete machine-readable copy of the corresponding source and relinking materials required for the LGPL-covered libraries incorporated through Bun, for no more than the reasonable physical cost of conveying that copy.
|
||||
|
||||
The nanobot application source, lockfile, build scripts, notices, and relinking instructions are
|
||||
already included in this archive. Exact upstream revisions are listed in `RELINKING.md`.
|
||||
The nanobot application source, lockfile, build scripts, notices, and relinking instructions are already included in this archive. Exact upstream revisions are listed in `RELINKING.md`.
|
||||
|
||||
To request any additional corresponding-source material, open an issue at
|
||||
<https://github.com/HKUDS/nanobot/issues> or email <xubinrencs@gmail.com> and identify the nanobot
|
||||
release tag and target platform shown in `THIRD_PARTY_NOTICES.txt`.
|
||||
To request any additional corresponding-source material, open an issue at <https://github.com/HKUDS/nanobot/issues> or email <xubinrencs@gmail.com> and identify the nanobot release tag and target platform shown in `THIRD_PARTY_NOTICES.txt`.
|
||||
Reference in new issue
Block a user