tabby-ai-tools 0.7.0 → 0.8.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +15 -5
- package/README.zh-CN.md +15 -5
- package/VALIDATION.md +49 -0
- package/dist/index.js +2 -1
- package/dist/index.js.LICENSE.txt +21 -0
- package/dist/pi/sidecar.mjs +1239 -1126
- package/docs/assets/overview.png +0 -0
- package/docs/assets/overview.svg +46 -24
- package/docs/attachments.md +33 -0
- package/docs/claude-code.md +2 -2
- package/docs/development.md +30 -0
- package/docs/guide.md +35 -5
- package/docs/instructions-sessions.md +49 -0
- package/docs/pi.md +67 -0
- package/docs/releases/0.7.1.md +11 -0
- package/docs/releases/0.8.0.md +20 -0
- package/docs/releases/instructions-sessions.md +7 -0
- package/docs/releases/pi-provider-configuration.md +9 -0
- package/docs/scheduled-tasks.md +2 -0
- package/package.json +4 -2
- package/skills/tabby/SKILL.md +14 -0
- package/skills/tabby/references/operations.md +20 -0
package/docs/assets/overview.png
CHANGED
|
Binary file
|
package/docs/assets/overview.svg
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
<svg xmlns="http://www.w3.org/2000/svg" width="1800" height="
|
|
2
|
-
<title id="title">Tabby AI Tools v0.
|
|
3
|
-
<desc id="desc">Interface illustration, not a running screenshot. 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.
|
|
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.0 interface illustration — conditional interactive workflows, helper models, local login and API connections</title>
|
|
3
|
+
<desc id="desc">SSH file/image attachments with 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.0 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="
|
|
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">>_</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.
|
|
18
|
+
<text x="1544" y="64" font-size="16" font-weight="600" style="fill:#8ae6c2">v0.8.0 / SSH files</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 / CLI</text>
|
|
135
|
+
<text x="84" y="1102" font-size="12" style="fill:#a7b8cb">Local login / newest CLI</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
138
|
<text x="334" y="1102" font-size="12" style="fill:#a7b8cb">Local login / CLI</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
|
|
140
|
-
<text x="584" y="1102" font-size="12" style="fill:#a7b8cb">
|
|
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">
|
|
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
|
|
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">
|
|
149
|
-
<text x="1160" y="1015" font-size="16">
|
|
150
|
-
<text x="1315" y="1015" font-size="16">
|
|
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">
|
|
153
|
-
<text x="1146" y="1052" font-size="15" style="fill:#a7b8cb">
|
|
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">
|
|
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">
|
|
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
|
|
161
|
-
<text x="72" y="1198" font-size="14" style="fill:#a7b8cb">Custom
|
|
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
|
|
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
|
|
175
|
-
<text x="72" y="1342" font-size="16" style="fill:#8ae6c2"
|
|
176
|
-
<
|
|
177
|
-
<text x="
|
|
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">Files and clipboard images / example transfer</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 · Upload → staging-app · SFTP</text>
|
|
192
|
+
<text x="164" y="1676" font-size="16" style="fill:#a7b8cb">Private target directory · plugin streams all chunks · no model relay</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 · Cancel / Copy remote 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,33 @@
|
|
|
1
|
+
# Files, clipboard images and SSH transfers
|
|
2
|
+
|
|
3
|
+
Open **Attachments** below the AI Tools composer. Paste a screenshot, drag files into the composer, or use **Add files or paste a screenshot**. Choose the exact connected native SSH terminal and an existing absolute upload parent directory (default `/tmp` on POSIX servers), then click **Upload**. The plugin creates a unique private subdirectory and never overwrites an existing project file. To retrieve a regular remote file, enter its absolute path and choose **Download to attachment cache**.
|
|
4
|
+
|
|
5
|
+
Use **Save locally** on a cached attachment to choose a local destination through the system save dialog.
|
|
6
|
+
|
|
7
|
+
The target tab shows Tabby's native progress bar. Progress comes from transferred file bytes; integrity verification finishes before the operation reports success. The attachment panel retains status, byte count, remote path, cancellation and **Copy remote path**. Collapsing the sidebar does not stop a transfer. If another native task takes over the tab's shared progress indicator, this plugin yields that indicator and retains progress in the attachment panel.
|
|
8
|
+
|
|
9
|
+
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.
|
|
10
|
+
|
|
11
|
+
## One transfer, no model chunk relay
|
|
12
|
+
|
|
13
|
+
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.
|
|
14
|
+
|
|
15
|
+
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.
|
|
16
|
+
|
|
17
|
+
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.
|
|
18
|
+
|
|
19
|
+
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.
|
|
20
|
+
|
|
21
|
+
## Remote Codex and other terminal Agents
|
|
22
|
+
|
|
23
|
+
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.
|
|
24
|
+
|
|
25
|
+
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.
|
|
26
|
+
|
|
27
|
+
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.
|
|
28
|
+
|
|
29
|
+
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.
|
|
30
|
+
|
|
31
|
+
## Validation scope
|
|
32
|
+
|
|
33
|
+
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.
|
package/docs/claude-code.md
CHANGED
|
@@ -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.
|
|
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.
|
|
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
|
|
package/docs/development.md
CHANGED
|
@@ -151,3 +151,33 @@ Stable GitHub Releases trigger `.github/workflows/publish.yml`. After exact-comm
|
|
|
151
151
|
## Conditional workflow runtime
|
|
152
152
|
|
|
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
|
+
|
|
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
|
+
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.
|
|
182
|
+
|
|
183
|
+
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.
|
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
|
|
17
|
-
- **Claude 订阅/Claude Code 本机模式**:本机安装官方 Claude Code
|
|
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
|
### 安装插件
|
|
@@ -286,11 +286,11 @@ Goal 通过证据检查和持续执行降低过早结束的概率,但无法数
|
|
|
286
286
|
|
|
287
287
|
## CLI 自动发现与启动排查
|
|
288
288
|
|
|
289
|
-
`codexAgent.executable` 留空或保持默认 `codex`
|
|
289
|
+
`codexAgent.executable` 留空或保持默认 `codex` 时,**Windows 会收集并比较已发现安装的实际 CLI 版本**:Tabby 进程 PATH 的所有匹配项、`CODEX_INSTALL_DIR`、`%LOCALAPPDATA%\Programs\OpenAI\Codex\bin\codex.exe`、`CODEX_HOME` 下的 standalone 入口、`%LOCALAPPDATA%\OpenAI\Codex\bin\<目录>\codex.exe`、用户 `.local\bin` 及 npm 常见目录和全局 prefix。不会命中第一个 PATH 旧版就停止。多个候选使用不消耗模型额度的 `--version` 查询,按语义版本选择较新者;稳定版优先于同版本预发布版,版本相同时保留发现顺序。哈希名及文件修改时间不作为版本新旧依据。单项查询限时 1.5 秒、输出最多 16 KiB,最多四项并发;失败或无法解析的候选不压过有有效版本号的候选。所有版本均未知时保留原发现顺序(桌面子目录内部以程序修改时间排序),此时不能保证最新。每次新连接重新扫描,不缓存版本结果;已有连接复用当前进程。Linux/macOS 仍先检查 PATH,再检查 `CODEX_INSTALL_DIR` 和下文的补充来源。
|
|
290
290
|
|
|
291
291
|
Linux/macOS 在默认命令模式下会异步启动 `$SHELL -ilc` 补全环境,即使桌面 PATH 已经包含 Codex,也会读取用户 Shell 中的 Codex 配置。未设置 SHELL 时,Linux 使用 `/bin/bash`,macOS 使用 `/bin/zsh`;支持 bash/zsh/sh/dash/ksh/fish。探测限时 3 秒,通过独立管道读取最多 64 KiB,忽略 Shell 启动输出。仅导入 PATH、CODEX_HOME / CODEX_SQLITE_HOME / CODEX_INSTALL_DIR、NVM_DIR、HOMEBREW_PREFIX、NPM_CONFIG_PREFIX / npm_config_prefix、代理、证书及 OPENAI_API_KEY / CODEX_API_KEY / CODEX_ACCESS_TOKEN;其中非 PATH 变量以父进程已有值(包括空值)为准,不导入 Shell 的 NODE_OPTIONS 等运行时钩子,也不把环境变量内容写入诊断。
|
|
292
292
|
|
|
293
|
-
默认 Codex 仍未找到时,按下表补充安装来源。POSIX 先恢复用户 Shell 环境,再检查 standalone、配置的 prefix、NVM 和常见系统目录;Windows
|
|
293
|
+
默认 Codex 仍未找到时,按下表补充安装来源。POSIX 先恢复用户 Shell 环境,再检查 standalone、配置的 prefix、NVM 和常见系统目录;Windows 已在上面的候选比较中检查独立安装、桌面安装和 npm 等目录。尚未找到时才查询包管理器 prefix,随后检查 macOS 桌面包,最后才扫描 IDE 扩展。Linux/macOS 已通过 PATH 选定的 Codex、各平台明确设置的文件路径或自定义命令不会被另一安装替换。
|
|
294
294
|
|
|
295
295
|
| 来源 | macOS / Linux | Windows |
|
|
296
296
|
| --- | --- | --- |
|
|
@@ -314,7 +314,15 @@ NVM 优先 current,其余按 Node 版本降序。IDE 同时支持 `.vscode-ins
|
|
|
314
314
|
|
|
315
315
|
服务关闭和重连会等待旧进程回收。Linux/macOS 为服务创建独立进程组,先发送 SIGTERM,等待最多 1 秒,再向仍存活的进程组发送 SIGKILL,并等待最多 2 秒确认服务管道关闭。Windows 使用由 SystemRoot / WINDIR 定位的绝对路径 `System32\taskkill.exe /t /f`,不依赖 PATH;执行和退出确认均有 2 秒上限。回收失败会给出诊断并阻止启动另一个服务,需要处理该错误并重启 Tabby 后重试。
|
|
316
316
|
|
|
317
|
-
|
|
317
|
+
Windows 桌面版升级可能更换或清理版本目录。要持续使用这套安装,在 **Codex CLI 可执行文件** 中填写稳定的父目录(用实际用户名替换 `用户名`):
|
|
318
|
+
|
|
319
|
+
```text
|
|
320
|
+
C:\Users\用户名\AppData\Local\OpenAI\Codex\bin
|
|
321
|
+
```
|
|
322
|
+
|
|
323
|
+
此目录配置每次新连接都扫描直属子目录,并比较 `codex.exe --version` 选择较新版本;仅限此目录,不比较 PATH 中的其他安装。默认留空同样会比较桌面安装与 PATH 版本,普通用户无需指定目录。无需在每次升级后手动填写哈希。若之前填写的是该桌面目录下的 `<目录>\codex.exe` 且文件已被移除,会在同一 `OpenAI\Codex\bin` 内恢复查找;若文件仍存在,保留显式固定版本。目录内没有可用程序时报错,不切换到另一安装。输入实际完整路径,不使用 `%LOCALAPPDATA%` 占位符。
|
|
324
|
+
|
|
325
|
+
显式配置的绝对路径、相对路径或 `~/` 路径优先(可带一对外层引号),会验证真实文件存在;除上述已移除的 Windows 桌面版本路径外,无效立即报错,**不会自动降级到另一安装**。自定义命令名(如 `my-codex`、`codex.cmd`)仅按 PATH / Windows PATHEXT 查找,保留命令名配置兼容性;未找到也不会改用桌面安装。Windows 支持原生 exe/com 和 cmd/bat 启动器,含空格、中文路径可用。原生程序使用绝对路径、参数数组和 `shell:false`;cmd/bat 由 cross-spawn 负责 cmd.exe 转义,stdin/stdout JSONL 及 stderr 均保留为管道。只填写文件路径或命令名,不附加参数。
|
|
318
326
|
|
|
319
327
|
子进程环境会移除所有大小写形式的 `CODEX_INTERNAL_ORIGINATOR_OVERRIDE`,初始化始终使用插件自己的 `clientInfo.name = tabby_codex_agent`,父进程环境不变。定位失败会给出 PATH 检查情况、Windows 安装扫描路径或 LOCALAPPDATA 缺失、Linux/macOS 的 Shell 探测结果及补充安装目录、候选拒绝原因,以及 **Settings → AI Tools → Codex CLI 可执行文件(`codexAgent.executable`)** 设置入口。
|
|
320
328
|
|
|
@@ -330,3 +338,25 @@ NVM 优先 current,其余按 Node 版本降序。IDE 同时支持 `.vscode-ins
|
|
|
330
338
|
空闲时输入 `/compact` 手动压缩。内置 API 保留原始历史,按完整工具批次投影请求;Pi 保留自己的 JSONL 原始条目和压缩边界。自动压缩默认关闭,摘要本身消耗额度并计入 Goal 预算。Pi 的重试倒计时使用 SDK 结构化事件,取消会结束独立进程,不重放整段任务。中断后先读取真实终端再继续,未知动作不会自动重放。
|
|
331
339
|
|
|
332
340
|
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 开始提供。
|
|
341
|
+
|
|
342
|
+
## Pi 原生 API 连接与草稿(v0.8.0)
|
|
343
|
+
|
|
344
|
+
新增 API 连接默认推荐 Pi SDK。选择 SDK 内置供应商并搜索 Gemini/OpenRouter 等 ID,离线浏览随 SDK 1.4.0 打包的模型目录,配置当前连接的 Key 或环境变量引用,再保存。目录存在不代表账号授权。自定义接口支持 Chat Completions、Responses、Anthropic Messages、Google Generative AI,需明确模型协议、上下文与最大输出能力;单次输出预算与模型能力分开。
|
|
345
|
+
|
|
346
|
+
连接编辑使用独立草稿,切换连接或供应商保留输入;保存、放弃、复制不会调用模型。无推理检查只验证本地配置、运行时与凭据存在,实际连接测试会调用模型并产生用量。保存不会热切换任务,空闲时在侧栏重新连接。旧 Pi 产品预设继续兼容。OAuth/云身份与高级导入导出仍待实现,见 [Pi 说明](pi.md#unreleased-native-providers-and-connection-drafts-p0--p1)。
|
|
347
|
+
|
|
348
|
+
### 自定义 AGENTS.md 与独立 CLI 会话
|
|
349
|
+
|
|
350
|
+
每个连接下方的 **Instructions and sessions/指令与会话** 支持 AI Tools 全局默认与连接级覆盖。可编辑正文、绑定本地 AGENTS.md 文件、继承默认或关闭自定义层;保存和放弃均显式操作。文件要求绝对路径、UTF-8、最多 32 KiB,可预览内容、来源、摘要和修改时间,不会覆盖源文件。新会话保存指令快照;原文件修改或丢失不影响已有会话恢复。使用 `/new` 应用新指令,文件不可读则阻止依赖它的新会话。内置工具说明与宿主权限检查仍生效,Pi 不因此启用自动发现;Codex/Claude 的原生项目规则另由引擎管理。
|
|
351
|
+
|
|
352
|
+
未使用过的 Codex/Claude Code 默认采用 **Tabby 独立空间**,已有 CLI 会话引用保留 **系统空间(旧版兼容)**。独立空间隔离磁盘历史及索引,而不仅过滤列表;任务 cwd 保持不变。选择目标空间后生成登录命令,在本地终端完成官方登录,再检查该空间认证并保存。系统 CLI 已登录不代表目标空间已登录,插件不会复制凭据。Windows 命令使用 PowerShell,Linux/macOS 使用 POSIX shell。
|
|
353
|
+
|
|
354
|
+
空闲时点击侧栏重连以切换空间并交接当前对话,或用 `/new` 开始新对话。旧记录保留原处,失败时仍保留原侧栏会话;不会搬走全部系统历史。定时任务后续运行使用连接当前选定空间和新指令快照,活动任务保留启动时的配置。详细路径、认证边界与验证范围见 [指令与会话说明](instructions-sessions.md)。
|
|
355
|
+
|
|
356
|
+
## 文件、剪贴板图片与 SSH 传输(v0.8.0)
|
|
357
|
+
|
|
358
|
+
点击输入框下方“附件”,粘贴截图、拖入或选择文件,明确选择已连接的 SSH 终端,填写现有的绝对上传父目录后上传。也可输入远端文件绝对路径,下载到本地附件缓存。目标 tab 显示原生进度;侧栏可查看详情、取消及复制校验后的远端路径。收起侧栏不停止传输。
|
|
359
|
+
|
|
360
|
+
传输复用 SSH,优先 SFTP,再使用独立 exec 的二进制/base64,最后才在已确认空闲的 Shell 中使用 PTY base64。插件连续处理分块,不让 AI 逐段读写 base64。只读模式禁止传输。目标是外层 SSH 的机器与账户;容器、嵌套 SSH、切换用户及 Codex 沙箱需另行确认可见性。上传图片不代表 Codex 已附图或读取;本版仅提供复制远端路径,不自动按回车或向侧栏模型发送图片。
|
|
361
|
+
|
|
362
|
+
图片最多 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,11 @@
|
|
|
1
|
+
# 0.7.1 — Windows Codex CLI discovery
|
|
2
|
+
|
|
3
|
+
Windows default configuration (blank or `codex`) now compares actual CLI versions across all PATH matches, desktop/standalone installs, user `.local/bin`, and known/npm global-prefix locations. A stale PATH entry no longer wins over a newer discovered CLI. Each new connection rescans without calling a model.
|
|
4
|
+
|
|
5
|
+
Version probes use semantic version ordering, a 1.5-second timeout, a 16-KiB output limit and at most four concurrent children. Synchronous process-launch errors are isolated to the failing candidate. Failed or unknown probes cannot outrank a known version; if every version is unknown, discovery order is retained and freshness cannot be guaranteed. CLI selection does not change account model entitlements.
|
|
6
|
+
|
|
7
|
+
An explicit `OpenAI\Codex\bin` directory compares only its child installations. Removed version-specific desktop entrypoints recover within the same installation. Existing explicit files and custom command names remain pinned. Linux/macOS lookup priority is unchanged.
|
|
8
|
+
|
|
9
|
+
English/Chinese READMEs, discovery/development guidance, bundled Tabby skill knowledge and the overview SVG/PNG now describe this behavior. The robot animation and reduced-motion fallback are preserved. The overview is an illustration with example tasks and connections, not a desktop screenshot.
|
|
10
|
+
|
|
11
|
+
Local validation uses Node 22.19.0. Release validation includes skill bundle/check, typecheck, full tests, production build, a real npm archive and installation with no node on PATH and lifecycle scripts enabled. Linux/macOS/Windows CI must pass before publication. Real account/model calls and an interactive Windows desktop session are outside this validation scope.
|
|
@@ -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,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.
|
package/docs/scheduled-tasks.md
CHANGED
|
@@ -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.
|
|
3
|
+
"version": "0.8.0",
|
|
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",
|