Skip to content

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

fix(agent): populate lifecycle key when spawning async subagents

Steven Enamakel4d7314bd204a
diff --git a/crates/openhuman-core/src/agent/orchestration/tools/spawn_async_subagent_execute.rs b/crates/openhuman-core/src/agent/orchestration/tools/spawn_async_subagent_execute.rs
index c0ebe3ae4f..af0883dfe8 100644
--- a/crates/openhuman-core/src/agent/orchestration/tools/spawn_async_subagent_execute.rs
+++ b/crates/openhuman-core/src/agent/orchestration/tools/spawn_async_subagent_execute.rs
@@ -279,7 +279,13 @@ impl SpawnAsyncSubagentTool {
task_title: task_title.clone(),
worker_thread_id: worker_thread_id.clone(),
task_id: task_id.clone(),
- lifecycle_key: None,
+ lifecycle_key: Some(
+ tinyagents_orchestration::subagent::SubagentTaskKey::from_context(
+ &detached_parent,
+ task_id.clone(),
+ parent_thread_id.clone(),
+ ),
+ ),
},
reusable.as_ref(),
) {