"""Events emitted by the AI layer."""

from __future__ import annotations

from simorgh.apps.events.bus import register_event

register_event(
    "ai.suggestion_created",
    description="An AI agent or action produced a suggestion awaiting review.",
    payload_keys=("tenant_id", "kind", "suggestion_id"),
)
register_event(
    "ai.suggestion_approved",
    description="A human approved an AI suggestion.",
    payload_keys=("tenant_id", "suggestion_id", "actor_id"),
)
register_event(
    "ai.suggestion_rejected",
    description="A human rejected an AI suggestion.",
    payload_keys=("tenant_id", "suggestion_id", "actor_id"),
)
register_event(
    "ai.action_executed",
    description="An AI action was executed (auto or after approval).",
    payload_keys=("tenant_id", "action", "status"),
)
register_event(
    "ai.agent_run_completed",
    description="An AI agent run finished.",
    payload_keys=("tenant_id", "agent", "status"),
)
