AgentListing class final
A class's agent list read once, for one run of the agent, in the shape AG-UI sends it. A new run reads the list again.
Constructors
- AgentListing.of(AgentSurface surface)
-
Reads
surface's AgentSurface.agentCapabilities and names its items with the generated AgentSurface.agentSchema.factory
Properties
-
context
→ List<
Map< String, Object?> > -
The
contextof AG-UI'sRunAgentInput: one entry for every.sees.final - hashCode → int
-
The hash code for this object.
no setterinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
-
tools
→ List<
Map< String, Object?> > -
The
toolsof AG-UI'sRunAgentInput: the methods listed when this listing was read.no setter
Methods
-
call(
String tool, Map< String, Object?> arguments, {bool approved = false}) → Future<Object?> -
Calls the method behind
toolwith the agent's JSONargumentsand returns its result as JSON. -
description(
String tool) → String -
The doc comment of
tool, as the agent got it. Throws a StateError for a tool this listing does not list. -
lists(
String tool) → bool -
needsApproval(
String tool) → bool -
Whether a call of
toolwaits for the user's approval, by the agent list as it is now. -
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited