Skip to content

The fastest, cheapest, most efficient open-source agent harness. Run more than 500 agents on a $10 VPS.

docs(chat): describe subagent resume without naming continue_subagent

Steven Enamakelbaccdf26cf3f
diff --git a/app/src/providers/ChatRuntimeProvider.tsx b/app/src/providers/ChatRuntimeProvider.tsx
index f42f9935c3..4f4b8e6d47 100644
--- a/app/src/providers/ChatRuntimeProvider.tsx
+++ b/app/src/providers/ChatRuntimeProvider.tsx
@@ -943,8 +943,8 @@ const ChatRuntimeProvider = ({ children }: { children: React.ReactNode }) => {
// Event-seen guard, matching `onToolCall`/`onToolResult`. This socket
// reconnects and redelivers freely (13+ times in one measured
// session), and a replayed `subagent_spawned` that lands AFTER
- // `subagent_awaiting_user` looks exactly like `continue_subagent`
- // resuming the child — the reducer would clear the pause and the
+ // `subagent_awaiting_user` looks exactly like a same-task resume —
+ // the reducer would clear the pause and the
// question would vanish while the child was still blocked. `seq` is
// the core's own answer to this: `(request_id, seq)` is stamped per
// emission (`publish_seq_stamped`), so a redelivery repeats the pair
diff --git a/app/src/services/chatService.ts b/app/src/services/chatService.ts
index b5cb3478fb..382fc8b166 100644
--- a/app/src/services/chatService.ts
+++ b/app/src/services/chatService.ts
@@ -682,7 +682,7 @@ export interface SubagentProgressDetail {
/** `null` when the child's cost is not known. */
cost_usd?: number | null;
/**
- * Provider-assigned id of the `spawn_subagent`/`spawn_subagent`/
+ * Provider-assigned id of the `spawn_subagent`/
* `delegate_*` tool call that started this delegation
* (`AgentProgress::SubagentSpawned::parent_call_id`, threaded onto every
* event in the `subagent_*` family — see `crates/openhuman-rpc/src/server/socketio.rs`).
diff --git a/app/src/store/chatRuntimeSlice.ts b/app/src/store/chatRuntimeSlice.ts
index 1af09b8801..dd9d624895 100644
--- a/app/src/store/chatRuntimeSlice.ts
+++ b/app/src/store/chatRuntimeSlice.ts
@@ -108,8 +108,8 @@ export interface SubagentActivity {
* Identity (`<request_id>:<seq>`) of the `subagent_spawned` event that last
* started or resumed this delegation.
*
- * `continue_subagent` announces a resume by republishing `subagent_spawned`
- * for the same task/agent, so "an existing row got spawned again" is the
+ * Resuming a paused task republishes `subagent_spawned` for the same
+ * task/agent, so "an existing row got spawned again" is the
* only resume signal the frontend gets — and a Socket.IO redelivery of the
* ORIGINAL spawn is indistinguishable from it by shape alone. Comparing
* identities separates them: a redelivery repeats the pair the core stamped
@@ -1976,8 +1976,7 @@ const chatRuntimeSlice = createSlice({
const existing = entries.find(e => e.id === rowId);
if (existing) {
// ...with one exception. Resuming a paused task republishes
- // `subagent_spawned` for the SAME task/agent when it resumes a paused
- // child (continue_subagent.rs:330), and that is the only signal the
+ // `subagent_spawned` for the SAME task/agent, and that is the only signal the
// frontend gets that the pause is over. Swallowing it left the row
// stuck on `awaiting_user` for the rest of the run: the card kept
// asking a question the user had already answered.
@@ -2162,10 +2161,10 @@ const chatRuntimeSlice = createSlice({
// running, and a background delivery (a `chat_done` with no
// `inference_start`) then froze it as its own trail: a card that spun
// forever under the reply announcing the child's result. Both ids are
- // turn-independent, so a run resumed by `continue_subagent` (same task
- // id) also settles the earlier turn's card for it. That is how a paused
+ // turn-independent, so a run resumed with the same task id also settles
+ // the earlier turn's card for it. That is how a paused
// `awaiting_user` card clears: the resumed run's completion carries the
- // new `continue_subagent` call as its parent, never the original spawn.
+ // newest `spawn_subagent` call as its parent, never the original spawn.
// Restored past-turn timelines too, like `subagentCancelResolved`: they
// hold persisted (core-id) rows the process-source panel shows.
const coreRowId = taskId !== undefined ? `subagent:${taskId}` : undefined;
diff --git a/crates/openhuman-core/src/agent/orchestration/running_subagents_cancel_tests.rs b/crates/openhuman-core/src/agent/orchestration/running_subagents_cancel_tests.rs
index 31daede3cf..73df54dc4e 100644
--- a/crates/openhuman-core/src/agent/orchestration/running_subagents_cancel_tests.rs
+++ b/crates/openhuman-core/src/agent/orchestration/running_subagents_cancel_tests.rs
@@ -1,7 +1,6 @@
//! Cancelling and stopping registered sub-agents: by task, by thread, and all.
use super::*;
-use tinyagents_orchestration::steering::SteerError;
/// A finished run stays registered until the terminal sweep, so a late
/// "Cancel" still finds it. It must come back flagged, so the RPC does not
@@ -60,28 +59,6 @@ async fn cancel_all_clears_everything() {
"headless sub-agents must not contribute an id"
);
- assert_eq!(
- steer(
- &cx(),
- "task-all-1",
- "session-A",
- "x".into(),
- QueueLane::Steer
- )
- .await,
- Err(SteerError::Unknown)
- );
- assert_eq!(
- steer(
- &cx(),
- "task-all-2",
- "session-B",
- "x".into(),
- QueueLane::Steer
- )
- .await,
- Err(SteerError::Unknown)
- );
// Registry is empty now.
assert!(cancel_all(&cx()).is_empty());
}
@@ -122,29 +99,6 @@ async fn stop_for_thread_aborts_the_threads_running_children() {
joined.expect_err("child was aborted").is_cancelled(),
"stop must abort the detached child task"
);
- assert_eq!(
- steer(
- &cx(),
- "task-stop-1",
- "session-stop",
- "x".into(),
- QueueLane::Steer
- )
- .await,
- Err(SteerError::Unknown)
- );
- assert!(
- steer(
- &cx(),
- "task-stop-other",
- "session-stop",
- "x".into(),
- QueueLane::Steer
- )
- .await
- .is_ok(),
- "a different thread's sub-agent is untouched"
- );
assert!(
stop_for_thread(&cx(), "thread-stop").is_empty(),
"idempotent"
diff --git a/crates/openhuman-core/src/agent/orchestration/running_subagents_tests.rs b/crates/openhuman-core/src/agent/orchestration/running_subagents_tests.rs
index 833e591e0a..e28b44d973 100644
--- a/crates/openhuman-core/src/agent/orchestration/running_subagents_tests.rs
+++ b/crates/openhuman-core/src/agent/orchestration/running_subagents_tests.rs
@@ -11,12 +11,11 @@ use crate::agent::orchestration::running_subagents::roster::snapshot_for_parent;
use crate::agent::queued_turn::QueuedTurn;
use std::path::PathBuf;
use std::sync::Arc;
-use std::time::Duration;
use tinyagents_harness::ids::TaskId;
use tinyagents_harness::run_queue::RunQueue;
use tinyagents_orchestration::subagent::FinishedOutcome;
use tinyagents_orchestration::subagent::{
- DetachedSubagentStatus, WaitError, WaitOutcome, DETACHED_LEDGER_TIMEOUT_MS,
+ DetachedSubagentStatus, WaitError, DETACHED_LEDGER_TIMEOUT_MS,
};
use tinyagents_tasks::OrchestrationTaskStatus;
use tokio::sync::watch;