kodeagent.history_formatter.HistoryFormatter#
- class kodeagent.history_formatter.HistoryFormatter[source]#
Abstract base class for formatting agent message history for LLM calls.
This class defines the interface for formatting strategies. Subclasses implement agent-specific logic for detecting and formatting tool calls.
- __init__()#
Methods
__init__()format_tool_call(msg, state)Format a message as a tool call.
pydantic_to_dict(msg)Convert Pydantic message to dict with proper formatting and metadata.
Determine if a message should be formatted as a tool call.