Documentation
¶
Index ¶
- type Options
- type Service
- func (s *Service) HandleTaskCompleted(msg agentdomain.A2ATaskCompletedEvent) tea.Cmd
- func (s *Service) HandleTaskFailed(msg agentdomain.A2ATaskFailedEvent) tea.Cmd
- func (s *Service) HandleTaskInputRequired(msg agentdomain.A2ATaskInputRequiredEvent) tea.Cmd
- func (s *Service) HandleTaskStatusUpdate(msg agentdomain.A2ATaskStatusUpdateEvent) tea.Cmd
- func (s *Service) HandleTaskSubmitted(msg agentdomain.A2ATaskSubmittedEvent) tea.Cmd
- func (s *Service) HandleToolCallExecuted(msg agentdomain.A2AToolCallExecutedEvent) tea.Cmd
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Options ¶
type Options struct {
ConversationRepo convdomain.ConversationRepository
StateManager agentdomain.ChatSessionManager
TaskRetentionService scheddomain.TaskRetentionService
Listener ui.ChatEventListener
}
Options bundles the dependencies needed to construct a Service.
type Service ¶
type Service struct {
// contains filtered or unexported fields
}
Service handles the UI side of A2A task lifecycle events.
func NewService ¶
NewService creates a new A2A task coordinator.
func (*Service) HandleTaskCompleted ¶
func (s *Service) HandleTaskCompleted(msg agentdomain.A2ATaskCompletedEvent) tea.Cmd
HandleTaskCompleted retains the terminal task, emits the formatted result as streaming content, refreshes history, and signals completion.
func (*Service) HandleTaskFailed ¶
func (s *Service) HandleTaskFailed(msg agentdomain.A2ATaskFailedEvent) tea.Cmd
HandleTaskFailed produces an error-content event with whatever result the agent returned plus the error message.
func (*Service) HandleTaskInputRequired ¶
func (s *Service) HandleTaskInputRequired(msg agentdomain.A2ATaskInputRequiredEvent) tea.Cmd
HandleTaskInputRequired surfaces a warning that the remote agent is waiting on user input before it can continue.
func (*Service) HandleTaskStatusUpdate ¶
func (s *Service) HandleTaskStatusUpdate(msg agentdomain.A2ATaskStatusUpdateEvent) tea.Cmd
HandleTaskStatusUpdate emits a working-status update for an in-flight A2A task and keeps the listener pumping.
func (*Service) HandleTaskSubmitted ¶
func (s *Service) HandleTaskSubmitted(msg agentdomain.A2ATaskSubmittedEvent) tea.Cmd
HandleTaskSubmitted emits a working status indicating an A2A task was submitted to a remote agent and continues listening on the chat channel.
func (*Service) HandleToolCallExecuted ¶
func (s *Service) HandleToolCallExecuted(msg agentdomain.A2AToolCallExecutedEvent) tea.Cmd
HandleToolCallExecuted reports that a tool was executed on the remote gateway as part of an A2A round-trip.