Parlora.Backends.Sagents (Parlora v0.1.0)

Copy Markdown View Source

Runs one isolated, bounded Sagents execution per admitted request.

Install optional sagents == 0.17.1. Configure :agent as a function receiving a BackendRequest and returning {:ok, agent, state}, :result as a function mapping a successful terminal tool result to %{status: ..., facts: ..., summary: ...}, and :completion_tool as its name. :max_runs defaults to 8 (maximum 100).

The application constructs the model, credentials and synchronous tools. Build the agent with replace_default_middleware: true and empty middleware; default filesystem/subagent tools, custom modes, fallbacks and asynchronous tools are deliberately unsupported. This makes execution ownership and authority explicit.

Cancellation is advisory: it stops local execution and reports an uncertain external outcome. It never confirms reversal of an already executed tool. Updates, model token streams, progress and clarification are not advertised.