Class: Pikuri::Tasks::ListChanged
- Inherits:
-
Data
- Object
- Data
- Pikuri::Tasks::ListChanged
- Defined in:
- lib/pikuri/tasks/list_changed.rb
Overview
Domain event emitted onto the agent’s listener stream after every List mutation (add / status change / delete), wired by Extension#bind via Agent::ExtensionContext#emit_event. Carries a frozen point-in-time snapshot of the whole list (Pikuri::Tasks::List#items‘s shape), so a consumer needs no List reference — render or serialize the payload as-is.
Lands between the mutating tool’s Agent::Event::ToolCall and Agent::Event::ToolResult in the stream (the on_change hook fires inside the tool’s execute). A batch task_create emits one event per added item — consumers that render should treat the latest snapshot as authoritative (last-wins) rather than diffing event-by-event.
Fired on the agent’s thread. A listener feeding another thread (e.g. a web UI pushing over SSE) should serialize inside on_event and hand off only the immutable result — see the Concurrency note on List.
Instance Attribute Summary collapse
-
#items ⇒ Object
readonly
Returns the value of attribute items.
Instance Attribute Details
#items ⇒ Object (readonly)
Returns the value of attribute items
24 25 26 |
# File 'lib/pikuri/tasks/list_changed.rb', line 24 def items @items end |