Turn-scoped activity projection for the agent UI.
The provider owns the underlying tool and todo state. This struct is the editor's render projection: it records the current turn start time, latest visible todo plan, active action, tool count, and touched file set.
Summary
Functions
Seeds the first visible timestamp without resetting the turn state.
Returns the number of touched files in the current projection.
Clears the active action after a tool finishes.
Marks the turn idle while preserving the last visible summary.
Creates an empty activity projection.
Records a touched file path for the current turn.
Replaces the visible todo plan.
Records that a tool started running.
Marks the beginning of a turn, preserving the visible plan.
Marks the beginning of a turn with a caller-provided timestamp.
Types
@type t() :: %MingaEditor.Agent.Activity{ active_action: String.t(), file_paths: MapSet.t(String.t()), started_at: DateTime.t() | nil, todos: [MingaAgent.TodoItem.t()], tool_count: non_neg_integer() }
Functions
Seeds the first visible timestamp without resetting the turn state.
@spec file_count(t()) :: non_neg_integer()
Returns the number of touched files in the current projection.
Clears the active action after a tool finishes.
Marks the turn idle while preserving the last visible summary.
@spec new() :: t()
Creates an empty activity projection.
Records a touched file path for the current turn.
@spec set_todos(t(), [MingaAgent.TodoItem.t()]) :: t()
Replaces the visible todo plan.
Records that a tool started running.
Marks the beginning of a turn, preserving the visible plan.
@spec start_turn(t(), DateTime.t()) :: t()
Marks the beginning of a turn with a caller-provided timestamp.