tabby-ai-tools 0.7.1 → 0.8.2

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.
Binary file
@@ -1,6 +1,6 @@
1
- <svg xmlns="http://www.w3.org/2000/svg" width="1800" height="1440" viewBox="0 0 1800 1440" role="img" aria-labelledby="title desc">
2
- <title id="title">Tabby AI Tools v0.7.1 interface illustration — conditional interactive workflows, helper models, local login and API connections</title>
3
- <desc id="desc">Interface illustration, not a running screenshot. Windows default discovery compares actual Codex versions across PATH, desktop and standalone installations. Conditional recordings preserve interaction intent; local rules run first, with an optional current-connection helper model and rebind-before-resume checkpoints. Settings use two-row connection cards and editor summaries, compact headings and full-page scrolling for connections, workflows/preferences and scheduled tasks, with no fixed-height editor. The assistant sidebar coordinates example staging database and application terminals. Connection and model controls share one compact row. Scheduled tasks, provider connections, startup opening enabled by default and twelve interface languages and the Claude Code local-login connection are shown below. Active goals continue automatically by default. Thinking and tool calls appear as collapsed conversation entries that can be expanded. Terminal reads return early after reliable shell completion. Terminal output is read on demand without automatic forwarding; a completed explicit recording and a saved workflow alias are shown. Archive status distinguishes successful checkpoints from successful persistence. Pi runtime settings show the built-in runtime and an optional Node override, host-only tools and opt-in automatic context compaction. The provider list includes Kimi and Alibaba Cloud Coding Plan connections. Custom OpenAI-compatible settings show an example Base URL, model, protocol and authentication. Version 0.7.1 example with optional Pi SDK runtime, built-in Node 22.19+, manual context compaction and structured retry waiting.</desc>
1
+ <svg xmlns="http://www.w3.org/2000/svg" width="1800" height="1900" viewBox="0 0 1800 1900" role="img" aria-labelledby="title desc">
2
+ <title id="title">Tabby AI Tools v0.8.2 interface illustration — conditional interactive workflows, helper models, local login and API connections</title>
3
+ <desc id="desc">Shared Codex/Claude CLI discovery prevents startup cancellation races; clipboard attachments with inline previews and native tab progress; custom instructions/private CLI session spaces and Pi configuration: native provider search, offline SDK 1.4.0 catalog, four custom protocols and Save/Discard/Copy drafts. Interface illustration, not a running screenshot. Windows default Codex discovery compares actual CLI versions across PATH and desktop/standalone installations; a stable directory limits selection to its own children. Conditional recordings preserve interaction intent; local rules run first, with an optional current-connection helper model and rebind-before-resume checkpoints. Settings use two-row connection cards and editor summaries, compact headings and full-page scrolling for connections, workflows/preferences and scheduled tasks, with no fixed-height editor. The assistant sidebar coordinates example staging database and application terminals. Connection and model controls share one compact row. Scheduled tasks, provider connections, startup opening enabled by default and twelve interface languages and the Claude Code local-login connection are shown below. Active goals continue automatically by default. Thinking and tool calls appear as collapsed conversation entries that can be expanded. Terminal reads return early after reliable shell completion. Terminal output is read on demand without automatic forwarding; a completed explicit recording and a saved workflow alias are shown. Archive status distinguishes successful checkpoints from successful persistence. Pi runtime settings show the built-in runtime and an optional Node override, host-only tools and opt-in automatic context compaction. The provider list includes Kimi and Alibaba Cloud Coding Plan connections. Custom OpenAI-compatible settings show an example Base URL, model, protocol and authentication. Version 0.8.2 example with optional Pi SDK runtime, built-in Node 22.19+, manual context compaction and structured retry waiting.</desc>
4
4
  <defs>
5
5
  <linearGradient id="background" x2="1" y2="1"><stop stop-color="#0c1622"/><stop offset="1" stop-color="#151729"/></linearGradient>
6
6
  <linearGradient id="outline"><stop stop-color="#375d5d"/><stop offset="1" stop-color="#3b3d5c"/></linearGradient>
@@ -10,12 +10,12 @@ text{font-family:"DejaVu Sans",sans-serif;fill:#e8eff9}
10
10
  .mono{font-family:"DejaVu Sans Mono",monospace}
11
11
  </style>
12
12
 
13
- <rect x="0" y="0" width="1800" height="1440" rx="24" fill="url(#background)"/>
13
+ <rect x="0" y="0" width="1800" height="1900" rx="24" fill="url(#background)"/>
14
14
  <rect x="48" y="38" width="42" height="38" rx="10" fill="#173a33" stroke="#306355"/>
15
15
  <text x="56" y="65" font-size="23" font-weight="700" style="fill:#8ae6c2" class="mono">&gt;_</text>
16
16
  <text x="106" y="66" font-size="21" font-weight="700" style="fill:#a7b8cb">TABBY AI TOOLS</text>
17
17
  <rect x="1534" y="44" width="218" height="28" rx="6" fill="#22313f"/>
18
- <text x="1544" y="64" font-size="16" font-weight="600" style="fill:#8ae6c2">v0.7.1 / Pi optional</text>
18
+ <text x="1544" y="64" font-size="16" font-weight="600" style="fill:#8ae6c2">v0.8.2 / CLI startup</text>
19
19
  <text x="48" y="134" font-size="54" font-weight="700" style="fill:#f1f6ff">Your terminals. Working together.</text>
20
20
  <text x="50" y="176" font-size="23" font-weight="400" style="fill:#a7b8cb">Codex + Claude Code + APIs + optional Pi SDK / Terminal tools / Scheduled AI tasks</text>
21
21
  <rect x="48" y="210" width="1704" height="632" rx="14" fill="#0d1520" stroke="url(#outline)"/>
@@ -84,6 +84,7 @@ text{font-family:"DejaVu Sans",sans-serif;fill:#e8eff9}
84
84
  <text x="810" y="286" font-size="17" font-weight="500" style="fill:#a7b8cb" class="mono">staging-app</text>
85
85
  <text x="1029" y="286" font-size="17" font-weight="400" style="fill:#8ca0b8" class="mono">local</text>
86
86
  <text x="1720" y="286" font-size="22" font-weight="400" style="fill:#a7b8cb">+</text>
87
+ <rect x="798" y="258" width="146" height="3" fill="#8ae6c2"/>
87
88
  <path d="M549 297H1751" stroke="#2b3a4d"/>
88
89
  <path d="M1150 297L1150 806" stroke="#2b3a4d"/>
89
90
  <text x="574" y="331" font-size="16" font-weight="700" style="fill:#8ae6c2">1 DATABASE</text>
@@ -131,38 +132,38 @@ text{font-family:"DejaVu Sans",sans-serif;fill:#e8eff9}
131
132
  <path d="M72 1061H1071" stroke="#2b3a4d"/>
132
133
  <rect x="72" y="1068" width="240" height="42" rx="5" fill="#233246" stroke="#3c5068"/>
133
134
  <text x="84" y="1086" font-size="14" font-weight="600">Codex · Default</text>
134
- <text x="84" y="1102" font-size="12" style="fill:#a7b8cb">Local login / newest CLI</text>
135
+ <text x="84" y="1102" font-size="12" style="fill:#a7b8cb">Local login / shared discovery</text>
135
136
  <rect x="322" y="1068" width="240" height="42" rx="5" fill="#233246" stroke="#3c5068"/>
136
137
  <text x="334" y="1086" font-size="14" font-weight="600">Claude Code</text>
137
- <text x="334" y="1102" font-size="12" style="fill:#a7b8cb">Local login / CLI</text>
138
+ <text x="334" y="1102" font-size="12" style="fill:#a7b8cb">Local login / shared discovery</text>
138
139
  <rect x="572" y="1068" width="240" height="42" rx="5" fill="#203e36" stroke="#43866f"/>
139
- <text x="584" y="1086" font-size="14" font-weight="600">Example API connection</text>
140
- <text x="584" y="1102" font-size="12" style="fill:#a7b8cb">Custom · your-model-id</text>
140
+ <text x="584" y="1086" font-size="14" font-weight="600">Example Pi connection</text>
141
+ <text x="584" y="1102" font-size="12" style="fill:#a7b8cb">Google · gemini-2.5-flash</text>
141
142
  <text x="830" y="1086" font-size="14" style="fill:#a7b8cb">Workflows + helper model</text>
142
143
  <text x="830" y="1104" font-size="14" style="fill:#a7b8cb">Scheduled tasks</text>
143
- <text x="72" y="1125" font-size="12" style="fill:#8ca0b8">Two-row connection cards · Forms scroll with the settings page</text>
144
+ <text x="72" y="1125" font-size="12" style="fill:#8ca0b8">Connection drafts · Reconnect when idle to apply · Active tasks keep their snapshot</text>
144
145
  <rect x="1122" y="878" width="630" height="254" rx="12" fill="#172130" stroke="#35475c"/>
145
- <text x="1146" y="915" font-size="22" font-weight="650" style="fill:#edf5ff">Pi SDK / Example runtime settings</text>
146
+ <text x="1146" y="915" font-size="22" font-weight="650" style="fill:#edf5ff">Pi SDK / Example connection draft</text>
146
147
  <text x="1146" y="946" font-size="16" style="fill:#a7b8cb">SDK bundled · Tabby built-in Node by default</text>
147
148
  <rect x="1146" y="960" width="580" height="31" rx="5" fill="#233246"/>
148
- <text x="1160" y="981" font-size="16">Compatibility Node (optional): leave blank</text>
149
- <text x="1160" y="1015" font-size="16">API Agent</text>
150
- <text x="1315" y="1015" font-size="16">Pi SDK</text>
149
+ <text x="1160" y="981" font-size="16">Native provider: Google Gemini / OpenRouter</text>
150
+ <text x="1160" y="1015" font-size="16">SDK catalog</text>
151
+ <text x="1315" y="1015" font-size="16">1.4.0</text>
151
152
  <rect x="1475" y="997" width="251" height="28" rx="5" fill="#286a54"/>
152
- <text x="1490" y="1016" font-size="16" style="fill:#e8fff5">Pi SDK selected</text>
153
- <text x="1146" y="1052" font-size="15" style="fill:#a7b8cb">Automatic compaction (optional)</text>
153
+ <text x="1490" y="1016" font-size="16" style="fill:#e8fff5">API Key path</text>
154
+ <text x="1146" y="1052" font-size="15" style="fill:#a7b8cb">Offline models / custom protocols</text>
154
155
  <rect x="1146" y="1063" width="461" height="28" rx="5" fill="#233246"/>
155
- <text x="1160" y="1083" font-size="14" style="fill:#a7b8cb">Off by default; /compact manually</text>
156
+ <text x="1160" y="1083" font-size="14" style="fill:#a7b8cb">Catalog is not account authorization</text>
156
157
  <rect x="1619" y="1063" width="107" height="28" rx="5" fill="#253348"/>
157
- <text x="1648" y="1083" font-size="14">Saved</text>
158
+ <text x="1648" y="1083" font-size="14">Draft</text>
158
159
  <text x="1146" y="1116" font-size="15" style="fill:#8ae6c2">Host tools only · Workflow checkpoints and helper budgets</text>
159
160
  <rect x="48" y="1152" width="1704" height="204" rx="12" fill="#172130" stroke="#35475c"/>
160
- <text x="72" y="1177" font-size="18" font-weight="650" style="fill:#edf5ff">Example API connection</text>
161
- <text x="72" y="1198" font-size="14" style="fill:#a7b8cb">Custom (OpenAI compatible) · your-model-id</text>
161
+ <text x="72" y="1177" font-size="18" font-weight="650" style="fill:#edf5ff">Example Pi connection</text>
162
+ <text x="72" y="1198" font-size="14" style="fill:#a7b8cb">Custom endpoint · explicit model capabilities</text>
162
163
  <path d="M49 1210H1751" stroke="#2b3a4d"/>
163
164
  <text x="72" y="1239" font-size="16" style="fill:#a7b8cb">API protocol</text>
164
165
  <rect x="260" y="1217" width="580" height="33" rx="5" fill="#233246"/>
165
- <text x="276" y="1240" font-size="16">Chat Completions (default) / Responses</text>
166
+ <text x="276" y="1240" font-size="16">Chat / Responses / Anthropic / Google</text>
166
167
  <text x="890" y="1239" font-size="16" style="fill:#a7b8cb">Key source</text>
167
168
  <rect x="1080" y="1217" width="646" height="33" rx="5" fill="#233246"/>
168
169
  <text x="1096" y="1240" font-size="16">Direct key / Environment variable / No API key</text>
@@ -171,8 +172,29 @@ text{font-family:"DejaVu Sans",sans-serif;fill:#e8eff9}
171
172
  <text x="276" y="1288" font-size="16">https://gateway.example/v1</text>
172
173
  <text x="890" y="1287" font-size="16" style="fill:#a7b8cb">Model ID</text>
173
174
  <rect x="1080" y="1265" width="646" height="33" rx="5" fill="#233246"/>
174
- <text x="1096" y="1288" font-size="16">your-model-id / Discover or enter manually</text>
175
- <text x="72" y="1342" font-size="16" style="fill:#8ae6c2">/remember: if / else → interaction helper → verify → resume · Stop cancels helper calls</text>
176
- <text x="49" y="1393" font-size="16" font-weight="400" style="fill:#8ca0b8">INTERFACE ILLUSTRATION · Example connections and task output; not a running screenshot.</text>
177
- <text x="49" y="1418" font-size="14" font-weight="400" style="fill:#8ca0b8">Appearance varies with your Tabby theme, window size and configured connections.</text>
175
+ <text x="1096" y="1288" font-size="16">your-model-id / offline catalog or explicit limits</text>
176
+ <text x="72" y="1342" font-size="16" style="fill:#8ae6c2">Save connection / Discard draft / Copy as new · Local checks and paid tool tests are separate</text>
177
+ <rect x="48" y="1372" width="1030" height="172" rx="12" fill="#172130" stroke="#35475c"/>
178
+ <text x="72" y="1403" font-size="21" font-weight="650">Instructions and sessions / example</text>
179
+ <text x="72" y="1437" font-size="17" style="fill:#a7b8cb">AI Tools default / per-connection override</text>
180
+ <text x="72" y="1470" font-size="17">AGENTS.md · Inline text · Inherit · No custom layer</text>
181
+ <text x="72" y="1507" font-size="16" style="fill:#8ae6c2">Save / Discard / Preview · New sessions freeze a snapshot</text>
182
+ <rect x="1100" y="1372" width="652" height="172" rx="12" fill="#172130" stroke="#35475c"/>
183
+ <text x="1124" y="1403" font-size="21" font-weight="650">Codex / Claude Code · Private history</text>
184
+ <text x="1124" y="1437" font-size="16" style="fill:#a7b8cb">Tabby space / system compatibility</text>
185
+ <text x="1124" y="1470" font-size="16">Login command / Check login / Save space</text>
186
+ <text x="1124" y="1507" font-size="16" style="fill:#8ae6c2">Same workspace · Original histories retained</text>
187
+ <rect x="48" y="1562" width="1704" height="248" rx="12" fill="#172130" stroke="#35475c"/>
188
+ <text x="72" y="1596" font-size="22" font-weight="650">Clipboard attachments / inline preview example</text>
189
+ <rect x="72" y="1620" width="72" height="72" rx="8" fill="#243247" stroke="#4c657f"/>
190
+ <path d="M85 1677L103 1655L117 1668L131 1647" fill="none" stroke="#8ae6c2" stroke-width="4"/>
191
+ <text x="164" y="1645" font-size="19">screenshot.png · 128 KiB ×</text>
192
+ <text x="164" y="1676" font-size="16" style="fill:#a7b8cb">Ctrl+V / Cmd+V in composer · image thumbnail · remove inline</text>
193
+ <rect x="72" y="1714" width="1010" height="10" rx="5" fill="#263a4e"/>
194
+ <rect x="72" y="1714" width="686" height="10" rx="5" fill="#8ae6c2"/>
195
+ <text x="1110" y="1724" font-size="18" style="fill:#8ae6c2">68% · Native target-tab progress</text>
196
+ <text x="72" y="1760" font-size="16" style="fill:#a7b8cb">SFTP → independent exec → base64 fallback · SHA-256 verification · Ask assistant for status / cancel / path</text>
197
+ <text x="72" y="1790" font-size="15" style="fill:#a7b8cb">Upload is separate from attaching an image to Codex. Sidebar model visual input is not included.</text>
198
+ <text x="49" y="1846" font-size="16" font-weight="400" style="fill:#8ca0b8">INTERFACE ILLUSTRATION · Example connections and task output; not a running screenshot.</text>
199
+ <text x="49" y="1871" font-size="14" font-weight="400" style="fill:#8ca0b8">Appearance varies with your Tabby theme, window size and configured connections.</text>
178
200
  </svg>
@@ -0,0 +1,31 @@
1
+ # Files, clipboard images and SSH transfers
2
+
3
+ Paste a screenshot or copied file directly into the AI Tools composer with **Ctrl+V** (**Cmd+V** on macOS), or drag files into it. Attachments appear inline above the input with their name, size and a remove button; pasted images show thumbnails. There is no attachment button or transfer popup. Plain text pastes normally.
4
+
5
+ For SSH uploads and downloads, ask the assistant to use the attachment tools with the exact connected native SSH terminal and an existing absolute upload parent directory (default `/tmp` on POSIX servers). The plugin creates a unique private subdirectory and never overwrites an existing project file. Downloads require the remote file's absolute path and are stored in the attachment cache. Query transfer status or request cancellation through the assistant; the target tab also shows Tabby's native progress bar. Integrity verification finishes before an operation reports success. Closing the sidebar does not stop a transfer.
6
+
7
+ Files stay in a private cache next to the Tabby configuration directory, under `tabby-agent-attachments`. Attachments are associated with the AI conversation; metadata survives restarts and **Remove attachment** deletes the local cached file. Completed remote uploads remain at their returned paths until explicitly removed on the remote machine. The latest 200 transfer receipts and request keys are retained. After restarting, unfinished operations are marked unknown; operations owned by another window are not resumed or cancelled by this window. Inspect the saved target/window before starting a new request. Restarting never resumes or repeats an upload automatically.
8
+
9
+ ## One transfer, no model chunk relay
10
+
11
+ The assistant can call `attachment_list`, `attachment_upload`, `attachment_download`, `attachment_status` and `attachment_cancel`. One upload/download request starts a plugin-owned operation. The plugin streams all chunks, performs SHA-256 checks and returns metadata and a verified receipt. For long transfers, status queries observe the same operation; they do not advance the next chunk. File bytes and base64 are never tool-result text, and the plugin does not call a model merely to move data.
12
+
13
+ An upload accepts an attachment ID from the current conversation. Its optional `remotePath` means the **parent directory**, not an overwrite destination. A download accepts a remote absolute filename and saves into the plugin's cache; models cannot select arbitrary local write paths. Attachment transfers are not recorded/replayed as reusable workflow steps; transfer the file before starting a recording or alias. Both directions respect existing tool permissions and approval policy. Read-only mode disables transfers, including downloads that create local files.
14
+
15
+ Transport order is the existing connection's SFTP, independent SSH exec with raw byte streams, independent exec with base64, then framed base64 in a positively identified idle Shell. Only a missing capability permits fallback. Permission errors, full disks, checksum failures and ambiguous results do not bypass those checks by trying another transport. Independent channels reuse SSH authentication and jump-host handling, without X11, a separate login, a file panel or a remote Agent installation.
16
+
17
+ Where independent exec is available, SFTP uploads create their private directory with `umask 077` on that connection, avoiding a directory SETSTAT incompatibility in the host's russh 0.1.38. File contents still use SFTP. SFTP verifies uploads by streaming them back and comparing SHA-256. Downloads reread the source and compare metadata and digest before publishing the local cache entry. Exec and PTY modes require an existing POSIX Shell, `base64` where used, and `sha256sum` or `shasum`; no runtime is installed. Limits are 100 MiB per file, 20 MiB / 40 million pixels per composer image, and eight attachments / 200 MiB per conversation. Transfers have a two-minute timeout. Payload capture is separate from ordinary screen snapshots.
18
+
19
+ ## Remote Codex and other terminal Agents
20
+
21
+ Independent SFTP/exec can upload while Codex keeps running. Copy the resulting path and give it to the intended Agent through its supported image/file input. Uploading a picture is not proof that the Agent attached or read it. This release does not automatically press Enter, alter a terminal draft, attach an image to an existing Codex conversation or send it to the sidebar model.
22
+
23
+ The target is the **outer SSH host and account**. Nested SSH, containers, switched users and Agent sandboxes may not see that path. Confirm access before reporting delivery. On servers without `/tmp`, choose an appropriate existing parent; exec/PTY fallbacks are POSIX-only.
24
+
25
+ The last PTY fallback requires the same live session, reliable recent Shell completion and exclusive input control. It refuses unknown Shell state and does not interrupt a running Codex, Claude, editor or other program. If it fails/cancels without a final frame, the receiver may still be waiting: inspect the terminal before releasing input or retrying. Payload is suppressed from AI reads and workflow records, but the terminal frontend or external recording can still contain transferred text.
26
+
27
+ Cancellation closes this operation's resources, not the shared SSH connection. A disconnect or missing publish acknowledgement can leave an **unknown** result; inspect the unique remote path before retrying. A verified receipt proves file integrity at transfer time, not deployment or Agent task success.
28
+
29
+ ## Validation scope
30
+
31
+ Fixtures exercise byte-exact SFTP, real local POSIX exec and Linux PTY round trips, changing files, owner isolation, request deduplication and native progress contention. Local subprocess fixtures are not authenticated SSH network tests. Actual desktop/SSH evidence is recorded separately in `VALIDATION.md` and the release notes; tests make no paid model requests.
@@ -7,13 +7,13 @@ Version 0.4.1 includes **Claude Code (local login)** alongside native Codex and
7
7
  ## Setup
8
8
 
9
9
  1. Install the [official Claude Code CLI](https://code.claude.com/docs/en/setup) on the computer running Tabby.
10
- 2. Run `claude auth login` in a local terminal and choose your Claude account to use an eligible subscription. Check `claude auth status` and confirm the intended authentication method. Existing API keys, API key helpers, or cloud-provider configuration may select separately billed usage; the plugin preserves the CLI's authentication options.
10
+ 2. In **Settings → AI Tools → Claude Code → Instructions and sessions**, choose the session space. Unused connections default to a Tabby private space; existing saved CLI references retain system compatibility mode. Generate its login command and run it in a local terminal, choosing your Claude account to use an eligible subscription. Check the selected-space login in Settings. A plain `claude auth login`/`claude auth status` uses your terminal's own configured space and may authenticate a different location.
11
11
  3. In **Settings → AI Tools → Claude Code**, set the executable path if discovery cannot find it. Select **Claude Code (local login)** in the sidebar or make it the default connection. The default alias is `sonnet`; `opus`, `haiku`, and full model IDs can also be configured. These are candidate aliases, not an account entitlement list.
12
12
  4. Describe a task. Operations use the same Tabby tools, read-only restrictions, approvals, workflow checkpoints, and execution records as API connections. The host's operating system permissions still apply; this mode does not supply an OS sandbox.
13
13
 
14
14
  The executable resolver checks PATH, the official `~/.local/bin` location, common Homebrew/npm directories, and the current executable's directory. Explicit paths, quoted paths, and `~/` paths are supported. A custom command name searches PATH only. Windows `.exe`, `.com`, `.cmd`, and `.bat` launchers are supported. Custom Node/npm prefixes outside these locations need an explicit path and a working Node environment.
15
15
 
16
- Connecting checks `--help` and `auth status` without model inference. The CLI must support the integration flags, including `--system-prompt-snapshot`, `--append-system-prompt-file`, strict MCP configuration, and streaming partial messages. Update Claude Code if the connection reports a missing flag. No account credentials are read from files or saved by the plugin.
16
+ Connecting checks `--help` and `auth status` without model inference, using the same configuration environment as inference. The CLI must support the integration flags, including `--system-prompt-snapshot`, `--append-system-prompt-file`, strict MCP configuration, and streaming partial messages. Update Claude Code if the connection reports a missing flag. The official CLI manages its credentials; the plugin does not read or copy credential files. Private mode uses `CLAUDE_CONFIG_DIR` and removes inherited API-key/token and cloud-routing overrides, while system compatibility retains existing authentication options. OS credential stores and managed policies can still affect an account. See [instruction snapshots, private history and migration](instructions-sessions.md).
17
17
 
18
18
  ## Design decision and official sources
19
19
 
@@ -153,3 +153,37 @@ Stable GitHub Releases trigger `.github/workflows/publish.yml`. After exact-comm
153
153
  `workflow-policy.ts` defines bounded declarative predicates and response policies; `task-memory.ts` records intents and maintains ordered identity/result gates. `workflow-runner.ts` interprets conditional steps and independent verification, and `workflow-session.ts` binds calls to the current connection, Goal budget and cancellation. `workflow-decision.ts` uses isolated tool-free decision sessions; the backend factory applies model overrides to Codex, Claude Code, API and Pi without mutating the foreground profile. Temporary auxiliary transcripts are removed after disposal. v2 libraries retain v1 compatibility; separate minimal run journals omit raw observations, replies and live tab IDs. Offline fixtures in `test/workflow.test.js` cover rule execution, helper fallback, stale decisions, duplicate input, unknown results, restart/rebind and budget attribution. General TUI interpretation and missing shell completion still require the main model.
154
154
 
155
155
  Windows 默认 CLI 选择:`node --test test/codex-version.test.js test/executable.test.js test/windows-launch.test.js test/installations.test.js` 验证语义版本比较、多个 PATH 入口、桌面升级目录清理、固定路径、超时与取消。Linux 上的 win32 文件系统模拟不替代真实 Windows 启动测试。
156
+
157
+ ## Pi provider configuration (v0.8.0 P0/P1)
158
+
159
+ Keep both SDK packages pinned to 1.4.0. `runtime/pi/resolver.mts` is the connection/model/auth resolver used by the sidecar and local no-inference check; it creates an in-memory credential store, disables user models and network refresh, and rejects deferred providers. `npm run pi:catalog` (Node 22.19+) generates the safe offline `src/pi-catalog.json` DTO through that resolver; `npm run pi:catalog:check` verifies reproducibility. Angular never imports the SDK. `pi:build` includes the resolver inside the sidecar (its separate internal test bundle in `artifacts/` is not shipped), while native request paths skip legacy provider payload patches.
160
+
161
+ Use the P0/P1 fixtures in `test/pi-agent.test.js` for native Gemini/OpenRouter, endpoint metadata preservation, independent credentials, all four custom streaming protocols and host-tool round trips. Gemini SSE fixtures must use `data:` events; the pinned Google client ignores blocks beginning with `event:`. `test/pi-settings.test.js` covers draft isolation, cancellation, save failure, copying, capabilities and legacy fingerprints. These use local HTTP only, never real model credentials. Test the extracted reviewed tarball too, then `npm run test:package -- /absolute/path/package.tgz` for scripts-enabled installation without Node on PATH. Bedrock's variable dynamic import remains unavailable: statically bundling it exposes additional optional `kerberos` dependency requirements; the existing external-import check alone is not evidence of support.
162
+
163
+ P2/P3 remain pending. Custom instructions and private CLI storage are implemented separately below; local Linux fixtures, Linux Electron utility-process evidence, remote three-platform CI and real provider/account tests must be reported separately. Release validation and publishing follow the repository release workflow.
164
+
165
+ Windows 桌面 Codex 路径回归:`node --test test/executable.test.js test/windows-launch.test.js test/installations.test.js`。覆盖稳定 bin 目录、升级目录清理、旧 PATH 安装优先级、显式路径固定及禁止跨安装降级。Linux 的 win32 文件系统模拟不代表真实 Windows 启动;后者仅在 Windows 运行。
166
+
167
+ Windows 默认启动还通过 `test/codex-version.test.js` 验证 PATH 旧版与桌面新版共存、文件时间与真实版本相反、多个 PATH 入口、预发布语义比较、超时/异常输出及取消清理。同步文件定位器保留原优先级,实际异步启动器收集候选并查询版本。`--version` 不启动模型;明确文件路径固定版本。
168
+
169
+ ## Custom instructions and CLI session storage
170
+
171
+ `agent-instructions.ts` validates the explicit text/file source, bounds UTF-8 reads at 32 KiB and produces a hashed immutable snapshot. `ApiSession.instructions` and the Codex private index persist it; missing metadata on old sessions represents an empty custom layer. Instruction changes never participate in provider compatibility fingerprints. Do not enable Pi's resource discovery to load a user-selected file. Settings provide explicit drafts and source/content preview; ordinary logs and configuration exports must not include saved session snapshots.
172
+
173
+ `session-space.ts` resolves stable Codex/Claude connection identities beneath the Tabby data root, prepares a manifest and constructs child-only environments. Executable discovery uses the original environment; private storage is applied afterward. Codex overrides both SQLite configuration/environment and log/auth storage; its client cache includes the space. Claude passes the same environment to auth inspection and inference. Native references and host indexes use the selected space, with separate legacy dictionaries for system mode. Session locks reject simultaneous writers and can recover after a recorded owner process exits. Private Codex clients are panel-owned; the legacy background runtime does not start an unused server in the system home for private connections.
174
+
175
+ Tests use offline process/MCP fixtures and temporary homes. The system Codex CLI can also be checked with `account/read`, `thread/start` and `thread/read` without `turn/start`; do not introduce paid model calls into routine verification. Validate actual desktop config persistence because Tabby's dynamic dictionaries require nonstructural defaults. Platform credential stores can differ; CLI history isolation does not establish independent account or OS sandbox boundaries. See [user instructions](instructions-sessions.md) and VALIDATION.md for current evidence.
176
+
177
+ ## SSH attachment transfers (0.8.0)
178
+
179
+ AttachmentStore owns immutable private snapshots; AttachmentTransferService owns bounded operations, idempotency and UI events. Model tools return receipts rather than base64. attachment-transport.ts streams SFTP and independent exec, with SHA-256 verification before publication; attachment-pty.ts provides the guarded POSIX fallback. Native tab progress uses the actual percentage rendering of TabHeader (0–100), despite the host type comment claiming 0–1. Other progress producers take precedence. Do not infer an Agent attached an image from an upload receipt.
180
+
181
+ The composer accepts clipboard files and drag-and-drop directly, displays inline thumbnails and removal, and has no attachment button or transfer popup. Cached raster previews enforce conversation ownership and are restored asynchronously; SSH transfers remain available through model tools.
182
+
183
+ Run test/attachments.test.js for filesystem/SFTP fixtures, actual POSIX subprocess and Linux PTY round trips, changing files and owner/idempotency/progress checks. Tests never call a real model. Native desktop, authenticated SSH, Windows/macOS desktop and simulated cross-platform cases must be reported separately.
184
+
185
+ The scoped russh event-buffer retention adapter is adapted from [tabby-ai-workspace-manager](https://github.com/SupremeJulyan/tabby-ai-workspace-manager/blob/b77c4dfe1f2de9e89419a23ce89fc938d1ebf309/src/adapters/exec-event-buffers.ts) (MIT, Copyright 2026 Julyan). Its notice is preserved in source and the bundled license notices. Only attachment-owned channel IDs are retained; other channel cleanup remains unchanged.
186
+
187
+ ### CLI 启动并发
188
+
189
+ `CodexClient` 将缺省空间与 `system:codex` 视为同一连接身份,启动时冻结传给探测的空间,避免后台预连接被侧栏补充空间元数据时取消。后台运行时只报告最新连接尝试的错误。`ClaudeCodeAgent` 对相同 CLI、工作目录与空间的并发连接共享正在进行的就绪检查;替换、关闭和失败后允许重新检查。`test/client.test.js`、`test/runtime.test.js` 与 `test/claude-code.test.js` 覆盖这些竞态及取消/重试,不调用真实模型。
package/docs/guide.md CHANGED
@@ -13,8 +13,8 @@
13
13
  v0.5.1 起,Pi SDK 及其所需 JavaScript 已打包。通过 Tabby 安装/升级插件不需要系统中存在 `node` 命令,也不会执行 `protobufjs` 等 Pi 依赖的安装脚本;Pi 默认通过 Electron 独立进程复用 Tabby 自带 Node;兼容版本的 Tabby 无需额外安装 Node。旧版宿主应优先升级 Tabby,也可显式选择可选的 Node 22.19+ 兼容路径。v0.5.0 的安装兼容性问题请通过升级 v0.5.1 修复,无需全局关闭安装脚本。
14
14
 
15
15
  - 本机安装 [Tabby](https://github.com/Eugeny/tabby),并能访问所选 AI 服务。操作内网服务器时,本机还需能通过 Tabby 连接目标服务器。
16
- - **ChatGPT 订阅/Codex 登录模式**:本机安装 Codex CLI,在本地终端执行 `codex login`,使用具备 Codex 权限的 ChatGPT 账号登录,再执行 `codex login status` 确认认证状态,无需在插件中填写 API Key。插件默认连接选 **Codex(本机登录)**;可用模型、用量和工作区权限以账号实际权益为准。见 [OpenAI 官方认证说明](https://learn.chatgpt.com/docs/auth)。CLI 需支持 `thread/goal/*`;已测试版本见[验证记录](../VALIDATION.md)。
17
- - **Claude 订阅/Claude Code 本机模式**:本机安装官方 Claude Code,运行 `claude auth login`,用 `claude auth status` 核对账号与认证方式。在侧栏或默认连接中选择 **Claude Code(本机登录)**;无需在插件里配置订阅凭据。API Key/云平台可能使用独立计费。完整方案、权限、恢复机制与验证限制见 [Claude Code 接入](claude-code.md)。
16
+ - **ChatGPT 订阅/Codex 登录模式**:本机安装 Codex CLI,选择 **Codex(本机登录)**,在“指令与会话”生成选定空间的登录命令。使用具备 Codex 权限的 ChatGPT 账号完成官方登录,再检查该空间认证,无需填写 API Key。普通 `codex login`/`codex login status` 针对终端当前配置的空间;未使用过的插件连接默认使用 Tabby 独立空间。可用模型、用量和工作区权限以账号实际权益为准。见 [OpenAI 官方认证说明](https://learn.chatgpt.com/docs/auth)。CLI 需支持 `thread/goal/*`;已测试版本见[验证记录](../VALIDATION.md)。
17
+ - **Claude 订阅/Claude Code 本机模式**:本机安装官方 Claude Code,选择 **Claude Code(本机登录)**,在“指令与会话”生成并执行选定空间的 `auth login` 命令,再检查该空间认证。普通 `claude auth login`/`auth status` 可能针对另一份系统配置。插件不复制凭据;账号权益及系统兼容模式的 API/云计费以官方 CLI 状态为准。完整方案、权限、恢复机制与验证限制见 [Claude Code 接入](claude-code.md)。
18
18
  - **API 模式**:准备 OpenAI、DeepSeek、GLM、Kimi、百炼 Coding Plan 或 Claude 对应的 Key,无需安装 Codex CLI。订阅登录与 API 连接是两种独立配置方式。
19
19
 
20
20
  ### 安装插件
@@ -186,7 +186,9 @@ API 工具循环检测始终启用,无需等到轮数上限。近期同一段
186
186
 
187
187
  AI Tools 默认在启动 Tabby 时自动展开侧栏,使用默认连接,无需先进入设置启用。未保存过此选项的已有配置也会默认打开;已明确关闭的配置保持关闭。如需关闭,在 **Settings → AI Tools** 取消勾选 **启动 Tabby 时自动打开 AI Tools**,下次启动生效。工作目录沿用工具栏打开侧栏时的规则:优先使用固定目录,否则尝试读取当前本地终端目录,无法读取时使用用户主目录。手动收起后,本次运行不会再次自动展开。
188
188
 
189
- 插件加载并读取配置后会立即启动常驻的 `codex app-server --listen stdio://`,每个 Tabby 窗口共用一个进程。打开、收起或切换侧栏均复用该服务,通过 JSONL 通知逐段显示流式应答。进程异常退出后自动重连,重试间隔从 1 秒逐步增加到最多 30 秒;服务启动失败会提示检查 CLI 路径。修改并保存 CLI 路径后自动更换进程,其他设置保存不会重启服务。窗口退出或插件销毁时关闭进程并清理重连定时器。
189
+ 使用 Codex 系统会话空间且未选择其他默认连接时,插件加载并读取配置后会启动常驻的 `codex app-server --listen stdio://`,每个 Tabby 窗口共用一个进程。打开、收起或切换侧栏均复用该服务,通过 JSONL 通知逐段显示流式应答。进程异常退出后自动重连,重试间隔从 1 秒逐步增加到最多 30 秒;服务启动失败会提示检查 CLI 路径。修改并保存 CLI 路径后自动更换进程,其他设置保存不会重启服务。窗口退出或插件销毁时关闭进程并清理重连定时器。
190
+
191
+ 同一 Codex 连接的启动预连接与侧栏连接共享 CLI 探测;未指定空间与显式系统空间视为同一目标,不会互相取消。私有空间由各自连接持有服务。Claude Code 对相同可执行文件、工作目录和会话空间的并发连接也共享探测;切换目标或关闭连接仍会取消旧探测,真实路径或登录错误仍会显示。
190
192
 
191
193
  ## 工作目录与线程
192
194
 
@@ -338,3 +340,25 @@ C:\Users\用户名\AppData\Local\OpenAI\Codex\bin
338
340
  空闲时输入 `/compact` 手动压缩。内置 API 保留原始历史,按完整工具批次投影请求;Pi 保留自己的 JSONL 原始条目和压缩边界。自动压缩默认关闭,摘要本身消耗额度并计入 Goal 预算。Pi 的重试倒计时使用 SDK 结构化事件,取消会结束独立进程,不重放整段任务。中断后先读取真实终端再继续,未知动作不会自动重放。
339
341
 
340
342
  Pi 的使用、存储、预算和验证限制见 [Pi runtime](pi.md)。开发与 CI 使用 Node 22.19+;升级系统 Node 不会改变 Electron 内置 Node。当前已验证本地 HTTP 夹具,并在独立配置的 Linux Tabby 1.0.238(Electron 43.7.0 / Node 24.21.0)中跑通侧栏、Pi 子进程、宿主 list_tabs 与 Goal 完成;真实模型、SSH/PTY 修改操作和 macOS/Windows 桌面仍待实测。此功能从 v0.5.0 开始提供。
343
+
344
+ ## Pi 原生 API 连接与草稿(v0.8.0)
345
+
346
+ 新增 API 连接默认推荐 Pi SDK。选择 SDK 内置供应商并搜索 Gemini/OpenRouter 等 ID,离线浏览随 SDK 1.4.0 打包的模型目录,配置当前连接的 Key 或环境变量引用,再保存。目录存在不代表账号授权。自定义接口支持 Chat Completions、Responses、Anthropic Messages、Google Generative AI,需明确模型协议、上下文与最大输出能力;单次输出预算与模型能力分开。
347
+
348
+ 连接编辑使用独立草稿,切换连接或供应商保留输入;保存、放弃、复制不会调用模型。无推理检查只验证本地配置、运行时与凭据存在,实际连接测试会调用模型并产生用量。保存不会热切换任务,空闲时在侧栏重新连接。旧 Pi 产品预设继续兼容。OAuth/云身份与高级导入导出仍待实现,见 [Pi 说明](pi.md#unreleased-native-providers-and-connection-drafts-p0--p1)。
349
+
350
+ ### 自定义 AGENTS.md 与独立 CLI 会话
351
+
352
+ 每个连接下方的 **Instructions and sessions/指令与会话** 支持 AI Tools 全局默认与连接级覆盖。可编辑正文、绑定本地 AGENTS.md 文件、继承默认或关闭自定义层;保存和放弃均显式操作。文件要求绝对路径、UTF-8、最多 32 KiB,可预览内容、来源、摘要和修改时间,不会覆盖源文件。新会话保存指令快照;原文件修改或丢失不影响已有会话恢复。使用 `/new` 应用新指令,文件不可读则阻止依赖它的新会话。内置工具说明与宿主权限检查仍生效,Pi 不因此启用自动发现;Codex/Claude 的原生项目规则另由引擎管理。
353
+
354
+ 未使用过的 Codex/Claude Code 默认采用 **Tabby 独立空间**,已有 CLI 会话引用保留 **系统空间(旧版兼容)**。独立空间隔离磁盘历史及索引,而不仅过滤列表;任务 cwd 保持不变。选择目标空间后生成登录命令,在本地终端完成官方登录,再检查该空间认证并保存。系统 CLI 已登录不代表目标空间已登录,插件不会复制凭据。Windows 命令使用 PowerShell,Linux/macOS 使用 POSIX shell。
355
+
356
+ 空闲时点击侧栏重连以切换空间并交接当前对话,或用 `/new` 开始新对话。旧记录保留原处,失败时仍保留原侧栏会话;不会搬走全部系统历史。定时任务后续运行使用连接当前选定空间和新指令快照,活动任务保留启动时的配置。详细路径、认证边界与验证范围见 [指令与会话说明](instructions-sessions.md)。
357
+
358
+ ## 文件、剪贴板图片与 SSH 传输(v0.8.0)
359
+
360
+ 在输入框中直接按 Ctrl+V(macOS 为 Cmd+V)粘贴截图或文件,也可拖入文件。附件直接显示在输入框上方,包含文件名、大小和移除按钮;粘贴的图片显示缩略图,无需附件按钮或弹窗。普通文本仍正常粘贴。需要 SSH 上传/下载时,让助手使用附件工具,并明确指定已连接的 SSH 终端与绝对路径;目标 tab 显示原生进度,可向助手查询传输状态、取消或取得校验后的远端路径。收起侧栏不停止传输。
361
+
362
+ 传输复用 SSH,优先 SFTP,再使用独立 exec 的二进制/base64,最后才在已确认空闲的 Shell 中使用 PTY base64。插件连续处理分块,不让 AI 逐段读写 base64。只读模式禁止传输。目标是外层 SSH 的机器与账户;容器、嵌套 SSH、切换用户及 Codex 沙箱需另行确认可见性。上传图片不代表 Codex 已附图或读取;本版仅提供复制远端路径,不自动按回车或向侧栏模型发送图片。
363
+
364
+ 图片最多 20 MiB/4000 万像素,普通文件最多 100 MiB;每会话 8 个附件/200 MiB。下载、缓存清理、取消、未知结果及 POSIX 回退限制见 [附件传输说明](attachments.md)。
@@ -0,0 +1,49 @@
1
+ # Custom instructions and CLI session spaces
2
+
3
+ In Settings → AI Tools, select a connection and open **Instructions and sessions**. These settings have explicit Save / Discard actions. Saving does not run a model or interrupt an active task.
4
+
5
+ ## Choose instructions
6
+
7
+ Choose **AI Tools default** to edit the shared default, or **This connection** to override it. A connection can inherit the default, use inline text, bind an absolute local AGENTS.md/Markdown file, or disable the custom layer. The connection override replaces the shared custom layer.
8
+
9
+ Use **Preview selected instructions** to read the chosen content without inference. Bound files must be regular UTF-8 files of at most 32 KiB. The preview shows the source, content hash and file modification time. Saving a file reference never overwrites the original file. A missing/unreadable file can remain saved for later repair, but prevents a new session that depends on it from starting. Relative paths and network URLs are not accepted.
10
+
11
+ New sessions save a private instruction snapshot. Editing the file or changing settings does not alter existing sessions, including after restart. Use `/new` for the new instructions. Existing histories remain visible; instruction changes are separate from connection compatibility fingerprints. For legacy sessions without a custom snapshot, the custom layer stays empty until a new session is created. Scheduled runs resolve the saved instruction configuration at the start of each new run; a missing file fails that run instead of falling back silently.
12
+
13
+ Custom instructions work with Codex, Claude Code, Pi and the existing API runtime. Tabby's built-in tool guidance stays enabled, and host permission/approval/read-only checks remain authoritative. Custom text does not activate hooks, extensions, MCP servers or native shell/file tools. The preview covers only this custom layer: Codex may also load native project AGENTS.md and Claude Code may load native CLAUDE.md. Pi's automatic context-file discovery remains disabled. Local instruction files are not automatically read from an SSH host.
14
+
15
+ ## Separate CLI history
16
+
17
+ Unused Codex and Claude Code connections default to **Tabby private space**. A connection with existing saved CLI thread references retains **System space (legacy compatibility)** until you explicitly change it. The space selector shows its effective mode. API and Pi histories already use Tabby's own store.
18
+
19
+ Private spaces live below the Tabby configuration directory:
20
+
21
+ ```text
22
+ tabby-agent-sessions/spaces/<stable-space-id>/
23
+ manifest.json
24
+ native/ # CLI state, history, indexes and space-local authentication
25
+ index/ # Tabby history, context handoffs and instruction snapshots
26
+ ```
27
+
28
+ Codex receives an explicit `CODEX_HOME`, SQLite and log location after executable discovery. Its process identity includes the space, and its private credential store is file-based. Claude Code receives `CLAUDE_CONFIG_DIR` for both authentication checks and inference. The plugin changes only its child-process environment; it does not change your shell, OS HOME or ordinary CLI directories. Private-mode launch removes inherited API-key/token overrides so a subscription connection does not silently use an unrelated API credential. Proxy and certificate settings remain available. The chosen workspace directory stays unchanged.
29
+
30
+ Tabby only lists/resumes private native sessions whose local metadata belongs to the selected space. A raw native ID cannot cross this boundary. Spaces and thread references are stable across restarts; sessions are not made ephemeral to hide them. Concurrent writers are rejected rather than sharing one native conversation silently.
31
+
32
+ ## Log in and migrate
33
+
34
+ 1. Select the target space. **Generate login command** prepares that space and displays a command for the discovered CLI. It does not execute the command.
35
+ 2. Copy and run it in a local terminal. The generated command uses POSIX shell syntax on Linux/macOS and PowerShell syntax on Windows, quotes paths, and targets the selected space. Complete the official account login there.
36
+ 3. Use **Check selected-space login**. This performs a local CLI/account check without model inference. A logged-in result does not prove a particular model is available or that quota remains.
37
+ 4. **Save session space**, then click the sidebar's reconnect control when idle. When switching spaces, the current conversation can be transferred through Tabby's portable context handoff into a new native session. Existing source records stay in their original location. Use `/new` to start fresh instead.
38
+
39
+ The plugin never copies credential files or imports all system history. Changing the space does not move or erase old shared sessions from your ordinary CLI list. Failed reconnection retains the current sidebar conversation; log in to the target or restore the previous space setting before trying again. Scheduled tasks use the connection's selected space for subsequent runs; active runs keep the backend they started with.
40
+
41
+ System mode deliberately retains existing CLI authentication/environment behavior. Private history does not imply account isolation: platform credential stores and managed policies may still affect an account, particularly with Claude Code. A separate login may be required. This feature is not an operating-system sandbox.
42
+
43
+ ## Evidence and limits
44
+
45
+ Offline process fixtures cover private persistence, process replacement, source/target indexes, instruction snapshots, restoration and authentication-environment consistency. Local Codex 0.166.0 additionally started an app-server in an empty private home, created/read a thread and placed SQLite/log state there without a `turn/start` request. That CLI does not support the extended-turn listing used by some newer app-server versions; the existing history compatibility path remains relevant.
46
+
47
+ Real Claude subscription login, model entitlement and macOS/Windows desktop behavior need their own platform/account validation; fixtures are not proof of those results. See [validation](../VALIDATION.md) for the exact local checks. Native account login remains an action you complete through the official CLI; no paid model smoke test is run automatically.
48
+
49
+ Official references: [Codex locations and overrides](https://learn.chatgpt.com/docs/config-file/environment-variables), [Codex app-server](https://learn.chatgpt.com/docs/app-server), [Claude Code settings](https://code.claude.com/docs/en/settings), [Claude Code CLI](https://code.claude.com/docs/en/cli-reference).
package/docs/pi.md CHANGED
@@ -45,3 +45,70 @@ Upstream API reference: [Pi SDK](https://github.com/earendil-works/pi/blob/f9dac
45
45
  ## Built-in runtime verification
46
46
 
47
47
  In official Linux Tabby 1.0.238 (Electron 43.7.0, built-in Node 24.21.0), the packaged main-process bridge and actual SDK completed streaming and a host-tool round trip with no system Node on PATH. Separate runs verified cancellation while a host-tool result was pending and termination when the owner window was destroyed. All model traffic used a local HTTP fixture; no real model or terminal mutation was performed. Electron renderer Node worker threads are unsupported in that app, and `ELECTRON_RUN_AS_NODE` did not provide the required startup path, so the implementation uses the supported utility-process API. The main bridge owns window/crash cleanup and acknowledges final IPC before the utility exits. macOS/Windows desktop behavior remains unverified; CI covers bridge ownership, cancellation, protocol handling and package installation on those systems.
48
+
49
+ <a id="unreleased-native-providers-and-connection-drafts-p0--p1"></a>
50
+
51
+ ## Native providers and connection drafts (v0.8.0)
52
+
53
+ New API connections recommend Pi SDK. Choose **SDK built-in provider**, search by name or ID (for example Gemini / `google` or OpenRouter), select a model from the offline SDK 1.4.0 catalog, and supply a direct key or an explicitly named environment variable. A blank native Base URL uses the SDK endpoint; an override preserves the provider identity, protocol and model metadata. The model's protocol is authoritative, including providers with mixed protocols. Catalog entries describe SDK capabilities, not your account's access or a successful tool test. Tabby currently sends text input only. Catalog prices are upstream estimates, not subscription balances; custom prices are unknown.
54
+
55
+ **Custom compatible endpoint** supports OpenAI Chat Completions, OpenAI Responses, Anthropic Messages and Google Generative AI. Enter the protocol base URL, model ID, explicit context window and model maximum output capability. The separate per-request output budget cannot exceed the model maximum. Custom local services can select no key; native providers require an explicit credential source. Keep HTTPS except for local loopback fixtures. For a native model absent from the catalog, specify its protocol and capabilities manually.
56
+
57
+ Connection edits are independent drafts. **Save connection** validates and persists locally without sending inference. **Discard draft** restores the saved connection or cancels a new connection; **Copy as new connection** allocates a new ID with empty thread references. Switching connections retains drafts for the lifetime of the settings component, and switching providers retains earlier provider inputs. Unsaved connections cannot become the default. A failed save retains the draft. Reconnect from the sidebar while idle to apply a saved configuration; active backends keep their original configuration. There is no automatic endpoint hot switch or paid test on save.
58
+
59
+ **Check configuration / runtime (no inference)** uses the packaged resolver and selected credential, proving local configuration/runtime compatibility and credential presence only. It does not prove account permission, billing/quota or remote tool support. **Test connection** uses the actual Pi stream and a harmless nonce tool and consumes model usage. Editing endpoint, authentication, model, protocol or parameters invalidates the displayed check. Offline model selection and sidebar `/models` do not call a generic `/models` endpoint or require a key. Network catalog refresh and account-specific catalog queries are deferred to P2.
60
+
61
+ Existing Pi connections remain in **Legacy product presets (compatibility)** with their existing model, endpoint, credentials, thread fingerprint and request patches. Kimi Coding keeps its Chat Completions compatibility, including international/proxy endpoints. Ordinary GLM, ZAI Coding and Alibaba Cloud Coding Plan remain distinct products; copy a connection before choosing native mode and verify the product/region and required key. Codex and Claude Code continue as independent local CLI engines.
62
+
63
+ The full 42-provider catalog is visible, with explicit adapter-pending reasons. Bedrock (AWS identity and opaque dynamic dependency), Vertex, Azure deployment, Cloudflare account/gateway, Copilot, OAuth-only providers and additional protocols are not enabled by this API-key stage. Adding a key to an unavailable entry does not bypass that boundary. P2 (headers, schema JSON/import/export, network refresh) and P3 (OAuth and cloud identity) remain pending.
64
+
65
+ Pi now accepts the shared/per-connection custom instruction snapshot through the host system prompt while keeping automatic context-file/extension discovery disabled. The separate [instructions and CLI spaces](instructions-sessions.md) implementation adds AGENTS.md configuration and private Codex/Claude history without moving Pi's existing session files or enabling new model authentication modes.
66
+
67
+ ### Pinned SDK capability inventory
68
+
69
+ Generated from SDK 1.4.0; 32 providers have the API-key configuration path, 10 are explicitly unavailable. Protocol fixtures prove Gemini/OpenRouter and the four custom protocol families; other enabled providers still require real-account validation. No credentials or provider accounts were used.
70
+
71
+ | Provider ID | Configuration status | Offline chat models |
72
+ | --- | --- | --- |
73
+ | `amazon-bedrock` | AWS identity and dependency adapter pending | 193 |
74
+ | `ant-ling` | API-key path; account unverified | 3 |
75
+ | `anthropic` | API-key path; account unverified | 17 |
76
+ | `azure` | Azure deployment adapter pending | 43 |
77
+ | `baseten` | API-key path; account unverified | 14 |
78
+ | `cerebras` | API-key path; account unverified | 2 |
79
+ | `cloudflare-ai-gateway` | Cloudflare account/gateway adapter pending | 58 |
80
+ | `cloudflare-workers-ai` | Cloudflare account adapter pending | 19 |
81
+ | `deepseek` | API-key path; account unverified | 2 |
82
+ | `fireworks` | API-key path; account unverified | 24 |
83
+ | `github-copilot` | Copilot authentication adapter pending | 26 |
84
+ | `google` | API-key path; account unverified | 24 |
85
+ | `google-vertex` | Google Cloud identity adapter pending | 14 |
86
+ | `groq` | API-key path; account unverified | 7 |
87
+ | `huggingface` | API-key path; account unverified | 80 |
88
+ | `kimi-coding` | API-key path; account unverified | 4 |
89
+ | `meta` | API-key path; account unverified | 6 |
90
+ | `minimax` | API-key path; account unverified | 4 |
91
+ | `minimax-cn` | API-key path; account unverified | 4 |
92
+ | `mistral` | Mistral Conversations protocol adapter pending | 37 |
93
+ | `moonshotai` | API-key path; account unverified | 4 |
94
+ | `moonshotai-cn` | API-key path; account unverified | 4 |
95
+ | `nvidia` | API-key path; account unverified | 21 |
96
+ | `openai` | API-key path; account unverified | 42 |
97
+ | `openai-codex` | Use the independent Codex CLI connection | 7 |
98
+ | `opencode` | API-key path; account unverified | 83 |
99
+ | `opencode-go` | API-key path; account unverified | 29 |
100
+ | `openrouter` | API-key path; account unverified | 401 |
101
+ | `qwen-token-plan` | API-key path; account unverified | 21 |
102
+ | `qwen-token-plan-cn` | API-key path; account unverified | 21 |
103
+ | `qwen-token-plan-individual` | API-key path; account unverified | 9 |
104
+ | `radius` | Radius protocol adapter pending | 32 |
105
+ | `together` | API-key path; account unverified | 15 |
106
+ | `typesafe` | No offline chat catalog available | 0 |
107
+ | `vercel-ai-gateway` | API-key path; account unverified | 305 |
108
+ | `xai` | API-key path; account unverified | 4 |
109
+ | `xiaomi` | API-key path; account unverified | 3 |
110
+ | `xiaomi-token-plan-ams` | API-key path; account unverified | 2 |
111
+ | `xiaomi-token-plan-cn` | API-key path; account unverified | 2 |
112
+ | `xiaomi-token-plan-sgp` | API-key path; account unverified | 2 |
113
+ | `zai` | API-key path; account unverified | 7 |
114
+ | `zai-coding-cn` | API-key path; account unverified | 4 |
@@ -0,0 +1,20 @@
1
+ # 0.8.0 — SSH attachments, native tab progress and connection/session configuration
2
+
3
+ Paste screenshots or add files in **Attachments**, choose a connected SSH terminal and upload into a unique private directory. Download remote regular files into the conversation's attachment cache. File bytes travel through the plugin, with streaming SHA-256 verification and native target-tab progress, rather than repeated model/base64 tool calls. The assistant can start, inspect and cancel the same operations through dedicated attachment tools.
4
+
5
+ Transfers reuse existing authentication. SFTP is preferred, followed by independent exec byte streams, exec base64 and a framed base64 protocol in a verified idle POSIX Shell. Capability failures permit fallback; policy failures and ambiguous results do not. Cancellation and receipts preserve the distinction between completed, failed and unknown writes. The ordinary terminal-reading/command-verification protocol remains unchanged.
6
+
7
+ This release also includes native Pi provider selection and the offline SDK 1.4.0 model catalog, four custom API protocols, explicit connection drafts, immutable custom-instruction snapshots and private Codex/Claude CLI history spaces. Existing connection identities and system-history compatibility remain available. Windows CLI discovery retains the 0.7.1 fixes.
8
+
9
+ Both READMEs, the guide, attachment/development/session documentation, model-facing skill and SVG/PNG overview describe the final capabilities. The overview is an illustration with example data; the robot animation and reduced-motion fallback remain available.
10
+
11
+ ## Boundaries
12
+
13
+ - Upload receipts prove file integrity, not that a terminal Agent attached or read an image. Automatic attachment to an existing Codex composer and sidebar model image input are deferred.
14
+ - Paths belong to the outer SSH host/account. Nested SSH, containers, changed users and Agent sandboxes need explicit visibility checks. POSIX fallback tools must already exist; no runtime is installed remotely.
15
+ - The final PTY fallback requires reliable idle-Shell evidence and does not stop an existing Agent. An ambiguous PTY cancellation can leave a receiver waiting; inspect before releasing input or retrying.
16
+ - Local cached attachments retain metadata across restarts. Transfer receipts survive restarts; unfinished or other-window operations remain unknown and are never replayed automatically. Uploaded remote files remain until explicitly removed.
17
+ - Other native progress producers take precedence over this plugin's tab progress; transfer details remain available in the attachment panel.
18
+ - Real provider/account access, billing and full macOS/Windows desktop behavior are separate from offline/local-host tests. Routine verification makes no paid model calls. OAuth/cloud identity, advanced provider import/export and general read-screen cursor improvements remain deferred.
19
+
20
+ Validation results and platform evidence are recorded in [VALIDATION.md](../../VALIDATION.md). GitHub Actions branch/tag checks and the verified npm tarball SHA-256 are recorded in the GitHub Release.
@@ -0,0 +1,19 @@
1
+ # 0.8.1 — Superseded release candidate
2
+
3
+ The immutable v0.8.1 tag was not published to npm because its Linux tag CI exposed an asynchronous SIGKILL/reaping assumption in an existing lifecycle test. See [0.8.2](0.8.2.md) for the published fixes.
4
+
5
+ ## Candidate changes
6
+
7
+ Codex background startup and the sidebar now reuse CLI discovery for the same system session space. Supplying explicit system-space metadata no longer cancels the startup connection or produces the misleading “Codex app-server was closed during CLI discovery” / background-service failure alert. Superseded startup attempts cannot report stale failures after a replacement connects.
8
+
9
+ Concurrent Claude Code connections to the same executable, working directory and session space share one readiness check. Switching targets or closing a connection still cancels discovery, and genuine CLI/authentication errors remain visible and retryable.
10
+
11
+ The composer accepts clipboard images/files and drag-and-drop directly, with inline names, sizes, removable attachments and image thumbnails. Cached raster previews survive conversation reopening and enforce ownership. SSH upload/download, status, cancellation and verified paths remain available through assistant tools; the old attachment button and transfer popup are removed. Images are not automatically sent to sidebar models or attached to a terminal Agent.
12
+
13
+ Both READMEs, guide, development/attachment notes, bundled skill/knowledge and synchronized SVG/PNG illustration reflect the final interaction. The existing robot GIF and reduced-motion static fallback are retained.
14
+
15
+ Validation: Linux / Node 22.23.3 runs 860 tests (854 passed, 6 platform skips), with skill bundle/check, both TypeScript boundaries, production build and whitespace checks. The actual release tarball is checked for complete public artifacts, excluded local files and installation with lifecycle scripts enabled and no node on PATH. Three-platform branch/tag CI and the exact artifact SHA-256 are recorded in the GitHub Release.
16
+
17
+ The Windows CI cancellation fixture now waits until SFTP opening has actually begun before cancelling, instead of assuming disk persistence finishes within 10 ms. Production cancellation behavior is unchanged.
18
+
19
+ These are offline/local fixture checks. Actual Tabby desktop startup, OS clipboard behavior, Windows/macOS desktop operation and real account/model inference have not been newly verified for this patch. The default development shell uses Node 20 and fails two existing Pi fixture setups requiring Node >=22.19; the release checks use the supported Node 22 toolchain.
@@ -0,0 +1,17 @@
1
+ # 0.8.2 — Reliable CLI startup and inline attachments
2
+
3
+ Codex background startup and the sidebar now reuse CLI discovery for the same system session space. Supplying explicit system-space metadata no longer cancels the startup connection or produces the misleading “Codex app-server was closed during CLI discovery” / background-service failure alert. Superseded startup attempts cannot report stale failures after a replacement connects.
4
+
5
+ Concurrent Claude Code connections to the same executable, working directory and session space share one readiness check. Switching targets or closing a connection still cancels discovery, and genuine CLI/authentication errors remain visible and retryable.
6
+
7
+ The composer accepts clipboard images/files and drag-and-drop directly, with inline names, sizes, removable attachments and image thumbnails. Cached raster previews survive conversation reopening and enforce ownership. SSH upload/download, status, cancellation and verified paths remain available through assistant tools; the old attachment button and transfer popup are removed. Images are not automatically sent to sidebar models or attached to a terminal Agent.
8
+
9
+ Both READMEs, guide, development/attachment notes, bundled skill/knowledge and synchronized SVG/PNG illustration reflect the final interaction. The existing robot GIF and reduced-motion static fallback are retained.
10
+
11
+ Validation: Linux / Node 22.23.3 runs 860 tests (854 passed, 6 platform skips), with skill bundle/check, both TypeScript boundaries, production build and whitespace checks. The actual release tarball is checked for complete public artifacts, excluded local files and installation with lifecycle scripts enabled and no node on PATH. Three-platform branch/tag CI and the exact artifact SHA-256 are recorded in the GitHub Release.
12
+
13
+ The Windows CI cancellation fixture now waits until SFTP opening has actually begun before cancelling, instead of assuming disk persistence finishes within 10 ms. Production cancellation behavior is unchanged.
14
+
15
+ The process-lifecycle fixture also waits with a bounded deadline for killed descendants to disappear or enter a Linux zombie state; it no longer assumes SIGKILL delivery and kernel reaping finish synchronously. It still fails if a live descendant remains. The v0.8.1 tag is retained without npm publication.
16
+
17
+ These are offline/local fixture checks. Actual Tabby desktop startup, OS clipboard behavior, Windows/macOS desktop operation and real account/model inference have not been newly verified for this patch. The default development shell uses Node 20 and fails two existing Pi fixture setups requiring Node >=22.19; the release checks use the supported Node 22 toolchain.
@@ -0,0 +1,7 @@
1
+ # Unreleased — custom instructions and private CLI history
2
+
3
+ AI Tools settings now support shared and per-connection instruction text or a local AGENTS.md reference, with explicit Save/Discard, source preview and bounded UTF-8 validation. New sessions persist an instruction snapshot, so file changes or removal do not silently alter a restored conversation. `/new` applies new instructions. The selected layer works across Codex, Claude Code, Pi and API runtimes, retaining built-in tool guidance and host policies.
4
+
5
+ Unused Codex/Claude Code connections default to a Tabby private session space. Existing CLI references retain an explicit system compatibility mode. Native state, indexes, restore checks and authentication inspection target the chosen space without changing the workspace or copying credentials. Settings generate a quoted login command for the selected space; the user completes official authentication locally. Idle reconnection can transfer the current conversation while preserving source history; completed identical handoffs are reused and concurrent native writers are rejected.
6
+
7
+ The bilingual README, guide, developer notes, model-facing skill/knowledge and SVG/PNG overview are synchronized. Local Node 22 tests, offline CLI/MCP fixtures, an isolated real Linux Tabby settings preview and no-inference Codex startup checks provide the validation scope recorded in VALIDATION.md. Actual Claude account login, subscription/model access and macOS/Windows desktop behavior remain unverified. No release or npm publication is included in this implementation session.
@@ -0,0 +1,9 @@
1
+ # Unreleased — Pi native API configuration (P0/P1)
2
+
3
+ New API connections recommend Pi SDK 1.4.0 with searchable native providers, offline model metadata, explicit API-key/environment authentication and four custom protocols. Native Gemini and OpenRouter retain their SDK identity and metadata through endpoint overrides. Manual models require explicit capabilities; request output budgets and SDK thinking levels are validated.
4
+
5
+ Connection edits use independent Save / Discard / Copy drafts. Saving does not infer or hot-switch an active task. The no-inference runtime/configuration check and explicit usage-consuming model/tool test have separate meanings. Legacy Pi connections, Kimi/Alibaba product presets, native history and both independent CLI engines retain their compatibility paths. Host tool permissions and bundled Electron launch are preserved.
6
+
7
+ The bilingual README, guide, Pi/development docs, model-facing skill/knowledge and SVG/PNG overview describe the new behavior. The full SDK provider catalog labels unavailable adapters. P2/P3 remain pending; this delivery does not claim OAuth, cloud identity, arbitrary headers/JSON import/export or remote catalog refresh. The separate [custom instructions and CLI spaces](../instructions-sessions.md) change adds its own settings, persistence and compatibility paths; its platform/account evidence is recorded separately.
8
+
9
+ Validation uses local fixtures and the actual pinned SDK, with no paid model calls. See VALIDATION.md for exact local check, desktop and tarball evidence. No commit, tag, remote CI or publication is part of this implementation session.
@@ -12,6 +12,8 @@ AI 会通过定时任务工具保存任务,返回任务 ID、下一次执行
12
12
 
13
13
  到点后由插件启动独立 AI 会话,重新发现终端并核对目标。AI 调用与普通对话相同的工具,读取操作结果后决定下一步,可以多次执行、等待、读取和调整方案。每次工具结果都会交回模型;没有把历史命令当作固定脚本重放。
14
14
 
15
+ 每次新运行使用连接当前保存的自定义指令配置并固定本次快照。Codex/Claude Code 使用该连接选定的系统或 Tabby 独立会话空间,认证检查和模型调用保持一致;独立空间需提前完成相应登录。指令文件不可读或目标空间未登录时如实记录失败,不会回退到系统默认认证或另一份指令。运行中的任务保留原后端,后续运行才应用已保存的空间修改。见 [指令与会话空间](instructions-sessions.md)。
16
+
15
17
  AI 需通过 `scheduled_task_finish` 提交有验证依据的完成结论或需人工处理的原因。普通回合结束但未提交结论时,调度器继续同一次运行,最多 8 个对话回合、30 分钟。API 每回合工具轮数仍使用连接配置;创建时设置的目标 token 预算适用于整次运行,以供应商上报用量为软上限。达到限制不代表完成。
16
18
 
17
19
  点击输入框旁的 **定时任务**,或输入 `/schedules`:
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "tabby-ai-tools",
3
- "version": "0.7.1",
3
+ "version": "0.8.2",
4
4
  "description": "A persistent AI agent sidebar for Tabby with Codex, Claude Code, OpenAI-compatible providers, DeepSeek, GLM, Kimi, and Alibaba Cloud Coding Plan support",
5
5
  "repository": {
6
6
  "type": "git",
@@ -42,7 +42,9 @@
42
42
  "install:tabby": "node scripts/install-local.mjs",
43
43
  "pi:build": "node scripts/build-pi.mjs",
44
44
  "test:package": "node scripts/check-package-install.mjs",
45
- "pretest": "npm run pi:build"
45
+ "pretest": "npm run pi:build",
46
+ "pi:catalog": "node scripts/generate-pi-catalog.mjs",
47
+ "pi:catalog:check": "node scripts/generate-pi-catalog.mjs --check"
46
48
  },
47
49
  "files": [
48
50
  "dist",