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: files changed src/core/agent_cli.rs,src/openhuman/agent/debug/wire_tests.rs,src/openhuman/age
Steven Enamakel83b161e49918
diff --git a/src/core/agent_cli.rs b/src/core/agent_cli.rsindex 8f27d4ec89..06398f26c3 100644--- a/src/core/agent_cli.rs+++ b/src/core/agent_cli.rs@@ -501,7 +501,10 @@ fn run_dump_prompt(args: &[String]) -> Result<()> {// and splitting the header onto stderr the way `print_human` does// would make `> turn.txt` drop the byte counts that give the payload// its meaning.- print!("{}", crate::openhuman::agent::debug::render_wire_dump(&dumped));+ print!(+ "{}",+ crate::openhuman::agent::debug::render_wire_dump(&dumped)+ );} else if flags.json {print_json(&dumped, flags.with_tools)?;} else {@@ -735,12 +738,14 @@ fn print_dump_prompt_help() {println!(" Config::workspace_dir / ~/.openhuman/workspace).");println!(" --model, -m <name> Override the resolved model name (affects only the");println!(" `## Runtime` section).");- println!(" --with-tools Also print the full list of tool names the agent sees.+ println!(+ " --with-tools Also print the full list of tool names the agent sees.--wire Print the ENTIRE fixed prefix exactly as the modelreceives it: the system prompt verbatim, then everyadvertised tool schema minified the way it is sent,with byte counts for each half. This is the whole- per-turn cost in one document.");+ per-turn cost in one document."+ );println!(" --json Emit a machine-readable JSON object on stdout.");println!(" -v, --verbose Enable debug logging on stderr.");println!();diff --git a/src/openhuman/agent/debug/wire_tests.rs b/src/openhuman/agent/debug/wire_tests.rsindex 5ea551a1d5..3bd7e1264a 100644--- a/src/openhuman/agent/debug/wire_tests.rs+++ b/src/openhuman/agent/debug/wire_tests.rs@@ -74,7 +74,10 @@ fn the_header_totals_the_two_halves() {let expected = 10 + serde_json::to_string(&s).unwrap().len();let rendered = render(&d);- assert_eq!(total_tool_bytes(&d), serde_json::to_string(&s).unwrap().len());+ assert_eq!(+ total_tool_bytes(&d),+ serde_json::to_string(&s).unwrap().len()+ );assert!(rendered.contains(&thousands(expected)),"header must report prompt + tools as one figure ({expected})"diff --git a/src/openhuman/agent/harness/session/builder/builder_tests.rs b/src/openhuman/agent/harness/session/builder/builder_tests.rsindex 4d75765f86..6b0e0c55aa 100644--- a/src/openhuman/agent/harness/session/builder/builder_tests.rs+++ b/src/openhuman/agent/harness/session/builder/builder_tests.rs@@ -806,7 +806,9 @@ async fn an_empty_named_scope_advertises_no_tools_at_all() {// Tolerant of an already-initialised singleton: this binary shares one// `OnceLock` across every test, so whether we are first is a property of// test ordering, not of this test.- let _ = crate::openhuman::agent::harness::definition::AgentDefinitionRegistry::init_global_builtins();+ let _ =+ crate::openhuman::agent::harness::definition::AgentDefinitionRegistry::init_global_builtins(+ );let tmp = tempfile::TempDir::new().unwrap();let config = test_config(&tmp);@@ -816,9 +818,7 @@ async fn an_empty_named_scope_advertises_no_tools_at_all() {let visible = agent.visible_tool_names_for_test();let real: Vec<&String> = visible.iter()- .filter(|n| {- n.as_str() != crate::openhuman::agent::harness::definition::NO_TOOLS_SENTINEL- })+ .filter(|n| n.as_str() != crate::openhuman::agent::harness::definition::NO_TOOLS_SENTINEL).collect();assert!(real.is_empty(),@@ -840,7 +840,9 @@ async fn a_zero_tool_agent_does_not_gain_the_compaction_recovery_tool() {// Tolerant of an already-initialised singleton: this binary shares one// `OnceLock` across every test, so whether we are first is a property of// test ordering, not of this test.- let _ = crate::openhuman::agent::harness::definition::AgentDefinitionRegistry::init_global_builtins();+ let _ =+ crate::openhuman::agent::harness::definition::AgentDefinitionRegistry::init_global_builtins(+ );let tmp = tempfile::TempDir::new().unwrap();let config = test_config(&tmp);@@ -848,7 +850,9 @@ async fn a_zero_tool_agent_does_not_gain_the_compaction_recovery_tool() {.expect("trigger_triage is a shipped agent definition");assert!(- !agent.visible_tool_names_for_test().contains(RETRIEVE_TOOL_NAME),+ !agent+ .visible_tool_names_for_test()+ .contains(RETRIEVE_TOOL_NAME),"a deliberately tool-less agent must not be handed the recovery tool");}@@ -865,9 +869,7 @@ fn the_no_tools_sentinel_can_never_name_a_real_tool() {#[test]fn is_empty_tool_scope_distinguishes_the_three_states() {- use crate::openhuman::agent::harness::definition::{- is_empty_tool_scope, NO_TOOLS_SENTINEL,- };+ use crate::openhuman::agent::harness::definition::{is_empty_tool_scope, NO_TOOLS_SENTINEL};use std::collections::HashSet;// Unset — the historical "everything" sentinel.diff --git a/src/openhuman/agent/harness/session/builder/factory.rs b/src/openhuman/agent/harness/session/builder/factory.rsindex 28e50903b3..8f15d28cfb 100644--- a/src/openhuman/agent/harness/session/builder/factory.rs+++ b/src/openhuman/agent/harness/session/builder/factory.rs@@ -3,11 +3,11 @@use super::helpers::prefetch_tool_memory_rules_blocking;use super::should_synthesize_delegation_tools;-use crate::openhuman::agent::harness::definition::NO_TOOLS_SENTINEL;use crate::openhuman::agent::context::prompt::SystemPromptBuilder;use crate::openhuman::agent::dispatcher::{NativeToolDispatcher, PFormatToolDispatcher, XmlToolDispatcher,};+use crate::openhuman::agent::harness::definition::NO_TOOLS_SENTINEL;use crate::openhuman::agent::harness::definition::{AgentDefinitionRegistry, PromptSource, ToolScope,};