@standardagents/code 0.13.1 → 0.13.3

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 CHANGED
@@ -17,14 +17,22 @@
17
17
  **A best-in-class terminal coding agent.**
18
18
 
19
19
  The LLM loop runs remotely on a [Standard Agents](https://github.com/standardagents) instance;
20
- every filesystem and shell tool executes locally on your machine via this CLI — so the agent
21
- works in *your* environment, against *your* code, with *your* permissions.
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.
22
24
 
23
25
  ```
24
26
  ┌─────────────────────────┐ bridge (WebSocket) ┌──────────────────────┐
25
- │ Standard Agents instance│ ── tool_request ──────────────▶ │ Standard Code CLI
27
+ │ Standard Agents instance│ ── tool_request ──────────────▶ │ Standard Code daemon
26
28
  │ (the agent's LLM loop) │ ◀──────────── tool_response ── │ (your machine) │
27
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
+ └─────────────────────────┘
28
36
  ```
29
37
 
30
38
  </div>
@@ -51,8 +59,13 @@ we're letting new folks in every week.
51
59
 
52
60
  ## Why Standard Code
53
61
 
54
- - **Your machine, your rules.** Tools run on your host — read/write/edit files, list, grep, glob,
55
- bash, delete — never in some sandboxed cloud container. The agent edits the same files you do.
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.
56
69
  - **Permission-aware by design.** A single auto-accept level (1–5) controls what runs unattended;
57
70
  anything riskier prompts you first. A catastrophic-command guard blocks dangerous shell calls
58
71
  at *every* level, so you can't accidentally `rm -rf` your way into a bad day.
@@ -84,8 +97,11 @@ we're letting new folks in every week.
84
97
 
85
98
  ## Quick start
86
99
 
87
- Standard Code is a zero-dependency CLI (Node built-ins only). For local development it
88
- runs through `tsx`; published builds are bundled with `tsup`:
100
+ Standard Code has one exact runtime dependency on its version-matched
101
+ `@standardagents/code-network` package. Both packages use Node built-ins and
102
+ web-platform APIs without third-party runtime dependencies. For local
103
+ development the CLI runs through `tsx`; published builds are bundled with
104
+ `tsup`:
89
105
 
90
106
  ```bash
91
107
  pnpm install # installs dev dependencies
@@ -121,8 +137,14 @@ environment on the instance — shared by the CLI, web console, and macOS app
121
137
  and the CLI itself never sees or stores the OpenAI key. Sama One sessions are
122
138
  not limited by the simultaneous-thread lease.
123
139
 
124
- You only do this once per machine. It then offers to **resume** a session tagged for this
125
- project + machine, or **start a new one**.
140
+ You only do this once per machine. Session start then asks **where the session should run**
141
+ this machine or any machine whose daemon is online — and offers to **resume** a session for that
142
+ project or **start a new one**.
143
+
144
+ The first time you choose this machine, the CLI offers to install its daemon in one keypress
145
+ (the same flow as `standardcode daemon install`), because that daemon is what runs sessions
146
+ here. Declining leaves local execution unavailable; remote machines and watching stay available,
147
+ and the command sets it up any time.
126
148
 
127
149
  Use `--endpoint [url]` or `-e [url]` to point a single CLI run at a different Standard Agents
128
150
  instance (local dev, self-hosted). If you omit the URL, the CLI prompts for it. Tokens are
@@ -139,14 +161,16 @@ remembered per endpoint, but this override does not change the saved default end
139
161
 
140
162
  ## Features
141
163
 
142
- - **Forwarded tools** executed on your host: read/write/edit files, list, grep, glob, bash, delete.
164
+ - **Forwarded tools** executed by the session's machine daemon: read/write/edit files, list,
165
+ grep, glob, bash, delete.
143
166
  - **Permissions**: a single auto-accept level 1–5 (shift-tab cycles it); risky calls prompt;
144
167
  a catastrophic-command guard blocks dangerous shell commands at every level.
145
168
  - **Durable, resumable** long-running/permission-gated tool calls (park & resume over HTTP).
146
169
  - **Background processes** tracked in the thread (survive resume from any machine).
147
170
  - **Subagent delegation** and non-blocking web research.
148
- - **MCP (Model Context Protocol)**: connect local MCP servers — the CLI is the MCP host,
149
- negotiating JSON-RPC over stdio. Manage them with `/mcp`; install new ones in natural
171
+ - **MCP (Model Context Protocol)**: connect MCP servers on your machine — the daemon is the MCP
172
+ host, negotiating JSON-RPC over stdio. Manage the machine's server list with `/mcp` (the daemon
173
+ connects the enabled ones when it next starts a session there); install new ones in natural
150
174
  language ("install the playwright mcp server") and the agent researches + installs them.
151
175
 
152
176
  ---
@@ -163,13 +187,15 @@ pnpm test # typecheck + MCP client/protocol + install actuator (no bac
163
187
 
164
188
  Standard Code is the **client** half of a two-part system. The agent loop and tool definitions
165
189
  live on the Standard Agents instance ([agentbuilder](https://github.com/standardagents/agentbuilder));
166
- this CLI connects to a thread, executes the agent's forwarded tool calls on the host, and renders
167
- the session.
190
+ this CLI connects to a thread and renders, steers, and approves the session, while the machine
191
+ daemon (`src/daemon.ts`) executes the agent's forwarded tool calls.
168
192
 
169
193
  See **[`AGENTS.md`](./AGENTS.md)** for the full source map, bridge protocol, MCP internals,
170
194
  test layout, and contributor conventions.
171
195
 
172
- - Zero runtime dependencies — Node built-ins only, run via `tsx`. No build step for development.
196
+ - Two version-locked packages: `@standardagents/code` and its shared
197
+ `@standardagents/code-network` client. Both use Node built-ins and
198
+ web-platform APIs without third-party runtime packages.
173
199
  - `src/progressive-markdown.ts` is the canonical structured streaming parser shared with the web
174
200
  and native heads. Run `pnpm markdown:sync` after changing it and `pnpm markdown:check` in CI.
175
201
  - The hosted instance's generated `src/session-state.ts` owns live-draft accumulation as well as