2.3.2

Agent

Package: flyte.ai.agents

Minimal protocol that any agent must satisfy to work with :class:AgentChatAppEnvironment.

protocol Agent()

Methods

Method Description
run() Process message (with prior history) and return an :class:AgentResult.
tool_descriptions() Return JSON-friendly metadata for every registered tool.

run()

def run(
    message: str,
    history: list[dict[str, str]],
) -> AgentResult

Process message (with prior history) and return an :class:AgentResult.

Parameter Type Description
message str
history list[dict[str, str]]

tool_descriptions()

def tool_descriptions()

Return JSON-friendly metadata for every registered tool.

Each dict should contain at least name, signature, and description keys.