fix: address argus+mara review on #1243 — stale docs, MANAGER_DEFAULT refs, ruth migration

This commit is contained in:
damocles 2026-06-04 11:39:01 +02:00 committed by mara
commit e58ead4329
7 changed files with 64 additions and 37 deletions

View file

@ -43,8 +43,7 @@ pub enum SocketReply {
Recent(Vec<hive_sh4re::InboxRow>),
Logs(String),
HostJournal(String),
/// `list_schedules` result — used by the manager surface only;
/// `AgentResponse` has no equivalent variant.
/// `list_schedules` result — returned by `list_schedules` (scheduling tool group).
Schedules(Vec<hive_sh4re::WireSchedule>),
/// `list_containers` result — descendant containers with running status.
Containers(Vec<hive_sh4re::ContainerInfo>),
@ -738,7 +737,8 @@ impl AgentServer {
description = "List loose ends pending against this agent: unanswered questions \
where you are the asker (waiting on someone) or the target (someone's waiting on \
you), pending reminders you scheduled, plus for the manager only pending \
approvals you submitted that the operator hasn't acted on yet. Also lists active \
approvals you submitted that the operator hasn't acted on yet (agents with the \
`approvals` tool group also see their own pending approvals). Also lists active \
local tasks published by external MCP daemons (e.g. running bash tasks). Cheap sweep, no args. Useful \
at turn start to remember what you owe / what's owed to you without scrolling \
inbox history. Output is a short bulleted list with ids, ages in seconds, and \
@ -1448,7 +1448,7 @@ pub async fn serve_agent_stdio(socket: PathBuf) -> Result<()> {
}
// -----------------------------------------------------------------------------
// Manager tool surface
// Privileged tool arg types (lifecycle, approvals, scheduling, diagnostics)
// -----------------------------------------------------------------------------
#[derive(Debug, serde::Deserialize, schemars::JsonSchema)]
@ -1559,12 +1559,11 @@ pub struct CancelLooseEndArgs {
#[derive(Debug, serde::Deserialize, schemars::JsonSchema)]
pub struct GetLooseEndsArgs {
/// Whose loose ends to list. Omit (or `null`) for your own — the
/// manager's: approvals you submitted + questions where you are
/// asker/target + your own pending reminders. Pass `"*"` for a
/// hive-wide view of EVERY pending approval, unanswered question,
/// and reminder across the swarm. Pass a specific agent name to
/// inspect just that agent's threads.
/// Whose loose ends to list. Omit (or `null`) for your own: approvals
/// you submitted + questions where you are asker/target + your own
/// pending reminders. Pass `"*"` for a hive-wide view of EVERY pending
/// approval, unanswered question, and reminder across the swarm. Pass a
/// specific agent name to inspect just that agent's threads.
#[serde(default)]
pub agent: Option<String>,
}
@ -1576,7 +1575,7 @@ pub struct AgentGetLooseEndsArgs {
/// Pass any other agent name to inspect their threads — requires the
/// `query_agent_state` capability; without it the request is rejected
/// with an error. The `"*"` hive-wide value is not available on the
/// agent socket; use the manager socket for swarm-wide scans.
/// agent socket.
#[serde(default)]
pub agent: Option<String>,
}
@ -1744,13 +1743,6 @@ pub const SERVER_NAME: &str = "hyperhive";
/// should plan in /state notes instead.
pub const ALLOWED_BUILTIN_TOOLS: &[&str] = &["Edit", "Glob", "Grep", "Read", "Write"];
/// Kept for API stability — was two-variant (Agent/Manager) but the manager
/// role no longer exists. Only `Agent` remains; everything is perms + caps.
#[derive(Debug, Clone, Copy)]
pub enum Flavor {
Agent,
}
/// Env var written by the meta renderer with a comma-separated list of
/// `hive_sh4re::ToolGroup` snake_case names (e.g. `"messaging,inbox,meta"`).
/// When present, the harness expands the groups into per-tool allow entries