Figure out how button clicks should work so that: 1. Actions happen immediately (no LLM latency) 2. Ava understands what happened (for coherent follow-up)
Button click triggers action, then injects synthetic message into conversation:
User clicked: [Start t-123]
System: Started work on t-123. Coder running...
Ava sees this in conversation history.
Maintain separate event log that Ava can reference:
data AvaEvent = ButtonClicked Text | WorkStarted TaskId | WorkCompleted TaskId | ...
Inject recent events into Ava's context.
Some messages bypass LLM (direct commands):
But still log everything for context.
Treat button clicks like tool calls - action happens, result goes into context:
[Button: start_task t-123]
[Result: Spawned pi-orchestrate for t-123]
Option A (Synthetic Messages) seems cleanest: