execute_programmatic
Method
This is a method of the TypedHandoff class in the handoff module.Execute typed handoff programmatically with schema validation.
Signature
Parameters
Agent
required
The agent initiating the handoff
Union[T, dict, str]
required
The typed payload (Pydantic model instance or dict) OR a string prompt (for backward compatibility)
Optional
Optional additional context
Returns
HandoffResult
HandoffResult with response or error
Exceptions
HandoffValidationError
HandoffValidationError
If payload validation fails
Uses
execute_programmatictime.timevalidated_payload.model_dump_jsonjson.dumpslogger.infochatHandoffResultlogger.error
Used By
Source
View on GitHub
praisonaiagents/agent/handoff.py at line 1431
