from typing import Literal, Any
from dataclasses import dataclass


@dataclass
class ConversationMessage:
    role: Literal["user", "assistant", "tool", "system"]
    """The role of the messages author."""

    content: str | None = None
    """The contents of the assistant message. Required unless tool_calls is specified."""

    tool_calls: list[Any] | None = None
    """The tool calls generated by the model, such as function calls."""

    tool_call_id: str | None = None
    """Unique identifier of the tool call."""

    sender: str | None = None
    """Indicate which agent the message originated from."""
