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/harness/host_definition.rs,crates/openhuman-cor

Steven Enamakela5b5a6c5c3ce
diff --git a/crates/openhuman-core/src/agent/harness/host_definition.rs b/crates/openhuman-core/src/agent/harness/host_definition.rs
index 932600d026..9d3f76bd8a 100644
--- a/crates/openhuman-core/src/agent/harness/host_definition.rs
+++ b/crates/openhuman-core/src/agent/harness/host_definition.rs
@@ -165,7 +165,17 @@ impl AgentDefinitionRegistry {
/// Build a registry containing only the built-in definitions.
pub fn builtins_only() -> Self {
let mut reg = Self::default();
- for def in super::builtin_definitions::all() {
+ for def in crate::agent::registry::agents::load_builtins()
+ .expect("built-in agent TOML must always parse")
+ {
+ reg.insert(def);
+ }
+ #[cfg(test)]
+ for def in [
+ super::test_support::test_main_def(),
+ super::test_support::test_inherit_echo_def(),
+ super::test_support::test_inherit_parallel_worker_def(),
+ ] {
reg.insert(def);
}
reg
diff --git a/crates/openhuman-core/src/agent/harness/mod.rs b/crates/openhuman-core/src/agent/harness/mod.rs
index 9e13b0a67d..763e02ecf7 100644
--- a/crates/openhuman-core/src/agent/harness/mod.rs
+++ b/crates/openhuman-core/src/agent/harness/mod.rs
@@ -21,7 +21,8 @@
//! `crate::agent::tinyagents`); there is no in-house interrupt fence.
pub mod artifact_offload;
-pub(crate) mod builtin_definitions;
+#[cfg(test)]
+pub(crate) mod test_support;
pub mod fork_context;
pub(crate) mod graph;
pub mod host_definition;
diff --git a/crates/openhuman-core/src/inference/host_runtime/ops/agent_chat_tests.rs b/crates/openhuman-core/src/inference/host_runtime/ops/agent_chat_tests.rs
index 1718acc5b3..efd820a4fd 100644
--- a/crates/openhuman-core/src/inference/host_runtime/ops/agent_chat_tests.rs
+++ b/crates/openhuman-core/src/inference/host_runtime/ops/agent_chat_tests.rs
@@ -71,7 +71,7 @@ fn the_outcome_keeps_its_historical_shape() {
#[test]
fn explicit_turn_temperature_overrides_the_definition_without_mutating_it() {
- let mut definition = crate::agent::harness::builtin_definitions::test_main_def();
+ let mut definition = crate::agent::harness::test_support::test_main_def();
definition.temperature = 0.6;
let effective = definition_for_turn(&definition, Some(0.9));
assert_eq!(effective.temperature, 0.9);
diff --git a/crates/openhuman-core/src/tools/rules/ops_tests.rs b/crates/openhuman-core/src/tools/rules/ops_tests.rs
index f489669bcc..6fcc2c7666 100644
--- a/crates/openhuman-core/src/tools/rules/ops_tests.rs
+++ b/crates/openhuman-core/src/tools/rules/ops_tests.rs
@@ -9,7 +9,7 @@ use tinytools::ToolRuleSet;
use tinytools::{Surface, ToolSubject};
fn definition(id: &str) -> AgentDefinition {
- crate::agent::harness::builtin_definitions::all()
+ crate::agent::registry::agents::load_builtins().expect("built-ins load")
.into_iter()
.next()
.map(|mut def| {