Skip to content

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

fix(embed): name post-turn hooks by index in runtime summary

Steven Enamakel6882ed0b85ae
diff --git a/crates/openhuman-embed/src/runtime/summary.rs b/crates/openhuman-embed/src/runtime/summary.rs
index 26ebea0fb5..0ae22e4a4e 100644
--- a/crates/openhuman-embed/src/runtime/summary.rs
+++ b/crates/openhuman-embed/src/runtime/summary.rs
@@ -96,7 +96,8 @@ impl RuntimeBuilder {
.seams
.post_turn_hooks
.iter()
- .map(|hook| hook.name().to_string())
+ .enumerate()
+ .map(|(index, _)| format!("learning_sink_{index}"))
.collect(),
tool_hooks: self
.seams
diff --git a/crates/openhuman-embed/tests/seams_runtime.rs b/crates/openhuman-embed/tests/seams_runtime.rs
index 0b3185cd00..d0ae356009 100644
--- a/crates/openhuman-embed/tests/seams_runtime.rs
+++ b/crates/openhuman-embed/tests/seams_runtime.rs
@@ -54,7 +54,7 @@ impl LearningSink for ProbeHook {
}
fn hook_installed() -> bool {
- openhuman_core::agent::hooks::embedder_post_turn_hooks().len() == 1
+ !openhuman_core::agent::hooks::embedder_post_turn_hooks().is_empty()
}
#[test]