Expand description
Core traits and types.
Always available regardless of feature flags. Includes:
Agent- The fundamental trait for all agentsTool/Toolset- For extending agents with capabilitiesSession/State- For managing conversation contextEvent- For streaming agent responsesAdkError/Result- Unified error handling Invocation context traits: state, session, artifacts, memory, and run configuration.
Structs§
- Memory
Entry - A single entry returned from memory search.
- RunConfig
- Configuration for a single agent run.
- RunConfig
Builder - Builder for
RunConfig. - Tool
Callback Context - Wraps a
CallbackContextto inject tool name and input for before-tool and after-tool callbacks. - Tool
Concurrency Config - Configuration for tool execution concurrency.
- Tool
Confirmation Request - Payload describing a tool call awaiting human confirmation.
- Tool
Outcome - Structured metadata about a completed tool execution.
Enums§
- Backpressure
Policy - Policy for handling excess tool calls when the concurrency limit is reached.
- Include
Contents - Controls what parts of prior conversation history is received by llmagent
- Streaming
Mode - Streaming mode for agent responses. Matches ADK Python/Go specification.
- Tool
Confirmation Decision - Decision applied when a tool execution requires human confirmation.
- Tool
Confirmation Policy - Policy defining which tools require human confirmation before execution.
Constants§
- MAX_
STATE_ KEY_ LEN - Maximum allowed length for state keys (256 bytes).
Traits§
- Artifacts
- Binary artifact storage for agents.
- Callback
Context - Context available to agent lifecycle callbacks.
- Invocation
Context - Full invocation context available to agents during execution.
- Memory
- Semantic memory search for agents.
- Readonly
Context - Read-only access to invocation metadata.
- Readonly
State - Read-only view of session state.
- Secret
Service - Trait for retrieving secrets at runtime.
- Session
- Represents an active conversation session with identity and state.
- State
- Mutable session state with key-value storage.
Functions§
- validate_
state_ key - Validates a state key. Returns
Ok(())if the key is safe, or an error message.