Skip to content

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

chore: files changed crates/openhuman-core/src/agent/orchestration/running_subagents/cancel.rs,crate

Steven Enamakel9751bc65c4b8
diff --git a/crates/openhuman-core/src/agent/orchestration/running_subagents/cancel.rs b/crates/openhuman-core/src/agent/orchestration/running_subagents/cancel.rs
index ee23afea25..c013a3e7f7 100644
--- a/crates/openhuman-core/src/agent/orchestration/running_subagents/cancel.rs
+++ b/crates/openhuman-core/src/agent/orchestration/running_subagents/cancel.rs
@@ -108,7 +108,7 @@ pub(crate) fn cancel_by_task_with_workspace_reason(
workspace_dir.clone(),
);
let jobs = crate::core::runtime::slot_for::<
- tinyagents_orchestration::subagent::SubAgentJobRegistry,
+ tinyagents_harness_tools::subagents::SubAgentJobRegistry,
>(ctx);
let selected = crate::agent::orchestration::subagent_sessions::cancel_driver_job_by_task(
&store,
@@ -218,7 +218,7 @@ pub(crate) fn stop_for_thread(
if let Some(core_context) = ctx.resolved() {
if let Ok(workspace_dir) = core_context.workspace_dir() {
let jobs = crate::core::runtime::slot_for::<
- tinyagents_orchestration::subagent::SubAgentJobRegistry,
+ tinyagents_harness_tools::subagents::SubAgentJobRegistry,
>(ctx);
let driver_stopped =
crate::agent::orchestration::subagent_sessions::cancel_driver_jobs_for_thread(
diff --git a/crates/openhuman-core/src/agent/orchestration/running_subagents/steering.rs b/crates/openhuman-core/src/agent/orchestration/running_subagents/steering.rs
index a696ed18d8..bcd2b7eb21 100644
--- a/crates/openhuman-core/src/agent/orchestration/running_subagents/steering.rs
+++ b/crates/openhuman-core/src/agent/orchestration/running_subagents/steering.rs
@@ -44,7 +44,7 @@ pub async fn steer(
.await?;
tracing::info!(
task_id,
- lane = tinyagents_orchestration::subagent::queue_lane_name(lane),
+ lane = tinyagents_orchestration::steering::queue_lane_name(lane),
?route,
"[running_subagents] steered detached task"
);
@@ -97,7 +97,7 @@ pub(crate) async fn steer_control(
.await?;
tracing::info!(
task_id,
- lane = tinyagents_orchestration::subagent::queue_lane_name(lane),
+ lane = tinyagents_orchestration::steering::queue_lane_name(lane),
?route,
"[running_subagents] control-steered detached task"
);
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 375232e972..31daede3cf 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,7 @@
//! Cancelling and stopping registered sub-agents: by task, by thread, and all.
use super::*;
-use tinyagents_orchestration::subagent::SteerError;
+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
diff --git a/crates/openhuman-core/src/agent/orchestration/running_subagents_steering_tests.rs b/crates/openhuman-core/src/agent/orchestration/running_subagents_steering_tests.rs
index 65a5a6c127..b663c3032c 100644
--- a/crates/openhuman-core/src/agent/orchestration/running_subagents_steering_tests.rs
+++ b/crates/openhuman-core/src/agent/orchestration/running_subagents_steering_tests.rs
@@ -1,5 +1,5 @@
use super::*;
-use tinyagents_orchestration::subagent::SteerError;
+use tinyagents_orchestration::steering::SteerError;
#[tokio::test]
async fn steer_pushes_into_the_subagent_queue() {
diff --git a/crates/openhuman-core/src/agent/orchestration/running_subagents_tenant_tests.rs b/crates/openhuman-core/src/agent/orchestration/running_subagents_tenant_tests.rs
index faceb2645f..f63c1851a2 100644
--- a/crates/openhuman-core/src/agent/orchestration/running_subagents_tenant_tests.rs
+++ b/crates/openhuman-core/src/agent/orchestration/running_subagents_tenant_tests.rs
@@ -5,7 +5,7 @@ use crate::agent::orchestration::running_subagents::resolve::{
use crate::core::runtime::DispatchCtx;
use crate::core::runtime::{ContextOverlay, CoreContext, DomainSet, Mode};
use crate::tools::toolpacks::ToolGroups;
-use tinyagents_orchestration::subagent::SteerError;
+use tinyagents_orchestration::steering::SteerError;
const CHILD: &str = "OPENHUMAN_DETACHED_TENANT_TEST_CHILD";
const PARENT: &str = "same-parent-session";
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 59b26c3bbc..4e8237baa3 100644
--- a/crates/openhuman-core/src/agent/orchestration/running_subagents_tests.rs
+++ b/crates/openhuman-core/src/agent/orchestration/running_subagents_tests.rs
@@ -1,5 +1,5 @@
use super::*;
-use tinyagents_orchestration::subagent::SteerError;
+use tinyagents_orchestration::steering::SteerError;
/// The context these tests dispatch under: the calling task's own.
fn cx() -> crate::core::runtime::DispatchCtx {
diff --git a/crates/openhuman-core/src/agent/orchestration/subagent_sessions/ops_driver.rs b/crates/openhuman-core/src/agent/orchestration/subagent_sessions/ops_driver.rs
index 6fbdee1e73..5796ea700e 100644
--- a/crates/openhuman-core/src/agent/orchestration/subagent_sessions/ops_driver.rs
+++ b/crates/openhuman-core/src/agent/orchestration/subagent_sessions/ops_driver.rs
@@ -8,7 +8,7 @@ use super::*;
pub fn cancel_driver_jobs_for_thread(
store: &SubagentSessionStore,
workspace_dir: &Path,
- jobs: &tinyagents_orchestration::subagent::SubAgentJobRegistry,
+ jobs: &tinyagents_harness_tools::subagents::SubAgentJobRegistry,
thread_id: &str,
) -> Vec<String> {
let sessions = match store.load() {
@@ -66,7 +66,7 @@ pub fn cancel_driver_jobs_for_thread(
pub fn cancel_driver_job_for_observed_session(
store: &SubagentSessionStore,
checkpoint_dir: &Path,
- jobs: &tinyagents_orchestration::subagent::SubAgentJobRegistry,
+ jobs: &tinyagents_harness_tools::subagents::SubAgentJobRegistry,
session: &DurableSubagentSession,
parent_session: &str,
parent_thread_id: Option<&str>,
@@ -126,7 +126,7 @@ pub struct DriverTaskCancellation {
pub fn cancel_driver_job_by_task(
store: &SubagentSessionStore,
checkpoint_dir: &Path,
- jobs: &tinyagents_orchestration::subagent::SubAgentJobRegistry,
+ jobs: &tinyagents_harness_tools::subagents::SubAgentJobRegistry,
task_id: &str,
reason: Option<&str>,
) -> Result<Option<DriverTaskCancellation>, String> {
diff --git a/crates/openhuman-core/src/agent/orchestration/subagent_sessions/tiny_port.rs b/crates/openhuman-core/src/agent/orchestration/subagent_sessions/tiny_port.rs
index e62fcb2aa7..f50c0d3d7f 100644
--- a/crates/openhuman-core/src/agent/orchestration/subagent_sessions/tiny_port.rs
+++ b/crates/openhuman-core/src/agent/orchestration/subagent_sessions/tiny_port.rs
@@ -21,7 +21,7 @@ pub(crate) struct OpenHumanTinySubagentSessionStore {
checkpoint_dir: PathBuf,
parent_session: String,
parent_thread_id: Option<String>,
- jobs: Option<tinyagents_orchestration::subagent::SubAgentJobRegistry>,
+ jobs: Option<tinyagents_harness_tools::subagents::SubAgentJobRegistry>,
}
impl OpenHumanTinySubagentSessionStore {
@@ -41,7 +41,7 @@ impl OpenHumanTinySubagentSessionStore {
pub(crate) fn with_jobs(
mut self,
- jobs: tinyagents_orchestration::subagent::SubAgentJobRegistry,
+ jobs: tinyagents_harness_tools::subagents::SubAgentJobRegistry,
) -> Self {
self.jobs = Some(jobs);
self
diff --git a/crates/openhuman-core/src/agent/orchestration/tools/spawn_async_subagent_host_impl.rs b/crates/openhuman-core/src/agent/orchestration/tools/spawn_async_subagent_host_impl.rs
index 87352b624b..f27e3f4f60 100644
--- a/crates/openhuman-core/src/agent/orchestration/tools/spawn_async_subagent_host_impl.rs
+++ b/crates/openhuman-core/src/agent/orchestration/tools/spawn_async_subagent_host_impl.rs
@@ -134,7 +134,7 @@ impl SpawnAsyncSubagentTool {
match subagent_sessions::find_reusable(&store, &selector) {
Ok(Some(session)) => {
let jobs = crate::core::runtime::slot_for::<
- tinyagents_orchestration::subagent::SubAgentJobRegistry,
+ tinyagents_harness_tools::subagents::SubAgentJobRegistry,
>(&dispatch);
let cancelled = subagent_sessions::cancel_driver_job_for_observed_session(
&store,
diff --git a/crates/openhuman-core/src/agent/orchestration/tools/tools_e2e_driver_tests.rs b/crates/openhuman-core/src/agent/orchestration/tools/tools_e2e_driver_tests.rs
index 064f5e0cdb..90089d4e12 100644
--- a/crates/openhuman-core/src/agent/orchestration/tools/tools_e2e_driver_tests.rs
+++ b/crates/openhuman-core/src/agent/orchestration/tools/tools_e2e_driver_tests.rs
@@ -206,7 +206,7 @@ async fn force_fresh_cancels_old_driver_before_creating_a_new_session() {
Some("force-fresh-parent-thread".into()),
);
let wait = SubAgentJobsTool::new((*jobs).clone())
- .with_fixed_action(tinyagents_orchestration::subagent::SubAgentJobAction::Await)
+ .with_fixed_action(tinyagents_harness_tools::subagents::SubAgentJobAction::Await)
.with_identifier_fields("task_id", "subagent_session_id")
.with_sessions(Arc::new(session_port), |_| {
"force-fresh-parent-session".to_owned()
@@ -366,7 +366,7 @@ async fn stopped_async_spawn_is_refused_before_progress_or_session_effects() {
"refusal must not publish spawn progress"
);
let jobs = crate::core::runtime::slot_for::<
- tinyagents_orchestration::subagent::SubAgentJobRegistry,
+ tinyagents_harness_tools::subagents::SubAgentJobRegistry,
>(&dispatch);
assert!(
jobs.list().is_empty(),
@@ -508,7 +508,7 @@ async fn deleted_thread_marker_survives_router_restart_and_refuses_async_spawn()
"refusal writes no durable child session"
);
let jobs = crate::core::runtime::slot_for::<
- tinyagents_orchestration::subagent::SubAgentJobRegistry,
+ tinyagents_harness_tools::subagents::SubAgentJobRegistry,
>(&restarted.data.dispatch_ctx());
assert!(jobs.list().is_empty(), "refusal registers no shared job");
@@ -613,7 +613,7 @@ async fn detached_registration_failure_finishes_the_announced_product_card() {
"registration error must not dispatch the model"
);
let jobs = crate::core::runtime::slot_for::<
- tinyagents_orchestration::subagent::SubAgentJobRegistry,
+ tinyagents_harness_tools::subagents::SubAgentJobRegistry,
>(&live.data.dispatch_ctx());
assert!(
jobs.list().is_empty(),
diff --git a/crates/openhuman-core/src/agent/orchestration/tools/tools_e2e_tests.rs b/crates/openhuman-core/src/agent/orchestration/tools/tools_e2e_tests.rs
index 913f9d5655..37cacb89b6 100644
--- a/crates/openhuman-core/src/agent/orchestration/tools/tools_e2e_tests.rs
+++ b/crates/openhuman-core/src/agent/orchestration/tools/tools_e2e_tests.rs
@@ -49,7 +49,7 @@ async fn spawn_subagent_tool_runs_child_agent_e2e() {
assert!(provider.saw(SPAWN_SUBAGENT_CANARY));
assert!(provider.saw("parent supplied context"));
let jobs = crate::core::runtime::slot_for::<
- tinyagents_orchestration::subagent::SubAgentJobRegistry,
+ tinyagents_harness_tools::subagents::SubAgentJobRegistry,
>(&live.data.dispatch_ctx());
assert!(
jobs.list().iter().any(|job| {
@@ -170,7 +170,7 @@ async fn archetype_delegation_tool_runs_child_agent_e2e() {
assert!(provider.saw(ARCHETYPE_DELEGATION_CANARY));
let jobs = crate::core::runtime::slot_for::<
- tinyagents_orchestration::subagent::SubAgentJobRegistry,
+ tinyagents_harness_tools::subagents::SubAgentJobRegistry,
>(&live.data.dispatch_ctx());
let completed = jobs.list();
assert!(
diff --git a/crates/openhuman-core/src/agent/orchestration/tools/tools_e2e_workspace_owner_tests.rs b/crates/openhuman-core/src/agent/orchestration/tools/tools_e2e_workspace_owner_tests.rs
index de81145a7c..27c09f9fa5 100644
--- a/crates/openhuman-core/src/agent/orchestration/tools/tools_e2e_workspace_owner_tests.rs
+++ b/crates/openhuman-core/src/agent/orchestration/tools/tools_e2e_workspace_owner_tests.rs
@@ -9,7 +9,7 @@ async fn driver_job_controls_are_isolated_by_workspace_with_shared_runtime_state
use crate::core::runtime::{ContextOverlay, CoreContext, DomainSet};
use crate::tools::toolpacks::ToolGroups;
use tinyagents_harness::agent_loop::phases::execute_tool_batch;
- use tinyagents_orchestration::subagent::SubAgentJobRegistry;
+ use tinyagents_harness_tools::subagents::SubAgentJobRegistry;
use tinyagents_runtime::turn_driver::SharedToolSet;
struct PausedModel {
diff --git a/crates/openhuman-core/src/agent/subagent_host/lifecycle.rs b/crates/openhuman-core/src/agent/subagent_host/lifecycle.rs
index 41a99a0371..140b4217cb 100644
--- a/crates/openhuman-core/src/agent/subagent_host/lifecycle.rs
+++ b/crates/openhuman-core/src/agent/subagent_host/lifecycle.rs
@@ -213,7 +213,7 @@ pub(crate) async fn spawn_async_via_driver_tool_with_jobs(
definition: crate::agent_registry::host_definition::AgentDefinition,
input: String,
options: SubagentRunOptions,
- jobs: tinyagents_orchestration::subagent::SubAgentJobRegistry,
+ jobs: tinyagents_harness_tools::subagents::SubAgentJobRegistry,
completion: impl Fn(
String,
Result<SubagentRunOutcome, String>,
@@ -239,7 +239,7 @@ async fn spawn_async_via_driver_tool_using_jobs(
definition: crate::agent_registry::host_definition::AgentDefinition,
input: String,
options: SubagentRunOptions,
- jobs: Option<tinyagents_orchestration::subagent::SubAgentJobRegistry>,
+ jobs: Option<tinyagents_harness_tools::subagents::SubAgentJobRegistry>,
completion: impl Fn(
String,
Result<SubagentRunOutcome, String>,
@@ -287,7 +287,7 @@ async fn invoke_async_spawn_driver_tool(
options: SubagentRunOptions,
mode: &str,
completion: Option<HostCompletion>,
- jobs_override: Option<tinyagents_orchestration::subagent::SubAgentJobRegistry>,
+ jobs_override: Option<tinyagents_harness_tools::subagents::SubAgentJobRegistry>,
continuation: Option<(SubagentTaskKey, SubagentResume)>,
) -> Result<(tinytools::ToolResult, OpenHumanDriverBundle), SubagentRunError> {
invoke_driver_tool_with_request(
@@ -311,7 +311,7 @@ async fn invoke_driver_tool_with_request(
input: String,
mode: &str,
completion: Option<HostCompletion>,
- jobs_override: Option<tinyagents_orchestration::subagent::SubAgentJobRegistry>,
+ jobs_override: Option<tinyagents_harness_tools::subagents::SubAgentJobRegistry>,
continuation: Option<(SubagentTaskKey, SubagentResume)>,
) -> Result<(tinytools::ToolResult, OpenHumanDriverBundle), SubagentRunError> {
use tinyagents_harness::tool::ToolDispatch;
diff --git a/crates/openhuman-core/src/agent/subagent_host/lifecycle_storage_adoption_tests.rs b/crates/openhuman-core/src/agent/subagent_host/lifecycle_storage_adoption_tests.rs
index d2eff2849b..2a2782e68d 100644
--- a/crates/openhuman-core/src/agent/subagent_host/lifecycle_storage_adoption_tests.rs
+++ b/crates/openhuman-core/src/agent/subagent_host/lifecycle_storage_adoption_tests.rs
@@ -239,7 +239,7 @@ async fn a_detached_driver_uses_its_carried_actor_for_lifecycle_commits() {
"finish".into(),
"background",
Some(completion),
- Some(tinyagents_orchestration::subagent::SubAgentJobRegistry::default()),
+ Some(tinyagents_harness_tools::subagents::SubAgentJobRegistry::default()),
None,
)
.await
diff --git a/crates/openhuman-core/src/agent/subagent_host/lifecycle_terminal_tests.rs b/crates/openhuman-core/src/agent/subagent_host/lifecycle_terminal_tests.rs
index e2233d18d1..ac5db9c740 100644
--- a/crates/openhuman-core/src/agent/subagent_host/lifecycle_terminal_tests.rs
+++ b/crates/openhuman-core/src/agent/subagent_host/lifecycle_terminal_tests.rs
@@ -10,7 +10,7 @@ async fn driver_cancel_uses_the_typed_terminal_for_lossy_idle_sessions() {
let directory = tempfile::tempdir().unwrap();
let workspace = directory.path();
let store = SubagentSessionStore::new(workspace.to_path_buf());
- let jobs = tinyagents_orchestration::subagent::SubAgentJobRegistry::default();
+ let jobs = tinyagents_harness_tools::subagents::SubAgentJobRegistry::default();
let persistence = OpenHumanPersistence::new(workspace.join(".openhuman/subagent_checkpoints"));
for (task_id, terminal, expected) in [
diff --git a/crates/openhuman-core/src/agent/subagent_host/ops_tests_driver_bridge_tests.rs b/crates/openhuman-core/src/agent/subagent_host/ops_tests_driver_bridge_tests.rs
index ba4079c714..aeb098505f 100644
--- a/crates/openhuman-core/src/agent/subagent_host/ops_tests_driver_bridge_tests.rs
+++ b/crates/openhuman-core/src/agent/subagent_host/ops_tests_driver_bridge_tests.rs
@@ -33,7 +33,7 @@ async fn prepared_subagent_runs_through_driver_jobs_dispatcher() {
);
assert_eq!(provider.captured.lock().len(), 1, "child provider must run");
let jobs = crate::core::runtime::slot_for::<
- tinyagents_orchestration::subagent::SubAgentJobRegistry,
+ tinyagents_harness_tools::subagents::SubAgentJobRegistry,
>(&parent.data.dispatch_ctx());
let job = jobs.get(&job_id).expect("driver tool registered the job");
assert_eq!(job.agent, "test");
@@ -386,7 +386,7 @@ async fn closing_a_durable_driver_session_cancels_only_its_registered_child() {
let message_store: std::sync::Arc<dyn TinySessionStore> = std::sync::Arc::new(port.clone());
let message_dispatch: crate::agent::tinyagents::tool_registration::RegisteredToolDispatch =
std::sync::Arc::new(
- tinyagents_orchestration::subagent::SubAgentMessageTool::new(jobs.clone())
+ tinyagents_harness_tools::subagents::SubAgentMessageTool::new(jobs.clone())
.with_tool_name("steer_subagent")
.with_argument_fields("task_id", "subagent_session_id", "message", "__request_id")
.with_lane_field("mode")
@@ -605,7 +605,7 @@ async fn detached_driver_spawn_repairs_replayed_host_outcome_without_reexecution
make_def_named_tools(&[]),
"return the persisted result".into(),
first_options,
- tinyagents_orchestration::subagent::SubAgentJobRegistry::new(),
+ tinyagents_harness_tools::subagents::SubAgentJobRegistry::new(),
move |_target, result, effects| {
let first_tx = first_tx.clone();
Box::pin(async move {
@@ -638,7 +638,7 @@ async fn detached_driver_spawn_repairs_replayed_host_outcome_without_reexecution
make_def_named_tools(&[]),
"return the persisted result".into(),
replay_options,
- tinyagents_orchestration::subagent::SubAgentJobRegistry::new(),
+ tinyagents_harness_tools::subagents::SubAgentJobRegistry::new(),
move |_target, result, effects| {
let replay_tx = replay_tx.clone();
Box::pin(async move {
diff --git a/crates/openhuman-core/src/agent/tinyagents/tool_registration_tests.rs b/crates/openhuman-core/src/agent/tinyagents/tool_registration_tests.rs
index 5144df6149..69c54f1820 100644
--- a/crates/openhuman-core/src/agent/tinyagents/tool_registration_tests.rs
+++ b/crates/openhuman-core/src/agent/tinyagents/tool_registration_tests.rs
@@ -430,7 +430,7 @@ async fn memory_live_context_dispatch_cancels_with_parent_without_creating_a_chi
.with_cancellation(cancellation.clone())
.into_tinyagents(RunConfig::new("memory-live-context-cancel"));
let jobs = crate::core::runtime::slot_for::<
- tinyagents_orchestration::subagent::SubAgentJobRegistry,
+ tinyagents_harness_tools::subagents::SubAgentJobRegistry,
>(&parent.data.dispatch_ctx());
assert!(jobs.list().is_empty(), "fresh parent has no child jobs");
diff --git a/crates/openhuman-core/src/agent_runs/subagent_control.rs b/crates/openhuman-core/src/agent_runs/subagent_control.rs
index e1d43165d7..427dee6bd0 100644
--- a/crates/openhuman-core/src/agent_runs/subagent_control.rs
+++ b/crates/openhuman-core/src/agent_runs/subagent_control.rs
@@ -16,7 +16,7 @@
use crate::core::runtime::DispatchCtx;
use serde_json::{json, Map, Value};
-use tinyagents_orchestration::subagent::SteerError;
+use tinyagents_orchestration::steering::SteerError;
use crate::agent::orchestration::running_subagents::CancelledSubagent;
use crate::agent::orchestration::{background_completions, running_subagents, subagent_sessions};
diff --git a/crates/openhuman-core/src/threads/ops/crud.rs b/crates/openhuman-core/src/threads/ops/crud.rs
index 023d22feb4..9f4903358b 100644
--- a/crates/openhuman-core/src/threads/ops/crud.rs
+++ b/crates/openhuman-core/src/threads/ops/crud.rs
@@ -492,7 +492,7 @@ async fn thread_delete_inner(
let cancelled_legacy =
crate::agent::orchestration::running_subagents::cancel_for_thread(&ctx, &request.thread_id);
let jobs = crate::core::runtime::slot_for::<
- tinyagents_orchestration::subagent::SubAgentJobRegistry,
+ tinyagents_harness_tools::subagents::SubAgentJobRegistry,
>(&ctx);
let cancelled_driver =
crate::agent::orchestration::subagent_sessions::cancel_driver_jobs_for_thread(