@standardagents/code 0.13.11 → 0.14.0-issue.108.a702d6-darwin-arm64

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/bin/standard ADDED
Binary file
package/bin/standardd ADDED
Binary file
package/bin/tmux ADDED
Binary file
@@ -0,0 +1,119 @@
1
+ libevent.txt
2
+ ============
3
+ Libevent is available for use under the following license, commonly known
4
+ as the 3-clause (or "modified") BSD license:
5
+
6
+ ==============================
7
+ Copyright (c) 2000-2007 Niels Provos <provos@citi.umich.edu>
8
+ Copyright (c) 2007-2012 Niels Provos and Nick Mathewson
9
+
10
+ Redistribution and use in source and binary forms, with or without
11
+ modification, are permitted provided that the following conditions
12
+ are met:
13
+ 1. Redistributions of source code must retain the above copyright
14
+ notice, this list of conditions and the following disclaimer.
15
+ 2. Redistributions in binary form must reproduce the above copyright
16
+ notice, this list of conditions and the following disclaimer in the
17
+ documentation and/or other materials provided with the distribution.
18
+ 3. The name of the author may not be used to endorse or promote products
19
+ derived from this software without specific prior written permission.
20
+
21
+ THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
22
+ IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
23
+ OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
24
+ IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
25
+ INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
26
+ NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
27
+ DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
28
+ THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
29
+ (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
30
+ THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
31
+ ==============================
32
+
33
+ Portions of Libevent are based on works by others, also made available by
34
+ them under the three-clause BSD license above. The copyright notices are
35
+ available in the corresponding source files; the license is as above. Here's
36
+ a list:
37
+
38
+ log.c:
39
+ Copyright (c) 2000 Dug Song <dugsong@monkey.org>
40
+ Copyright (c) 1993 The Regents of the University of California.
41
+
42
+ strlcpy.c:
43
+ Copyright (c) 1998 Todd C. Miller <Todd.Miller@courtesan.com>
44
+
45
+ win32select.c:
46
+ Copyright (c) 2003 Michael A. Davis <mike@datanerds.net>
47
+
48
+ evport.c:
49
+ Copyright (c) 2007 Sun Microsystems
50
+
51
+ ht-internal.h:
52
+ Copyright (c) 2002 Christopher Clark
53
+
54
+ minheap-internal.h:
55
+ Copyright (c) 2006 Maxim Yegorushkin <maxim.yegorushkin@gmail.com>
56
+
57
+ ==============================
58
+
59
+ The arc4module is available under the following, sometimes called the
60
+ "OpenBSD" license:
61
+
62
+ Copyright (c) 1996, David Mazieres <dm@uun.org>
63
+ Copyright (c) 2008, Damien Miller <djm@openbsd.org>
64
+
65
+ Permission to use, copy, modify, and distribute this software for any
66
+ purpose with or without fee is hereby granted, provided that the above
67
+ copyright notice and this permission notice appear in all copies.
68
+
69
+ THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
70
+ WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
71
+ MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
72
+ ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
73
+ WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
74
+ ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
75
+ OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
76
+
77
+ ==============================
78
+
79
+ The Windows timer code is based on code from libutp, which is
80
+ distributed under this license, sometimes called the "MIT" license.
81
+
82
+
83
+ Copyright (c) 2010 BitTorrent, Inc.
84
+
85
+ Permission is hereby granted, free of charge, to any person obtaining a copy
86
+ of this software and associated documentation files (the "Software"), to deal
87
+ in the Software without restriction, including without limitation the rights
88
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
89
+ copies of the Software, and to permit persons to whom the Software is
90
+ furnished to do so, subject to the following conditions:
91
+
92
+ The above copyright notice and this permission notice shall be included in
93
+ all copies or substantial portions of the Software.
94
+
95
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
96
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
97
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
98
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
99
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
100
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
101
+ THE SOFTWARE.
102
+
103
+
104
+ tmux.txt
105
+ ========
106
+ Copyright (c) Various Authors
107
+
108
+ Permission to use, copy, modify, and distribute this software for any
109
+ purpose with or without fee is hereby granted, provided that the above
110
+ copyright notice and this permission notice appear in all copies.
111
+
112
+ THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
113
+ WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
114
+ MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
115
+ ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
116
+ WHATSOEVER RESULTING FROM LOSS OF MIND, USE, DATA OR PROFITS, WHETHER
117
+ IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING
118
+ OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
119
+
package/manifest.json ADDED
@@ -0,0 +1 @@
1
+ {"schema":2,"format":"standard-npm-native-target-v2","repository":"standardagents/code-rs","commit":"a702d6e8c8d98ba117bc6059f200d7c91ba19ad6","version":"0.14.0-issue.108.a702d6","target":"aarch64-apple-darwin","runtime":{"tmuxVersion":"3.7","tmuxSha256":"ae7f4750005959947b562417731f1cb07cd7e674eb8f266069564107ea2a4cbb"},"signing":{"algorithm":"ed25519","keyId":"team-2026-1","platformCodeSignature":"apple-developer-id","notarization":{"status":"Accepted","submissionId":"7f5deebb-83e3-4dd7-936b-1127808e8623"}},"files":[{"path":"bin/standard","size":11604720,"sha256":"edf1fd5c8f62a04c21921cd6bef7c75b402f06ab5b44820218e6dc0676cdc302"},{"path":"bin/standardd","size":13625104,"sha256":"d19d934a19f8e829643078b103cf6ca85e9e0bd0d5ac707594f63b2da7ffa1f8"},{"path":"bin/tmux","size":1229696,"sha256":"ae7f4750005959947b562417731f1cb07cd7e674eb8f266069564107ea2a4cbb"},{"path":"licenses/THIRD-PARTY.txt","size":5306,"sha256":"8a03d349b280b03332f6ec1093d868ad77d29a4871f3b4a6c61471da6f53da44"}]}
package/manifest.sig ADDED
@@ -0,0 +1 @@
1
+ lw16EuIg3hTJeMq1t/MJG2J8WQvnj7nRBIo3zoOtXxSmqmE8yawC7wSCQseFTGStJzNcbFM2+ad14LFB3c/GAA==
package/package.json CHANGED
@@ -1,49 +1,26 @@
1
1
  {
2
2
  "name": "@standardagents/code",
3
- "version": "0.13.11",
4
- "description": "Standard Code a terminal coding agent whose LLM loop runs on a Standard Agents instance while its tools execute on your machine via this CLI.",
5
- "type": "module",
6
- "license": "UNLICENSED",
7
- "packageManager": "pnpm@11.9.0",
3
+ "version": "0.14.0-issue.108.a702d6-darwin-arm64",
4
+ "description": "Standard native binaries for darwin-arm64.",
8
5
  "repository": {
9
6
  "type": "git",
10
- "url": "git+https://github.com/standardagents/code.git"
7
+ "url": "git+https://github.com/standardagents/code-rs.git"
11
8
  },
9
+ "license": "UNLICENSED",
10
+ "os": [
11
+ "darwin"
12
+ ],
13
+ "cpu": [
14
+ "arm64"
15
+ ],
16
+ "files": [
17
+ "bin",
18
+ "licenses",
19
+ "manifest.json",
20
+ "manifest.sig"
21
+ ],
12
22
  "publishConfig": {
13
23
  "access": "public",
14
24
  "registry": "https://registry.npmjs.org/"
15
- },
16
- "bin": {
17
- "standardcode": "dist/index.js"
18
- },
19
- "files": [
20
- "dist"
21
- ],
22
- "scripts": {
23
- "start": "tsx src/index.ts",
24
- "code": "tsx src/index.ts",
25
- "tui:rust": "pnpm --filter @standardagents/code-network build && cargo run -p standardcode-tui",
26
- "build": "pnpm --filter @standardagents/code-network build && tsup",
27
- "release": "node scripts/release.mjs",
28
- "release:next": "node scripts/release.mjs --tag=next",
29
- "release:dev": "node scripts/release.mjs --tag=dev",
30
- "markdown:sync": "node scripts/sync-progressive-markdown-runtime.mjs",
31
- "markdown:check": "node scripts/sync-progressive-markdown-runtime.mjs --check",
32
- "activity:sync": "node scripts/sync-tool-activity-runtime.mjs",
33
- "activity:check": "node scripts/sync-tool-activity-runtime.mjs --check",
34
- "version:check": "node scripts/check-version-lockstep.mjs",
35
- "typecheck": "tsc --noEmit",
36
- "test": "pnpm version:check && pnpm typecheck && node scripts/run-tests.mjs && cargo test --workspace",
37
- "check:rust": "cargo fmt --all --check && cargo clippy --workspace --all-targets -- -D warnings"
38
- },
39
- "dependencies": {
40
- "@standardagents/code-network": "0.13.11"
41
- },
42
- "devDependencies": {
43
- "@clack/prompts": "^1.6.0",
44
- "@types/node": "^22.10.0",
45
- "tsup": "^8.5.1",
46
- "tsx": "^4.20.6",
47
- "typescript": "^5.9.3"
48
25
  }
49
26
  }
package/README.md DELETED
@@ -1,417 +0,0 @@
1
- <div align="center">
2
-
3
- ```
4
- █████████████
5
- ███ ██
6
- ██ █
7
- ████ ████████ ██
8
- ███ ████████ ███
9
- ██ ████████ ████
10
- █ ██
11
- ██ ███
12
- █████████████
13
- ```
14
-
15
- # Standard Code
16
-
17
- **A best-in-class terminal coding agent.**
18
-
19
- The LLM loop runs remotely on a [Standard Agents](https://github.com/standardagents) instance;
20
- every filesystem and shell tool executes on your own machine, through that machine's Standard
21
- Code **daemon** — so the agent works in *your* environment, against *your* code, with *your*
22
- permissions. The CLI is the terminal you watch and steer it from, and it never executes tools
23
- itself: a session survives closing the terminal, and any client can attach to it.
24
-
25
- ```
26
- ┌─────────────────────────┐ bridge (WebSocket) ┌──────────────────────┐
27
- │ Standard Agents instance│ ── tool_request ──────────────▶ │ Standard Code daemon │
28
- │ (the agent's LLM loop) │ ◀──────────── tool_response ── │ (your machine) │
29
- └─────────────────────────┘ └──────────────────────┘
30
- │ ▲
31
- │ conversation, steering, approvals │ same machine,
32
- ▼ │ or a VPS
33
- ┌─────────────────────────┐
34
- │ Standard Code CLI │ the terminal you watch and steer from
35
- └─────────────────────────┘
36
- ```
37
-
38
- </div>
39
-
40
- ---
41
-
42
- ## 🔒 Early Access
43
-
44
- Standard Code is in **early access**. The agent loop, tooling, and backend are evolving fast,
45
- and we're rolling it out gradually to keep the feedback loop tight.
46
-
47
- **Access is invite-only.** To run Standard Code you need:
48
-
49
- 1. A spot on the **early-access list** — request one at
50
- **[standardagents.ai/early-access](https://standardagents.ai/early-access)**.
51
- 2. A Standard Agents instance exposing the `standard_code_agent`
52
- (see [agentbuilder](https://github.com/standardagents/agentbuilder)).
53
-
54
- If you're already on the list, you'll have received an instance URL and an API token. Jump to
55
- [Quick start](#quick-start). If not, [join the waitlist](https://standardagents.ai/early-access) —
56
- we're letting new folks in every week.
57
-
58
- ---
59
-
60
- ## Why Standard Code
61
-
62
- - **Your machine, your rules.** Tools run on your own machines — read/write/edit files, list,
63
- grep, glob, bash, delete — never in some sandboxed cloud container. The agent edits the same
64
- files you do.
65
- - **The daemon is the executor.** Every machine that runs sessions installs one
66
- (`standardcode daemon install`); the CLI, web console, and macOS app all attach as clients.
67
- Work continues on that machine after you close the terminal, and a machine without a daemon
68
- still runs the full CLI as a watcher of sessions executing elsewhere.
69
- - **Permission-aware by design.** A single auto-accept level (1–5) controls what runs unattended;
70
- higher-risk calls prompt you first. Operations explicitly marked as requiring permission prompt
71
- regardless of their numeric risk unless you previously granted that exact tool. Accepting a risk
72
- tier raises the shared thread level so every client displays and enforces the same policy. A
73
- catastrophic-command guard blocks dangerous shell calls at *every* level.
74
- - **Real project containment.** File destinations and background-process working directories are
75
- checked through filesystem symlinks; any path that resolves outside the project always requires
76
- a fresh human approval.
77
- - **Durable, resumable sessions.** Long-running and permission-gated calls *park* and resume over
78
- HTTP — a slow approval or a dropped socket can't kill your turn. Resume the same session from
79
- any machine.
80
- - **Background processes that survive.** Dev servers, watchers, queue workers are tracked in the
81
- thread and keep running across reconnects and resumes.
82
- - **Idle attachments stay dormant.** Queue/draft snapshots refresh from events and lifecycle
83
- transitions, stream and idle execution-bridge heartbeats use Durable Object hibernation
84
- auto-responses on a 30-second quiet cadence (real traffic suppresses the keepalive), and
85
- transcript safety requests run only while the agent is active. The bridge switches to a
86
- 5-second observable liveness heartbeat only during a forwarded tool or approval, so
87
- leaving a terminal attached does not continuously wake an idle thread. Each running client owns
88
- one account user stream; a machine daemon opens a per-thread execution bridge only while
89
- forwarded work is active. Stream transitions update machine presence once. Remote filesystem
90
- responses arrive through account events and trigger one response read, with no response loop.
91
- - **Subagents & research built in.** Delegate focused subtasks to a coding subagent, or spin up a
92
- non-blocking web-research agent that returns source-backed findings.
93
- - **MCP, first-class.** The CLI is a Model Context Protocol host — connect local MCP servers
94
- (Playwright, databases, issue trackers, anything) and the agent can use them. Install new ones
95
- in natural language: *"install the playwright mcp server"* and it researches and wires them up.
96
- - **Stable progressive Markdown.** Streaming buffers are parsed into shared, source-offset-keyed
97
- blocks and inline runs. An open fence is a persistent code node and incomplete emphasis is a
98
- styled run, so later chunks extend existing UI state instead of replacing raw Markdown. The
99
- shared live-draft reducer appends monotonically across provider/reconnect message-ID aliases,
100
- and the durable answer uses the same document renderer for a geometry-preserving handoff.
101
-
102
- ---
103
-
104
- ## Quick start
105
-
106
- Standard Code has one exact runtime dependency on its version-matched
107
- `@standardagents/code-network` package. Both packages use Node built-ins and
108
- web-platform APIs without third-party runtime dependencies. For local
109
- development the CLI runs through `tsx`; published builds are bundled with
110
- `tsup`:
111
-
112
- ```bash
113
- pnpm install # installs dev dependencies
114
- pnpm code <dir> # run against a project directory (defaults to cwd)
115
- pnpm code --endpoint http://localhost:5178 <dir>
116
- ```
117
-
118
- The parallel Rust TUI preview signs in, loads the shared machine → project →
119
- session projection, and attaches through the same version-matched network
120
- core. It owns the terminal's alternate screen and does not open native HTTP or
121
- WebSocket connections. Terminals at least 100 columns wide keep the session
122
- tree available as a full-height left column; Tab or its clickable divider
123
- collapses it to a one-column rail with a vertically stacked `Tab` hint. A
124
- one-column gutter separates that rail from the conversation while the
125
- transcript, composer, and chat controls expand into the reclaimed space.
126
- Narrower terminals show the session tree full-screen when focused and omit the
127
- sidebar collapse control. An authenticated launch with no attached session uses
128
- that same shell. A normal launch registers or refreshes the current directory
129
- as a project and highlights its row without creating a thread. `--browse`
130
- opens the account-wide picker without a project target. The sidebar remains
131
- available while the right column presents a session-selection empty state.
132
- Machine and project headings sit on the same left edge, sessions use one
133
- shallow indentation step, and a blank row separates machines. A one-cell `⣿`
134
- texture marks machine headings and continues through their divider. Machine
135
- rows have no disclosure glyph; a collapsed machine instead shows its known
136
- thread count, such as `(13)`; offline machines show that retained count too.
137
- Collapsed projects likewise append their known thread count.
138
- Each machine's green/red presence dot precedes its name. The leading texture
139
- cell takes the branch accent only while that machine is active, hovered, or
140
- keyboard-highlighted; inactive machine texture remains structural gray.
141
- Machines receive stable colors from DMUX's eight-accent palette, so color
142
- belongs to a branch rather than to global selection. Machine color is limited
143
- to its texture/divider while the active machine name stays white. Project
144
- headings and dividers remain structural gray at every state. Unrelated
145
- hierarchy recedes to dark gray.
146
- The attached project and thread use typography without persistent row fills;
147
- the thread title inherits its machine accent. Hover or keyboard navigation uses
148
- the same brighter row background for machines, projects, and threads;
149
- navigated threads also add a `›` marker. Every thread has a status cell: hollow gray is idle, solid
150
- blue is unread, and a green animated texture is working. Unread state uses the
151
- shared core's account-scoped, message-recency watermark; opening a thread
152
- advances that shared state, and background activity timestamps never create a
153
- false unread dot.
154
- Click a heading or select its name and press Enter to collapse it. Right moves
155
- keyboard focus to the heading's complete `[+]` button; Enter activates it,
156
- Left returns to the name, and Right again returns to an attached conversation.
157
- The button is hidden until its row is hovered or keyboard-highlighted; while
158
- hidden, the heading divider fills those final three cells instead of reserving
159
- an empty control gap.
160
- The project `[+]` opens a prospective session composer. The machine `[+]`
161
- opens its structure-only directory picker and registers the chosen project
162
- before opening that composer. The canonical thread is created when its first
163
- message is submitted, so closing an untouched composer leaves no empty thread.
164
- The composer takes keyboard focus and explains that the first message creates
165
- the session.
166
- An offline machine has no disclosure/collapse action and hides its retained
167
- project/session branch. Its machine row keeps the last known thread count and
168
- can still receive keyboard or mouse highlight, but its foreground remains gray
169
- and activation does nothing. Creation controls are absent while that machine is
170
- offline, and presence is checked again before a core request is sent.
171
- Those actions use the shared core's `project.open`, `session.start`, and
172
- `machines.fsBrowse` operations. The Rust face receives filesystem data and
173
- canonical session metadata from the core.
174
- Press Tab to reveal and focus sessions, use ↑/↓ or j/k and Enter to activate,
175
- and press Esc or Tab to return to the composer. Clicking anywhere in the
176
- expanded sidebar also transfers keyboard focus there, beginning on the clicked
177
- row when there is one. Left from an empty composer
178
- also reveals and focuses the sidebar; Left retains normal cursor movement when
179
- the composer contains text. Activating a prospective or existing chat returns
180
- keyboard focus to the conversation. Switching saves the current shared draft
181
- before detaching, and never stops the session's remote work. While the selected
182
- conversation loads, the full-height session tree stays mounted and only the
183
- right chat column enters its loading state. Session rows also switch on one
184
- click. Passive mouse motion gives clickable session rows a high-contrast
185
- surface, highlights the sidebar toggle rail, Markdown
186
- links, and the jump-to-latest pill, and asks supporting terminals such as
187
- Ghostty for a pointer cursor. Redraws are coalesced until the semantic hover
188
- target really changes. The transcript owns pane-local click-drag selection, so it copies
189
- semantic Markdown text without Shift and never sweeps through the sidebar.
190
- White is reserved for user text and high-value accents. Assistant prose and
191
- tool, system, reasoning, and structural rows use sampled cool-gray tiers;
192
- semantic states and Markdown keep muted accent colors. Live thought and answer blocks grow from a stable prefix,
193
- so streamed chunks extend visible text without deleting and reflowing its
194
- beginning. Running subagents retain a bounded list of their reads, searches,
195
- edits, and other tool actions beneath the current activity phrase.
196
- Settled reads and searches roll up under `Explored` while preserving every
197
- action. Successful commands use one compact highlighted row. Failures retain
198
- their complete output as a quiet gray block beneath the highlighted command,
199
- and prose-like tool results share the transcript's word wrapper. Known
200
- arguments and results receive muted semantic syntax colors. Consecutive edits
201
- roll up under `Edited N files`; their complete red and green hunks fill the
202
- available conversation width.
203
- Thinking appears in an expandable block with an animated Braille texture while
204
- the trace is active. Active traces start collapsed, and completed traces retain
205
- a one-line disclosure. Click any thinking row to toggle its trace, or press Ctrl+T
206
- to toggle the newest trace.
207
- Releasing the button clears the highlight and shows `Copied text` in the status
208
- row. Clicking anywhere in the active conversation column returns keyboard
209
- focus to its composer without disrupting drag selection. Prose wraps at word
210
- boundaries; long unbroken tokens and code still
211
- hard-wrap to the pane. The complete loaded transcript remains scrollable with
212
- the mouse wheel or Page Up/Page Down. Ctrl+Home jumps to the beginning and
213
- Ctrl+End resumes bottom-follow; output that arrives while scrolled up leaves
214
- the viewport anchored and shows a one-click “Jump to latest” pill at the bottom
215
- of the conversation. The pill calls out new output when it arrives. Wheel bursts
216
- accumulate between frames, preserving responsive trackpad motion instead of dropping input.
217
- While a turn runs, an animated amber/coral/violet Braille status row stays
218
- directly above the composer, after the optional `Session todos` card.
219
- The composer and submitted user messages share one quiet filled rectangular
220
- surface with a chevron gutter. One empty surface row sits above the editable
221
- rows and one below, so the empty composer is three terminal rows; it grows
222
- from one to eight content rows, wraps prose on word boundaries,
223
- preserves hard newlines from Shift+Enter and multiline paste, and then scrolls
224
- internally without displacing more of the transcript. Short conversations use
225
- natural document flow: the composer and telemetry follow the final transcript
226
- row, leaving unused space below. Once the transcript consumes the available
227
- viewport, the composer stays pinned at the bottom and the transcript scrolls
228
- above it. The mouse
229
- wheel follows the pane under the pointer, so a capped composer scrolls without
230
- moving the conversation; the next edit resumes caret-follow. Pastes over 1,000
231
- characters render as an atomic cyan `[Pasted Content N chars]` element while
232
- their exact text remains in the shared draft and submitted message. Backspace
233
- or Delete at that element removes the complete paste. Enter sends or queues,
234
- while Ctrl+Enter steers. Up/Down moves through visual editor
235
- rows before recalling the core-backed per-thread sent history at the top or
236
- bottom edge.
237
- Structured session todos appear in a collapsible card above the composer. One
238
- blank row separates the neutral teal-gray card from the transcript. Todo
239
- descriptions and steps wrap to show their complete content. Escape promotes the
240
- oldest queued message through the shared core. During active work with an empty
241
- queue, Escape stops execution and releases the composer for a new message.
242
- An offline runner does not make its cloud conversation disappear: the session
243
- still opens for review, but the composer pauses instead of letting new work
244
- silently wait for a missing executor. There is no separate offline banner; the
245
- composer becomes a hollow, unfilled surface carrying the state inline. If work
246
- is already waiting, it says `Waiting for <machine> — Esc stops`. Pushed machine-presence events unlock
247
- the composer and restore the retained sidebar branch as soon as the daemon
248
- reconnects; there is no presence poll or session relist.
249
- The line beneath the composer is session telemetry rather than a persistent
250
- keyboard cheat sheet: it shows the attached thread's agent, runner machine,
251
- current working directory, running background-process count, and
252
- compaction-scaled context usage. The muted path gets priority over the literal
253
- `context` label. Full agent names stay visible at comfortable widths; only a
254
- narrow footer abbreviates them (`Unlimited One` → `U1`, `Sama One` → `S1`)
255
- before squeezing the deepest complete path breadcrumbs further.
256
- The row ends with the old terminal face's five colored permission dots, so the
257
- current effective auto-accept ceiling remains visible without adding another
258
- row. Accepted risk grants raise the dots immediately and reconcile from the
259
- persisted approval state. Approval requests show the tool summary, stated
260
- reason, execution machine, five-dot risk level, and fully labeled decisions in
261
- a bordered card. These
262
- values come from the shared roster, session tree,
263
- approvals, process registry, and context projections in the network core.
264
- Headings, emphasis, links, lists, tables, quotes, and fenced code use
265
- the same progressive parser contract as the TypeScript UI. PNG attachments use
266
- Kitty Unicode placeholders in verified Kitty/Ghostty/WezTerm environments,
267
- including configured tmux; other terminals keep the same layout and show a
268
- text fallback:
269
-
270
- ```bash
271
- pnpm tui:rust
272
- # Open the account-wide project picker:
273
- pnpm tui:rust -- --browse
274
- # Optional direct-attach fast path:
275
- pnpm tui:rust -- --thread <thread-id>
276
- ```
277
-
278
- This preview is additive; the TypeScript CLI remains the normal entry point
279
- while the Rust face is brought to feature parity.
280
-
281
- Installed from npm:
282
-
283
- ```bash
284
- npx @standardagents/code@latest <dir>
285
- # or
286
- npm install -g @standardagents/code
287
- standardcode <dir>
288
- standardcode --endpoint https://your-instance.example.com <dir>
289
- standardcode -e -- <dir> # prompt for the endpoint for this run
290
- ```
291
-
292
- On first run it connects to the hosted Standard Code instance
293
- (`https://api.standardcode.ai`) and walks you through a one-time browser sign-in — press
294
- Enter, approve in the browser, and your key is stored in `~/.standardagents/credentials`.
295
- ### Choosing an agent
296
-
297
- Session start opens with an agent picker: **Frontier One** (coming soon),
298
- **Unlimited One** (the default — adaptive high/low routing), **Sama One**
299
- (OpenAI-only, powered by your own ChatGPT authorization), and **Dario**
300
- (unavailable). Skip the menu with `--agent unlimited` or `--agent sama`.
301
-
302
- Sama One is BYOK: the first time you pick it, the CLI opens
303
- `https://standardcode.ai/app` where you connect your ChatGPT account once.
304
- That connection installs the authorization in your account's secret
305
- environment on the instance — shared by the CLI, web console, and macOS app —
306
- and the CLI itself never sees or stores the OpenAI key. Connection changes are
307
- pushed over the existing account WebSocket to every open client; the clients
308
- do not poll account metadata. Sama One sessions are not limited by the
309
- simultaneous-thread lease.
310
-
311
- You only do this once per machine. Session start then asks **where the session should run** —
312
- this machine or any machine whose daemon is online — and offers to **resume** a session for that
313
- project or **start a new one**.
314
-
315
- The first time you choose this machine, the CLI offers to install its daemon in one keypress
316
- (the same flow as `standardcode daemon install`), because that daemon is what runs sessions
317
- here. Declining leaves local execution unavailable; remote machines and watching stay available,
318
- and the command sets it up any time.
319
-
320
- Manage the local daemon from any shell:
321
-
322
- ```bash
323
- standardcode daemon status
324
- standardcode daemon restart
325
- standardcode daemon update
326
- standardcode daemon add-project /absolute/path/to/project
327
- standardcode daemon uninstall
328
- ```
329
-
330
- `restart` immediately reloads the installed launchd or systemd service. `update` lets active tool
331
- calls finish, installs the latest Standard Code package, and restarts the daemon.
332
-
333
- Use `--endpoint [url]` or `-e [url]` to point a single CLI run at a different Standard Agents
334
- instance (local dev, self-hosted). If you omit the URL, the CLI prompts for it. Tokens are
335
- remembered per endpoint, but this override does not change the saved default endpoint.
336
- Endpoints without a scheme default to `https://`; using plaintext local development requires an
337
- explicit URL such as `http://localhost:5178`.
338
-
339
- For HTTPS on a loopback, private, `.local`, or `.localhost` endpoint, the CLI can relax certificate
340
- verification for its own instance connections. That process-local setting is stripped from every
341
- browser, shell, background process, package-manager, git, clipboard, and ripgrep child so local
342
- development never disables TLS verification in unrelated commands.
343
-
344
- ### Requirements
345
-
346
- - **Node 22+**
347
- - A Standard Agents instance exposing the `standard_code_agent`
348
- (see the [agentbuilder](https://github.com/standardagents/agentbuilder) repo). For local
349
- development, run that backend on `:5178` and point this CLI at `http://localhost:5178`.
350
-
351
- ---
352
-
353
- ## Features
354
-
355
- - **Forwarded tools** executed by the session's machine daemon: read/write/edit files, list,
356
- grep, glob, bash, delete.
357
- - **Permissions**: a shared auto-accept level 1–5 (shift-tab cycles it); accepting a risk tier
358
- raises the stored thread level across clients; server-marked permission requests cannot be
359
- downgraded by a model-supplied risk. A catastrophic-command guard blocks dangerous shell commands
360
- at every level.
361
- - **Durable, resumable** long-running/permission-gated tool calls (park & resume over HTTP).
362
- - **Background processes** tracked in the thread (survive resume from any machine).
363
- - **Subagent delegation** and non-blocking web research.
364
- - **MCP (Model Context Protocol)**: connect MCP servers on your machine — the daemon is the MCP
365
- host, negotiating JSON-RPC over stdio. Manage the machine's server list with `/mcp` (the daemon
366
- connects the enabled ones when it next starts a session there); install new ones in natural
367
- language ("install the playwright mcp server") and the agent researches + installs them.
368
-
369
- ---
370
-
371
- ## Tests
372
-
373
- ```bash
374
- pnpm test # TypeScript checks/tests plus Rust unit and PTY tests
375
- pnpm check:rust # rustfmt and clippy with warnings denied
376
- ```
377
-
378
- `scripts/run-tests.mjs` owns the explicit no-backend test manifest, prints each
379
- file as it runs, and fails when a new `scripts/*-test.ts` file is not classified.
380
- Run an individual file with `pnpm exec tsx scripts/<name>-test.ts`.
381
-
382
- ---
383
-
384
- ## Architecture & contributing
385
-
386
- Standard Code is the **client** half of a two-part system. The agent loop and tool definitions
387
- live on the Standard Agents instance ([agentbuilder](https://github.com/standardagents/agentbuilder));
388
- this CLI connects to a thread and renders, steers, and approves the session, while the machine
389
- daemon (`src/daemon.ts`) executes the agent's forwarded tool calls.
390
-
391
- See **[`AGENTS.md`](./AGENTS.md)** for the full source map, bridge protocol, MCP internals,
392
- test layout, and contributor conventions.
393
-
394
- - Two version-locked packages: `@standardagents/code` and its shared
395
- `@standardagents/code-network` client. Both use Node built-ins and
396
- web-platform APIs without third-party runtime packages.
397
- - `src/progressive-markdown.ts` is the canonical structured streaming parser used by every face.
398
- The Node face-core sends its versioned documents to Rust, which handles
399
- terminal layout and paint. Web receives an exact source copy, and macOS runs
400
- the generated JavaScriptCore bundle. Shared vectors cover parser output and
401
- Rust transport-schema compatibility.
402
- Run `pnpm markdown:sync` after changing the authored TypeScript parser and
403
- `pnpm markdown:check` in CI.
404
- - The hosted instance authors the session-state reducer published through
405
- `@standardagents/code-network`. It owns live-draft accumulation and busy/tool/message
406
- reconciliation; a changed chunk ID is an alias, never permission to erase text.
407
- - Commit messages use Conventional Commits, scope `cli` (e.g. `feat(cli): …`).
408
-
409
- ---
410
-
411
- <div align="center">
412
-
413
- **[Join the early-access list →](https://standardagents.ai/early-access)**
414
-
415
- Built by [Standard Agents](https://github.com/standardagents).
416
-
417
- </div>