feat(agent-consoles): remote file browser — read-only, MCP-backed (slice 3) - #68
Merged
Conversation
This was referenced Aug 17, 2026
…ice 3) Slice 3 of the agent-consoles ADR (#49): the remote file editor's read path (Part D). Adds a capability-gated, read-only directory browser + file viewer to the agent console. Per the merged Part D decision (#70), fs is an MCP files server the target agent exposes, reached Studio-brokered via the `oab` reverse-MCP tool — not a bespoke `fs/*` method set on `/acp`. The fs MCP server + the `oab` fs-relay are upstream (openab) and absent today, the same bucket as token streaming / `tool_call`. So this slice ships the browser UI + the source-agnostic read contract now; live fs traffic (MCP-backed read, then write/apply) lands in slice 4 with the server + relay. The earlier draft's bespoke `crates/acp-tunnel` `fs/*` client is dropped (the mechanism #70 rejected); the browser UI it fronted is source- agnostic and unchanged. - console/fileBrowser.ts: capability-gated browser + read-only CodeMirror viewer, mounted per open console, disposed on close/switch. Read-only. - render.ts: pure `fsListingHtml` (dirs-before-files, sizes, open-marking, `data-fs-*` nav hooks) + `fsUnavailableHtml`. - types/source/fixtures: the fs view-models; `fsCapability`/`fsList`/ `fsRead` (Mock = fixture FS; Tauri = honestly unsupported until slice 4). - index.html / styles.css: the Files region (listing + viewer split). Security (Part D): read-only — write/Apply is slice 4, gated at the fs server's tool level (agent-declared roots, `writable` default-off, no `/`-wide default). No orchestrator/kube creds; the `oab` relay stays management-only. Testing: console — `tsc --noEmit` clean · 84 vitest (incl. fs render cases) · `vite build` OK. No Rust change (the bespoke client is removed). 🤖 Generated with [Claude Code](https://claude.com/claude-code)
brettchien
force-pushed
the
feat/adr49-slice3-fs-read
branch
from
August 17, 2026 06:19
29724e0 to
0f15242
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Slice 3 of the agent-consoles ADR (#49) — the remote file editor's read path (Part D), on fresh
main(slices 1 #66 + 2 #67 + registry editor #69 + the Part D decision #70 all merged). Adds a capability-gated, read-only directory browser + file viewer to the agent console.Reworked after #70 — fs is MCP, not bespoke
fs/*The Part D decision (#70) locked the mechanism: fs is an MCP files server the target agent exposes, reached Studio-brokered via the
oabreverse-MCP tool — not a bespokefs/*method set on/acp. This slice was rewritten to match:crates/acp-tunnelfs/*client (fs.rs+Session::fs_list/fs_read/fs_stat) — the mechanism docs(adr): agent-consoles Part D — fs = MCP files server, Studio-brokered #70 rejected. No Rust change in this PR now.The fs MCP server + the
oabfs-relay are upstream (openab) and absent today, the same bucket as token streaming /tool_call. So this slice ships the UI + the source-agnostic read contract now; live fs traffic (MCP-backed read, then write/apply) lands in slice 4 with the server + relay. On a real endpoint the browser shows a "pending the fs MCP files server" placeholder; the browser build's mock serves a fixture filesystem so the surface is reviewable.Changes (
console)fileBrowser.ts— capability-gated directory browser + read-only CodeMirror viewer, mounted per open console, disposed on close/switch..tomlhighlighted; strictly read-only.render.ts— purefsListingHtml(dirs-before-files, sizes, open-marking,data-fs-*nav hooks) +fsUnavailableHtml.types/source/fixtures— the fs view-models;fsCapability/fsList/fsRead(Mock = fixture FS; Tauri = honestly unsupported until slice 4).index.html/styles.css— the Files region (listing + viewer split).ADR fidelity / security
fs/write/Apply is slice 4, gated at the fs server's tool level: agent-declaredroots,writabledefault-off, explicit Apply, no/-wide default.oabrelay stays management-only, no orchestrator/kube creds, no reverse-MCP grant widening.Testing
console—tsc --noEmitclean · 84 vitest (incl. fs render cases) ·vite buildOK.acp-tunnelfs client is removed).Follows: slice 4 — fs MCP server +
oabfs-relay, then write/apply.🤖 Generated with Claude Code