Skip to content

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

chore: files changed src/openhuman/agent/harness/session/turn/mod.rs,src/openhuman/tools/toolpacks/m

Steven Enamakel848e269069d2
diff --git a/src/openhuman/agent/harness/session/turn/mod.rs b/src/openhuman/agent/harness/session/turn/mod.rs
index c7a0592f30..652877786f 100644
--- a/src/openhuman/agent/harness/session/turn/mod.rs
+++ b/src/openhuman/agent/harness/session/turn/mod.rs
@@ -31,19 +31,6 @@ const DIRECT_TOOL_NAMES: &[&str] = &[
/// When this pattern appears, rewrite it into a direct tool call so the turn
/// can proceed without a manual retry.
pub(super) fn normalize_tool_call<'a>(call: &'a ParsedToolCall) -> Cow<'a, ParsedToolCall> {
- // `load_skill` merged into `use_skill`: the pack index each carried in its
- // own description was one list charged twice, and splitting disclosure from
- // dispatch made the first call of any packed tool a mandatory round trip.
- // The retired name took the same `skill` argument the merged tool takes, so
- // rewrite it rather than spending the iteration on an unknown-tool error.
- if call.name == crate::openhuman::tools::toolpacks::LOAD_SKILL {
- log::warn!("[agent_loop] rewrote retired load_skill call into use_skill");
- return Cow::Owned(ParsedToolCall {
- name: crate::openhuman::tools::toolpacks::USE_SKILL.to_string(),
- arguments: call.arguments.clone(),
- tool_call_id: call.tool_call_id.clone(),
- });
- }
if call.name != "run_workflow" && call.name != "run_skill" {
return Cow::Borrowed(call);
}
diff --git a/src/openhuman/tools/toolpacks/mod.rs b/src/openhuman/tools/toolpacks/mod.rs
index 6a1795db89..615b232457 100644
--- a/src/openhuman/tools/toolpacks/mod.rs
+++ b/src/openhuman/tools/toolpacks/mod.rs
@@ -31,7 +31,7 @@ pub mod types;
pub use groups::{GroupMode, ToolGroups, GROUP_COUNT};
pub use ops::{append_pack_tools, bind_pack_registry, strip_packed_from_visible};
pub use registry::{all_packed_tool_names, pack, pack_for_tool, PACKS};
-pub use tools::{PackRegistryHandle, LOAD_SKILL, USE_SKILL};
+pub use tools::{PackRegistryHandle, USE_SKILL};
pub use types::ToolPack;
#[cfg(test)]
diff --git a/src/openhuman/tools/toolpacks/ops.rs b/src/openhuman/tools/toolpacks/ops.rs
index 7afb169823..398a1d469e 100644
--- a/src/openhuman/tools/toolpacks/ops.rs
+++ b/src/openhuman/tools/toolpacks/ops.rs
@@ -4,7 +4,7 @@ use std::collections::HashSet;
use std::sync::{Arc, Weak};
use super::registry;
-use super::tools::{PackRegistryHandle, UseSkillTool, LOAD_SKILL, USE_SKILL};
+use super::tools::{PackRegistryHandle, UseSkillTool, USE_SKILL};
use crate::openhuman::tools::traits::Tool;
/// Append `use_skill` to a freshly built registry.
@@ -52,12 +52,7 @@ pub fn bind_pack_registry(tools: &Arc<Vec<Box<dyn Tool>>>) {
/// A caller with an *empty* `visible` set means "everything is visible"
/// (the harness's historical sentinel), so there is nothing to subtract from
/// and the set is left alone.
-///
-/// [`LOAD_SKILL`] is inserted alongside [`USE_SKILL`] even though it is no
-/// longer a registered tool: the visible set is also what the tool-policy
-/// boundary is rendered from, and a model that emits the retired name reaches
-/// `use_skill` through `normalize_tool_call` only if the policy layer did not
-/// refuse it by name first.
+
pub fn strip_packed_from_visible(visible: &mut HashSet<String>, agent_id: &str) {
if visible.is_empty() {
return;
@@ -79,7 +74,6 @@ pub fn strip_packed_from_visible(visible: &mut HashSet<String>, agent_id: &str)
for name in &packed {
visible.remove(name);
}
- visible.insert(LOAD_SKILL.to_string());
visible.insert(USE_SKILL.to_string());
tracing::info!(
agent = %agent_id,
diff --git a/src/openhuman/tools/toolpacks/tools.rs b/src/openhuman/tools/toolpacks/tools.rs
index a1bbbd1ba8..153d23d2d3 100644
--- a/src/openhuman/tools/toolpacks/tools.rs
+++ b/src/openhuman/tools/toolpacks/tools.rs
@@ -9,13 +9,6 @@ use super::registry;
use crate::openhuman::tools::traits::{PermissionLevel, Tool, ToolCallOptions, ToolResult};
use tinytools::ToolRunContext;
-/// The retired name of the disclosure half, kept as a call-name alias.
-///
-/// `load_skill` and `use_skill` were separate tools, each rendering the whole
-/// pack index into its own description. They are one tool now, but a model
-/// that learned the old name still emits it, so `normalize_tool_call`
-/// rewrites such a call onto [`USE_SKILL`] rather than failing the turn.
-pub const LOAD_SKILL: &str = "load_skill";
pub const USE_SKILL: &str = "use_skill";
/// An `Arc`-shared, owned view of the tool registry a pack tool lives in.
@@ -158,9 +151,9 @@ fn named_tool(args: &Value) -> Option<&str> {
/// `use_skill` — until the pack index that each carried in its own description
/// made the pair spend 3.3 kB of every single turn saying one list twice, and
/// made the first call of any packed tool a mandatory two-call round trip.
-/// `load_skill` survives as a call-name alias (`normalize_tool_call` in
-/// `agent/harness/session/turn/mod.rs`), so a model that learned the old name
-/// still lands here.
+/// A model that learned the retired name gets the harness's "unknown tool"
+/// recovery result (#4249) and retries against the schema it can actually see,
+/// so no alias is carried for it.
///
/// **Permission forwarding is load-bearing.** The harness gates a call on the
/// tool's `permission_level_with_args`, so a proxy reporting its own level would