AgenthubSdk behaviour (AgentHub SDK v1.0.2)
View SourceSimple interface to make agents runnable on AgentHub.
This module provides the core behavior for creating agent runners that can be executed on the AgentHub platform.
Summary
Callbacks
Defines the behavior for an agent runner.
Functions
Runs an agent with the given input.
Callbacks
Functions
Runs an agent with the given input.
This function provides a standardized way to execute agents that implement the AgentRunner behavior.
Parameters
agent_module
- The module implementing the AgentRunner behaviorinput
- The input data to pass to the agent
Returns
{:ok, result}
- On successful execution{:error, reason}
- On failure
Examples
iex> AgenthubSdk.run(MyAgent, %{data: "test"})
{:ok, %{result: "processed"}}