Skip to content

file transfer (rust): send_message.files[] on the tool context - #350

Merged
brentrager merged 1 commit into
mainfrom
ft-rust
Aug 11, 2026
Merged

brentrager merged 1 commit into
mainfrom
ft-rust

Conversation

@brentrager

Copy link
Copy Markdown
Contributor

Completes Rust's side of the file-transfer contract (spec #342). Rust already had images→model and the directive sink; this adds the new files[]:

  • UserFile + ToolProviderContext.files (parallel to images) + with_files builder.
  • Parse send_message.files[] fail-soft in handler.rs, thread through the runner onto the tool context.
  • Files are surfaced to host tools (for the host — the smooth daemon — to persist into the workspace), NOT sent to the model.
  • Test-constructor call-sites updated for the new field; unit tests for UserFile round-trip + with_files.

⚠️ Do not merge yet — engine repo has no Rust PR CI, and I built this under a load-406 machine that killed the verification run. cargo fmt --check is clean; I'll re-run cargo clippy+cargo test once the box is sane and confirm green before merging. Part of the Big Smooth bidirectional file-transfer epic.

🤖 Generated with Claude Code

https://claude.ai/code/session_01Vzh8t76aDVgeoiwC9KEKZZ

Add UserFile + ToolProviderContext.files (parallel to images) + with_files
builder; parse send_message.files[] fail-soft in handler and thread through the
runner onto the tool context. Files are surfaced to host tools (for the host to
persist into the workspace), NOT sent to the model. Rust already had images +
the directive sink, so this completes Rust's side of the file-transfer contract.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Vzh8t76aDVgeoiwC9KEKZZ
@changeset-bot

changeset-bot Bot commented Aug 11, 2026

Copy link
Copy Markdown

🦋 Changeset detected

Latest commit: 6b69659

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
@smooai/smooth-operator-server Minor

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@brentrager
brentrager merged commit ee2bdaa into main Aug 11, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant