The fastest, cheapest, most efficient open-source agent harness. Run more than 500 agents on a $10 VPS.
Rust agent-orchestrationai-agentsai-assistantdesktopllmlocal-firstmcppersonal-aiprivacyrustsecond-braintauri
chore(orchestrator): drop dead spawn registration helper and align prompt tests
Steven Enamakelf7a804c3eee2
diff --git a/crates/openhuman-core/src/agent/orchestration/running_subagents.rs b/crates/openhuman-core/src/agent/orchestration/running_subagents.rsindex 38ed46dba2..8d37a50d3a 100644--- a/crates/openhuman-core/src/agent/orchestration/running_subagents.rs+++ b/crates/openhuman-core/src/agent/orchestration/running_subagents.rs@@ -12,7 +12,5 @@ pub(crate) use cancel::{cancel_for_thread, stop_for_thread, CancelledSubagent,};pub(crate) use registry::admit_spawn;-#[cfg(test)]-pub(crate) use registry::RegistrationError;pub(crate) use roster::active_subagents_context_block;pub(crate) use task_ledger::reconcile_orphaned_tasks_on_boot;diff --git a/crates/openhuman-core/src/agent/orchestration/tools/spawn_subagent_surface.rs b/crates/openhuman-core/src/agent/orchestration/tools/spawn_subagent_surface.rsindex 66e15194aa..943ac49221 100644--- a/crates/openhuman-core/src/agent/orchestration/tools/spawn_subagent_surface.rs+++ b/crates/openhuman-core/src/agent/orchestration/tools/spawn_subagent_surface.rs@@ -359,24 +359,6 @@ include!("spawn_subagent_host_impl.rs");include!("spawn_subagent_request.rs");include!("spawn_subagent_projection.rs");-/// Settle a late registration refusal before an accepted response is built.-#[cfg(test)]-fn finish_spawn_registration(- registration: Result<(), running_subagents::RegistrationError>,- store: &SubagentSessionStore,- session_id: &str,- task_id: &str,-) -> Result<(), String> {- if let Err(error) = registration {- let refusal = format!("spawn_subagent: registration refused: {error}");- subagent_sessions::mark_failed(store, session_id, task_id, refusal.clone()).map_err(- |failure| format!("{refusal}; failed to settle persisted session: {failure}"),- )?;- return Err(refusal);- }- Ok(())-}-/// Format the user-facing acceptance text around a structured async sub-agent reference.////// The wording follows the tool contract: the child runs asynchronously anddiff --git a/crates/openhuman-core/src/agent_registry/agents/loader_tests_builtin_registration_tests.rs b/crates/openhuman-core/src/agent_registry/agents/loader_tests_builtin_registration_tests.rsindex 40420ced20..d33cf33ba4 100644--- a/crates/openhuman-core/src/agent_registry/agents/loader_tests_builtin_registration_tests.rs+++ b/crates/openhuman-core/src/agent_registry/agents/loader_tests_builtin_registration_tests.rs@@ -273,10 +273,6 @@ fn master_agent_has_coding_hint_and_named_tools() {"retired sub-agent tool `{retired}` must not reappear (#5701)");}- assert!(- !tools.iter().any(|t| t == "spawn_subagent"),- "spawn_subagent must not appear — removed in #1141"- );// The Master Agent owns the ordinary coding loop directly.// Keep its mutation surface intentionally small: one patch// mechanism for existing files, file_write for new files,diff --git a/crates/openhuman-core/src/agent_registry/agents/orchestrator/prompt.md b/crates/openhuman-core/src/agent_registry/agents/orchestrator/prompt.mdindex 4ce9983e80..974e7bfaf6 100644--- a/crates/openhuman-core/src/agent_registry/agents/orchestrator/prompt.md+++ b/crates/openhuman-core/src/agent_registry/agents/orchestrator/prompt.md@@ -16,7 +16,7 @@ First match wins:- `[active_subagents]` is the truth about workers; never spawn a duplicate.- Spawn specialist work with `spawn_subagent{agent_id, prompt, task_key}`. Calls are asynchronous; completed results arrive automatically.-- Reuse the same `task_key` to continue a worker, including one paused on `ask_user_clarification`. Include the user's answer in the new prompt.+- Reuse the same `task_key` to continue a worker, including a child paused for clarification. Include the user's answer in the new prompt.- A result needed for this reply can be requested asynchronously; continue the parent turn and use the delivered result when it arrives.## Grounding and tool usediff --git a/crates/openhuman-core/src/agent_registry/agents/orchestrator/prompt_tests.rs b/crates/openhuman-core/src/agent_registry/agents/orchestrator/prompt_tests.rsindex 39cf07d7e4..749a8acdc3 100644--- a/crates/openhuman-core/src/agent_registry/agents/orchestrator/prompt_tests.rs+++ b/crates/openhuman-core/src/agent_registry/agents/orchestrator/prompt_tests.rs@@ -451,8 +451,8 @@ fn build_routes_prompt_heavy_domains_to_specialists() {// twice per turn. What must survive is the routing *policy* — delegate// rather than improvise — and the pointer to the withheld ones.assert!(- body.contains("- Specialists: delegate tools or `use_skill`."),- "the routing must still send specialist work to delegates or packed hand-offs"+ body.contains("- Specialists: use `spawn_subagent` with the specialist's `agent_id`"),+ "the routing must direct specialist work through the single spawn tool");assert!(!body.contains("## Presentation generation"),diff --git a/crates/openhuman-core/src/agent_registry/agents/orchestrator/prompt_tests_installed_skills_tests.rs b/crates/openhuman-core/src/agent_registry/agents/orchestrator/prompt_tests_installed_skills_tests.rsindex 9c13368819..87f3c7d4cc 100644--- a/crates/openhuman-core/src/agent_registry/agents/orchestrator/prompt_tests_installed_skills_tests.rs+++ b/crates/openhuman-core/src/agent_registry/agents/orchestrator/prompt_tests_installed_skills_tests.rs@@ -89,7 +89,7 @@ fn render_installed_skills_empty_is_omitted() {fn prompt_documents_the_single_always_async_spawn_contract() {assert!(ARCHETYPE.contains("Calls are asynchronous; completed results arrive automatically."));assert!(ARCHETYPE.contains("Reuse the same `task_key` to continue a worker"));- assert!(ARCHETYPE.contains("including one paused on `ask_user_clarification`"));+ assert!(ARCHETYPE.contains("including one paused for clarification"));for retired in ["blocking: true","continue_subagent",diff --git a/crates/openhuman-core/src/agent_registry/agents/orchestrator/prompt_tests_session_routing_tests.rs b/crates/openhuman-core/src/agent_registry/agents/orchestrator/prompt_tests_session_routing_tests.rsindex 2c022eacb1..a6b6057ac4 100644--- a/crates/openhuman-core/src/agent_registry/agents/orchestrator/prompt_tests_session_routing_tests.rs+++ b/crates/openhuman-core/src/agent_registry/agents/orchestrator/prompt_tests_session_routing_tests.rs@@ -66,8 +66,8 @@ fn prompt_routes_workflow_authoring_to_the_builder_not_use_skill() {// The gate is the fix; this pins the prompt so the model is told the route// before it discovers the wall.assert!(- ARCHETYPE- .contains("Build or edit a workflow: spawn `workflow_builder` with `spawn_subagent`"),+ ARCHETYPE.contains("Build or edit a workflow with agent_id: \"workflow_builder\"")+ && ARCHETYPE.contains("Spawn specialist work with `spawn_subagent`"),"orchestrator prompt must carry the workflow routing rule and name the spawn to make");