ExAthena.Tools.TodoWrite (ExAthena v0.4.0)

Copy Markdown View Source

Writes the agent's todo list.

Stored in ctx.assigns[:todos] by default; callers that want a different side channel (e.g. broadcasting to a LiveView) can override via ctx.assigns[:todo_writer] — a function (list -> :ok) that the tool will call instead of (or in addition to) mutating the assigns map.

Arguments:

  • todos (required) — list of %{content: String.t(), status: "pending"|"in_progress"|"completed"}.

The loop replays the new list back to the model so it has fresh state.