Repository navigation
feat(hub): save files for a run's agent on its machine (OFF-143) - #655
Merged
Merged
Conversation
…ge and the API (OFF-143)
offdesk.so lets the person attach pictures, recordings and any file to a message for
an agent. New bridge commands upload_begin / upload_chunk / upload_end (and
POST /api/agent-runs/{id}/files/begin|chunk|end for runs:message tokens) save a file of
up to 100 MB in ~/.offdesk/attachments/<run> on the run's machine, through the node's
existing file transfer, and answer with its path for the message to name.
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Merged
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.
offdesk.so's Agents chat lets the person attach pictures, recordings and any file to a message. The hub saves each one on the run's machine and answers with its path, which the message then names. The agent opens it from disk, as it would a file dropped into its terminal.
upload_begin,upload_chunkandupload_endcommands.runs:message, an open run of the bridge's user, and a machine it can reach.upload_endis audited with the path and size but never the content.POST /api/agent-runs/{id}/files/begin|chunk|endforruns:messagetokens.FsUpload*messages andMkdir, so nodes don't change. Nodes withoutfs-ops-v1get a 503 "Update Offdesk…".~/.offdesk/attachments/<run_id>/. Names are cleaned, and a repeated name is kept as a copy (KeepBoth).docs/agent-bridge-protocol.md.Tests:
cargo test -p offdesk-hubpasses. They cover name cleaning, upload ownership, and a bridge test against a fake machine: refusals, folders, chunks, a repeated command id, another bridge, and audit.🤖 Generated with Claude Code