Backplane.AgentRuntime.ToolEffects behaviour (backplane_agent_runtime v1.6.0)

Copy Markdown

Tool effects and cancellation boundary for Backplane agent runtime.

Summary

Types

adapter()

@type adapter() :: module()

Callbacks

cancel(map)

@callback cancel(map()) :: :ok | {:error, Backplane.AgentRuntime.Error.t()}

execute(map)

@callback execute(map()) :: {:ok, map()} | {:error, Backplane.AgentRuntime.Error.t()}

Functions

cancel(adapter, invocation)

@spec cancel(adapter(), map()) :: :ok | {:error, Backplane.AgentRuntime.Error.t()}

execute(adapter, invocation, context)

@spec execute(adapter(), map(), map()) ::
  {:ok, map()} | {:error, Backplane.AgentRuntime.Error.t()}

validate_output(output, opts \\ [])

@spec validate_output(map(), keyword()) ::
  {:ok, map()} | {:error, Backplane.AgentRuntime.Error.t()}