2026-05-27 13:58:57 +02:00
|
|
|
"""Built-in ``agent_task`` action. Self-registers at import time."""
|
|
|
|
|
|
|
|
|
|
from __future__ import annotations
|
|
|
|
|
|
2026-05-27 17:02:44 +02:00
|
|
|
from app.automations.actions.agent_task import build_handler
|
2026-05-27 13:58:57 +02:00
|
|
|
from app.automations.schemas.actions import AgentTaskActionParams
|
|
|
|
|
|
|
|
|
|
from .store import register_action
|
2026-05-27 17:02:44 +02:00
|
|
|
from .types import ActionDefinition
|
2026-05-27 13:58:57 +02:00
|
|
|
|
|
|
|
|
AGENT_TASK_ACTION = ActionDefinition(
|
|
|
|
|
type="agent_task",
|
|
|
|
|
name="Agent task",
|
2026-05-27 17:02:44 +02:00
|
|
|
description="Run a multi_agent_chat turn from an automation step.",
|
2026-05-27 13:58:57 +02:00
|
|
|
params_schema=AgentTaskActionParams.model_json_schema(),
|
2026-05-27 17:02:44 +02:00
|
|
|
build_handler=build_handler,
|
2026-05-27 13:58:57 +02:00
|
|
|
)
|
|
|
|
|
|
|
|
|
|
register_action(AGENT_TASK_ACTION)
|