Repository navigation
feat: provide resource manipulation tools for remote agents - #115
Open
maxy-shpfy wants to merge 1 commit into
Conversation
maxy-shpfy
marked this pull request as ready for review
October 23, 2026 23:26
maxy-shpfy
force-pushed
the
maxy/feat--agents-tools-session-resources
branch
from
October 27, 2026 23:13
e515466 to
5257b70
Compare
maxy-shpfy
force-pushed
the
maxy/feat--agents-tools-session-resources
branch
from
October 28, 2026 23:50
5257b70 to
eaec694
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.
Description
A remote environment can add, list, and read session resources over the
/remote-envsocket, through the same catalog path the HTTP resource routes use. An agent on one host can contribute a file, a host entry, or a memory write, and Prime or an agent on another machine can fetch it.remote:resource:add,remote:resource:list, andremote:resource:read.RemoteResourceInputreusesHostResourceInput, so afilewrite (bytes underuploads/, binary as base64), ahostentry, and amemorywrite share one catalog path.useResourceswires the catalog, the spawn-preamble refresh, and the room notifier. Adds go throughapplyResourceInput. Lists scan the workspace, then return the catalog. Reads stay inside the session'suploads/andartifacts/trees, reject a uri that escapes that root, cap the payload atMAX_FILE_RESOURCE_BYTES, and return base64 plus a content type derived from the extension. Authorization reuses the room-read gate.maxHttpBufferSizematchesMAX_JSON_BODY_BYTES, so a file at the 1 MiB cap still fits once base64 and the ack envelope are included.@tangent/remote-subagent:addResource,listResources, andreadResource(30s ack timeout), documented in the package README.How to test
pnpm --filter @tangent/server test—remoteEnvironmentGatewayResources.test.tscovers a file add/read/list round trip, a uri that escapes the session root, a session-scoped host writing another session, and an add when the catalog is not wired.pnpm --filter @tangent/remote-subagent test— client ack success and rejection for add, list, and read.Notes
Builds on #111. Next in the stack is #112; calling these methods from the local agent host is follow-up work.
Stack created with GitHub Stacks CLI • Give Feedback 💬