Watch
0
0
Fork
You've already forked hyperhive
0

Compare commits

..
5 changed files with 11 additions and 12 deletions

View file

@ -15,12 +15,11 @@ future reader won't think to look).
- **Pure fire-and-forget notification, no reply expected** - a - **Pure fire-and-forget notification, no reply expected** - a
dashboard-visible one-way message is fine. Don't reach for a dashboard-visible one-way message is fine. Don't reach for a
conversational channel just to say something that needs no response. conversational channel just to say something that needs no response.
- **A specific decision you need recorded** (a gated approval, a - **A specific decision you need recorded, that threads an answer back
go/no-go call) - if it's issue-shaped, it's really the next bullet to you** - use a mechanism built for exactly that (queues cleanly,
(post it where the context lives and it stays that thread's own the answer comes back attached to the question). This matters for
back-and-forth); otherwise use a real conversational channel and anything you'll need to point back to later - a gated approval, a
write the outcome down somewhere a future reader will actually find go/no-go call.
it - no tool threads that bookkeeping back to you automatically.
- **An issue-shaped question or decision** - post it where the - **An issue-shaped question or decision** - post it where the
surrounding context already lives (the tracked item itself), not in surrounding context already lives (the tracked item itself), not in
a side channel. A future reader looking at that item should find the a side channel. A future reader looking at that item should find the

View file

@ -391,8 +391,8 @@ impl AgentServer {
}; };
let kind_label = loose_end_kind_label(kind); let kind_label = loose_end_kind_label(kind);
// Reminders are harness-local — dial the in-agent socket // Reminders are harness-local — dial the in-agent socket
// directly instead of the broker; the other kind (approval) // directly instead of the broker; every other kind
// still lives in c0re. // (question/approval) still lives in c0re.
if kind == hive_sh4re::inbox::CancelLooseEndKind::Reminder { if kind == hive_sh4re::inbox::CancelLooseEndKind::Reminder {
return match dial_agent_socket(&hive_agent_sock::Request::CancelReminder { id }) return match dial_agent_socket(&hive_agent_sock::Request::CancelReminder { id })
.await .await

View file

@ -26,8 +26,8 @@ pub const MESSAGE_MAX_BYTES: usize = 4096;
/// `Response::Err`) on failure. /// `Response::Err`) on failure.
/// ///
/// `label` shows up in the error message verbatim — pass a short /// `label` shows up in the error message verbatim — pass a short
/// noun like `"send"` or `"broadcast"` so the model can tell which /// noun like `"send"`, `"question"`, `"broadcast"` so the model can
/// call got rejected. /// tell which call got rejected.
pub fn check_size(label: &str, body: &str) -> Result<(), String> { pub fn check_size(label: &str, body: &str) -> Result<(), String> {
if body.len() > MESSAGE_MAX_BYTES { if body.len() > MESSAGE_MAX_BYTES {
Err(format!( Err(format!(

View file

@ -173,7 +173,7 @@ pub struct Coordinator {
/// Unified wire-facing event channel feeding the dashboard SSE /// Unified wire-facing event channel feeding the dashboard SSE
/// stream. Carries broker messages (mirrored from `broker.subscribe` /// stream. Carries broker messages (mirrored from `broker.subscribe`
/// by the forwarder task in `main.rs`) and dashboard-only mutation /// by the forwarder task in `main.rs`) and dashboard-only mutation
/// events (approval added/resolved, etc.). /// events (approval added/resolved, question added/answered, etc.).
/// Snapshot endpoints capture `event_seq` before reading state so /// Snapshot endpoints capture `event_seq` before reading state so
/// the client can dedupe its buffered live traffic against the /// the client can dedupe its buffered live traffic against the
/// snapshot. /// snapshot.

View file

@ -86,7 +86,7 @@ pub struct PowerStore {
impl PowerStore { impl PowerStore {
/// Open (a connection to) the shared coordinator DB and ensure the /// Open (a connection to) the shared coordinator DB and ensure the
/// `agent_power` table exists. `db_path` is the same sqlite file /// `agent_power` table exists. `db_path` is the same sqlite file
/// the broker / approvals stores open. /// the broker / approvals / questions stores open.
pub fn open(db_path: &Path) -> Result<Self> { pub fn open(db_path: &Path) -> Result<Self> {
let conn = crate::db::open(db_path, "agent_power")?; let conn = crate::db::open(db_path, "agent_power")?;
conn.execute_batch(SCHEMA) conn.execute_batch(SCHEMA)