The CLI's side of harness spec 3.11.0, on serve --stdio and on the link.
- acp/editor.ts: _lembas/complete (one HTTP request with the login the
agent holds, the window trimmed, a newer request closes the older one's
connection and that one is answered as cancelled), _lembas/edit (one
model request with no tools; the stream cleaned of a fence around the
whole answer and given the selection's ending; deltas; cancel),
_lembas/models, _lembas/editor/settings, the editor block of a prompt,
and ACP diff items.
- acp/files.ts: _lembas/fs/list, stat, read, write, mkdir, move, copy,
delete, search. A path is judged where it really is, symlinks followed
first; outside remote.roots, the CLI's own directories and protected
paths are refused, and so is a folder that holds them; read-only where
the device allows plan mode only. A write is checked against the hash
the client last saw, twice for an upload in parts, and put in place
whole. A delete goes to the system's trash or is refused until the
client says permanent.
- tool/buffers.ts: read, write, edit, multiedit and apply_patch take a
file's text from the client's editor and write through it where the
client offers ACP's fs methods; any failure there is the disk. The call
is judged before any of it, as before. An overwrite of text that changed
in the editor since it was read is refused.
- A tool's preview gives each file's text before and after beside the
unified diff; a client that said editor: true gets them as diff items on
the approval card and on every finished edit. The texts are kept only
for such a client.
- tool/show.ts: to a client that said media: true a file that is not text
is handed over by a handle (_lembas/show/read), good while the request
is open and for that file as it was; a table, an SVG and a notebook are
named. On stdio the request also says where the file is.
- The hardline, the modes and the rules are untouched; tool/replace.ts is
untouched.
Tests: tests/acp-editor.test.ts (19), tests/acp-files.test.ts (13), and
the conformance areas editor, device_files and show.
Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>