Skip to content

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

refactor(orchestration): remove unused skill delegation tool

Steven Enamakel09729c437554
diff --git a/crates/openhuman-core/src/agent/orchestration/tools.rs b/crates/openhuman-core/src/agent/orchestration/tools.rs
index a69e29af82..a5cad62ba5 100644
--- a/crates/openhuman-core/src/agent/orchestration/tools.rs
+++ b/crates/openhuman-core/src/agent/orchestration/tools.rs
@@ -8,8 +8,7 @@
//! - **Control**: `steer_subagent`, `continue_subagent`, `close_subagent`,
//! `wait_subagent`, `wait` / `wait_loop`, `list_subagents`.
//! - **Delegation**: `DelegateGraphTool`, `ArchetypeDelegationTool`,
-//! `SkillDelegationTool`, `CollapsedDelegationTool` (`delegate_to`), and
-//! `agent_prepare_context`.
+//! `CollapsedDelegationTool` (`delegate_to`), and `agent_prepare_context`.
//!
//! `dispatch.rs`, `awaiting_user.rs`, and `worker_thread.rs` are `pub(crate)`
//! helpers shared by the tools above (the common spawn path, the awaiting-user
@@ -39,8 +38,6 @@ mod delegate_graph;
mod dispatch;
#[path = "tools/list_subagents.rs"]
mod list_subagents;
-#[path = "tools/skill_delegation.rs"]
-mod skill_delegation;
#[path = "tools/spawn_async_subagent.rs"]
mod spawn_async_subagent;
#[path = "tools/spawn_parallel_agents.rs"]
@@ -94,7 +91,6 @@ pub(crate) use delegate_graph::DelegateGraphDispatch;
pub use delegate_graph::DelegateGraphTool;
pub(crate) use list_subagents::ListSubagentsDispatch;
pub use list_subagents::ListSubagentsTool;
-pub use skill_delegation::{SkillDelegationTool, INTEGRATIONS_DELEGATE_TOOL_NAME};
pub(crate) use spawn_async_subagent::SpawnAsyncSubagentDispatch;
pub use spawn_async_subagent::{scope_spawn_async_subagent_spec, SpawnAsyncSubagentTool};
pub(crate) use spawn_parallel_agents::SpawnParallelAgentsDispatch;
diff --git a/crates/openhuman-core/src/agent/orchestration/tools/dispatch.rs b/crates/openhuman-core/src/agent/orchestration/tools/dispatch.rs
index 354d72d84d..0757411768 100644
--- a/crates/openhuman-core/src/agent/orchestration/tools/dispatch.rs
+++ b/crates/openhuman-core/src/agent/orchestration/tools/dispatch.rs
@@ -30,9 +30,6 @@ enum DelegationDispatchKind {
Collapsed {
targets: Result<Vec<super::collapsed_delegation::DelegateTarget>, String>,
},
- Integrations {
- connected_toolkits: Vec<String>,
- },
Archetype,
}
@@ -46,17 +43,6 @@ impl DelegationDispatch {
),
}
}
- super::skill_delegation::INTEGRATIONS_DELEGATE_TOOL_NAME => {
- let connected_toolkits = tool
- .parameters_schema()
- .pointer("/properties/toolkit/enum")
- .and_then(serde_json::Value::as_array)
- .into_iter()
- .flatten()
- .filter_map(|value| value.as_str().map(str::to_owned))
- .collect();
- DelegationDispatchKind::Integrations { connected_toolkits }
- }
// Only synthesized archetype delegate names enter this path.
// `delegate_graph` is a concrete durable graph tool with its own
// typed dispatcher, and arbitrary `delegate_*` tools must not be
@@ -114,22 +100,6 @@ impl ToolDispatch<(), crate::agent::tinyagents::host::OpenHumanRunContext> for D
)
.await
}
- DelegationDispatchKind::Integrations { connected_toolkits } => {
- let connected_toolkits: Vec<(String, String)> = connected_toolkits
- .iter()
- .cloned()
- .map(|slug| (slug, String::new()))
- .collect();
- super::skill_delegation::execute_skill_delegation_with_live_parent(
- self.tool.name(),
- &connected_toolkits,
- arguments,
- Some(&tool_context),
- child,
- Some(parent),
- )
- .await
- }
DelegationDispatchKind::Archetype => {
let Some(agent_id) = AgentDefinitionRegistry::global().and_then(|registry| {
registry.list().into_iter().find_map(|definition| {
@@ -418,16 +388,11 @@ pub(crate) async fn dispatch_subagent_with_live_parent(
prompt.chars().count()
);
- // Propagate the per-call toolkit scope into the subagent runner so
- // that the collapsed `SkillDelegationTool` can narrow
- // `integrations_agent` to a single Composio toolkit (e.g.
- // `delegate_to_integrations_agent { toolkit: "gmail" }` →
- // integrations_agent + toolkit="gmail"). Earlier code plumbed this through
- // `skill_filter_override` (which matches `{skill}__` QuickJS-style
- // names), but Composio actions are named `GMAIL_*` / `NOTION_*` —
- // so the filter excluded every Composio tool instead of narrowing
- // them. `toolkit_override` applies the correct `{TOOLKIT}_` prefix
- // check, restricted to skill-category tools.
+ // Propagate a per-call toolkit scope into the subagent runner as
+ // `toolkit_override` (the `{TOOLKIT}_` prefix check on skill-category
+ // tools), never as `skill_filter_override` (which matches `{skill}__`
+ // QuickJS-style names and would exclude every Composio action). The
+ // delegation tools synthesised today all pass `None` here.
let worktree_action_dir = parent_workspace_descriptor
.as_ref()
.map(|descriptor| descriptor.root.clone());