reword ack->mark-done terminology on mark_todos_done and get_loose_ends

This commit is contained in:
damocles 2026-08-16 17:47:25 +02:00 committed by mara
commit 5e7f74e92d

View file

@ -347,14 +347,15 @@ impl AgentServer {
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 \
the relevant context. Each `question` or `reminder` row can be cancelled by \
passing its id + kind to `cancel_loose_end`. Empty result is reported clearly. Todos \
cap at 40 rows; a trailer line says how many more are pending clear the shown ones \
with `mark_todos_done`, then call again for the rest.\n\
A row that is still genuinely in flight (a running bash task, say) doesn't need an \
early ack only mark done the ones you've actually resolved. A real content change \
(like a task finishing) un-acks and resurfaces the same row on its own, so acking it \
while it's still running buys nothing and just costs you a second, redundant call \
later.\n\
passing its id + kind to `cancel_loose_end`. Empty result is reported clearly.\n\
Todos are a to-do list, not an inbox to empty on sight a row that's still \
genuinely in flight (a running bash task, say) is expected to sit there and \
doesn't need marking done early; only mark done the ones you've actually \
reviewed and resolved. A real content change (like a task finishing) resurfaces \
the same row on its own regardless of whether you marked it done while it was \
still running, so doing that buys nothing and just costs a redundant call later. \
Todos cap at 40 rows; a trailer line says how many more are pending mark the \
reviewed ones done with `mark_todos_done`, then call again for the rest.\n\
Pass `agent: \"<name>\"` to inspect a specific peer agent's threads. Direct \
child agents are always accessible. For non-children, the `query_agent_state` \
capability is required without it the request is rejected with an error."
@ -554,19 +555,19 @@ impl AgentServer {
}
#[tool(
description = "Bulk-clear specific todos by id in one call, instead of \
description = "Bulk-mark specific todos done by id in one call, instead of \
`cancel_loose_end`ing each one. List-based, not range-based no `ack_until`-style \
'clear below id N' for todos, since a blind range-clear risks acking something you \
never saw. Pass the ids you've actually reviewed (typically what `get_loose_ends` \
just showed); unknown/already-acked ids are silently skipped. Returns how many were \
newly acked."
'clear below id N' for todos, since a blind range-clear risks marking something \
done that you never actually reviewed. Pass the ids you've actually reviewed \
(typically what `get_loose_ends` just showed); unknown/already-done ids are \
silently skipped. Returns how many were newly marked done."
)]
async fn mark_todos_done(&self, Parameters(args): Parameters<MarkTodosDoneArgs>) -> String {
let log = format!("{args:?}");
run_tool_envelope("mark_todos_done", log, async move {
match mark_local_todos_done(args.ids).await {
Some(hive_agent_sock::Response::Acked { count }) => {
format!("acked {count} todo(s)")
format!("marked {count} todo(s) done")
}
Some(hive_agent_sock::Response::Err { message }) => {
format!("mark_todos_done failed: {message}")