operator inbox view on dashboard; agent ui doesn't clobber typing

This commit is contained in:
müde 2026-05-15 17:23:53 +02:00
parent 070b237d03
commit 06ea0cf283
9 changed files with 132 additions and 12 deletions

View file

@ -92,6 +92,10 @@ struct StateSnapshot {
containers: Vec<ContainerView>,
transients: Vec<TransientView>,
approvals: Vec<ApprovalView>,
/// Latest messages addressed to `operator` — surfaces agent replies
/// asynchronously so the operator can see them without watching the
/// live panel during a turn.
operator_inbox: Vec<crate::broker::InboxRow>,
}
#[derive(Serialize)]
@ -217,6 +221,12 @@ async fn api_state(
approval_views.push(view);
}
let operator_inbox = state
.coord
.broker
.recent_for(hive_sh4re::OPERATOR_RECIPIENT, 50)
.unwrap_or_default();
axum::Json(StateSnapshot {
hostname,
manager_port: MANAGER_PORT,
@ -224,6 +234,7 @@ async fn api_state(
containers,
transients,
approvals: approval_views,
operator_inbox,
})
}