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
test(memory): add test to dump tool contracts for inspection
Steven Enamakel58edccbc402b
diff --git a/crates/openhuman-core/src/memory/tools/search/mod.rs b/crates/openhuman-core/src/memory/tools/search/mod.rsindex 5c308b076c..c9c5f3bb45 100644--- a/crates/openhuman-core/src/memory/tools/search/mod.rs+++ b/crates/openhuman-core/src/memory/tools/search/mod.rs@@ -25,3 +25,45 @@ pub use crate::memory::query::{MemoryTreeDrillDownTool, MemoryTreeFetchLeavesTool, MemoryTreeIngestDocumentTool,MemoryTreeQuerySourceTool, MemoryTreeSearchEntitiesTool,};++#[cfg(test)]+mod zz_dump_contracts {+ use tinytools::Tool;+ #[test]+ fn dump_contracts() {+ let tools: Vec<Box<dyn Tool>> = vec![+ Box::new(super::MemoryChunkContextTool),+ Box::new(super::MemoryHybridSearchTool),+ Box::new(super::MemoryVectorSearchTool),+ Box::new(super::MemoryStoreKindsTool),+ Box::new(super::MemoryStoreRawChunksTool),+ Box::new(super::MemoryStoreRawSearchTool),+ Box::new(crate::memory::tools::tool_memory::MemoryToolsListTool),+ Box::new(crate::memory::tools::tool_memory::MemoryToolsPutTool),+ Box::new(super::MemoryTreeDrillDownTool),+ Box::new(super::MemoryTreeFetchLeavesTool),+ Box::new(super::MemoryTreeQuerySourceTool),+ Box::new(super::MemoryTreeSearchEntitiesTool),+ Box::new(crate::memory::query::MemoryTreeCoverWindowTool),+ Box::new(crate::memory::query::MemoryTreeTool),+ ];+ let mut out = serde_json::Map::new();+ for t in tools {+ out.insert(+ t.name().to_string(),+ serde_json::json!({+ "name": t.name(),+ "description": t.description(),+ "parameters_schema": t.parameters_schema(),+ "exposure": format!("{:?}", t.exposure()),+ "permission_level": format!("{:?}", t.permission_level()),+ }),+ );+ }+ std::fs::write(+ "/tmp/claude-1000/-home-enamakel-work-openhuman/9e4bbe5d-dfd3-4283-bb6a-e34995c22b9c/scratchpad/tool_contracts.json",+ serde_json::to_string_pretty(&serde_json::Value::Object(out)).unwrap(),+ )+ .unwrap();+ }+}