mirror of
https://github.com/outbackdingo/optimclaw.git
synced 2026-09-01 17:19:24 +00:00
feat(engine): live progress status updates via event broadcast
Engine v2 now shows live progress in the CLI (and any channel): - "Thinking..." when a step starts - Tool name + success/error when actions execute - "Processing results..." when a step completes Implementation: - ThreadManager holds a broadcast::Sender<ThreadEvent> (capacity 256) - ExecutionLoop.emit_event() writes to thread.events AND broadcasts - ThreadManager.subscribe_events() returns a receiver - Router uses tokio::select! to listen for events while waiting for thread completion, forwarding them as StatusUpdate to the channel This replaces the polling approach with zero-latency event streaming. Agent.channels visibility widened to pub(crate) for bridge access. 102 tests passing, zero clippy warnings. Co-Authored-By: Claude Opus 4.6 (1M context) <[email protected]>
This commit is contained in:
@@ -175,7 +175,7 @@ pub struct AgentDeps {
|
||||
pub struct Agent {
|
||||
pub(super) config: AgentConfig,
|
||||
pub(super) deps: AgentDeps,
|
||||
pub(super) channels: Arc<ChannelManager>,
|
||||
pub(crate) channels: Arc<ChannelManager>,
|
||||
pub(super) context_manager: Arc<ContextManager>,
|
||||
pub(super) scheduler: Arc<Scheduler>,
|
||||
pub(super) router: Router,
|
||||
|
||||
Reference in New Issue
Block a user