Skip to content
Dashboard

The fx adapter now runs the harness on the host

Software Engineer

The fx adapter for the AI SDK’s HarnessAgent now uses libfx, the TypeScript library for fx. The harness and model requests run in your application’s process, while built-in filesystem and shell operations remain isolated in the sandbox.

This simplifies sandbox setup: you no longer need to install fx inside the sandbox, run a sandbox bridge, or expose a sandbox port. Model credentials stay on the host, outside the environment where the agent runs commands.

The rewrite also adds:

  • Built-in tool filtering: choose which built-in tools the agent can use

  • Mid-turn steering: send new instructions while a turn is running

  • Structured output: generate responses that match a schema

  • Image tool results: return images to the model through toModelOutput()

Sessions can be saved and resumed in a new host process.

Update @ai-sdk/harness-fx to the latest version to use the new adapter. Learn more in the fx harness documentation.