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
refactor(web3): move wallet tool registration into wallet module
Steven Enamakel676d8bbd7f1f
diff --git a/crates/openhuman-core/src/tools/mod.rs b/crates/openhuman-core/src/tools/mod.rsindex fd93e11c75..faf89a4252 100644--- a/crates/openhuman-core/src/tools/mod.rs+++ b/crates/openhuman-core/src/tools/mod.rs@@ -57,8 +57,6 @@ pub use crate::skills::search::SkillSearchTool;pub use crate::skills::tools::*;#[cfg(feature = "voice")]pub use crate::voice::audio_toolkit::tools::*;-#[cfg(feature = "web3")]-pub use crate::web3::wallet::tools::*;pub use implementations::*;pub use schemas::{all_controller_schemas as all_tools_controller_schemas,diff --git a/crates/openhuman-core/src/tools/ops.rs b/crates/openhuman-core/src/tools/ops.rsindex 4492bf7624..120572df8b 100644--- a/crates/openhuman-core/src/tools/ops.rs+++ b/crates/openhuman-core/src/tools/ops.rs@@ -309,23 +309,10 @@ pub fn all_tools_with_runtime(Box::new(FlowMemoryRecallTool::new()),#[cfg(feature = "flows")]Box::new(FlowMemoryRememberTool::new(security.clone())),- // Wallet tools — expose wallet operations to the agent tool-call pipeline- // so the crypto sub-agent can prepare transfers, check status, etc.- // Gated with the `web3` feature (the wallet domain is compiled out when- // web3 is disabled; the concrete tool types live in `tinywallet-web3`,- // re-exported under `wallet::tools`, and run over the process-wide engine).- #[cfg(feature = "web3")]- Box::new(WalletStatusTool::new(crate::web3::seams::engine())),- #[cfg(feature = "web3")]- Box::new(WalletChainStatusTool::new(crate::web3::seams::engine())),- #[cfg(feature = "web3")]- Box::new(WalletPrepareTransferTool::new(crate::web3::seams::engine())),- #[cfg(feature = "web3")]- Box::new(WalletTxStatusTool::new(crate::web3::seams::engine())),- #[cfg(feature = "web3")]- Box::new(WalletTxReceiptTool::new(crate::web3::seams::engine())),- #[cfg(feature = "web3")]- Box::new(WalletLookupTxTool::new(crate::web3::seams::engine())),+ ];+ #[cfg(feature = "web3")]+ tools.extend(crate::web3::wallet::registration::tools());+ tools.extend(vec![Box::new(ScheduleTool::new(security.clone(), root_config.clone())),Box::new(ProxyConfigTool::new(config.clone(), security.clone())),Box::new(UpdateCheckTool::new()),@@ -506,7 +493,7 @@ pub fn all_tools_with_runtime(Box::new(WorkspaceUpdatePersonaTool::new(config.clone())),Box::new(WorkspaceResetPersonaTool::new(config.clone())),Box::new(WorkspaceInitTool),- ];+ ]);// The single `memory` tool (recall | fetch | learn | forget), registered// only while memory is on: with no usable engine (signed out, no CortexDBdiff --git a/crates/openhuman-core/src/web3/wallet/mod.rs b/crates/openhuman-core/src/web3/wallet/mod.rsindex fc59a23cbc..dbf221ca7d 100644--- a/crates/openhuman-core/src/web3/wallet/mod.rs+++ b/crates/openhuman-core/src/web3/wallet/mod.rs@@ -47,10 +47,8 @@ pub(crate) mod rpc;#[cfg(feature = "web3")]mod schemas;-/// The wallet agent tools, re-exported from `tinywallet-web3`. The host builds-/// them over the process-wide engine in `tools/ops.rs`.#[cfg(feature = "web3")]-pub mod tools;+pub(crate) mod registration;/// The host side of the wallet primitives' `Transport` seam — endpoint resolution,/// failover and redaction stay here, where the config lives.#[cfg(feature = "web3")]diff --git a/crates/openhuman-core/src/web3/wallet/registration.rs b/crates/openhuman-core/src/web3/wallet/registration.rsnew file mode 100644index 0000000000..19d71ac9cc--- /dev/null+++ b/crates/openhuman-core/src/web3/wallet/registration.rs@@ -0,0 +1,19 @@+//! Host registration of wallet tools over the configured wallet engine.++use tinytools::Tool;+use tinywallet_web3::tools::wallet::{+ WalletChainStatusTool, WalletLookupTxTool, WalletPrepareTransferTool,+ WalletStatusTool, WalletTxReceiptTool, WalletTxStatusTool,+};++/// Build the wallet tool family in its persisted catalogue order.+pub(crate) fn tools() -> Vec<Box<dyn Tool>> {+ vec![+ Box::new(WalletStatusTool::new(crate::web3::seams::engine())),+ Box::new(WalletChainStatusTool::new(crate::web3::seams::engine())),+ Box::new(WalletPrepareTransferTool::new(crate::web3::seams::engine())),+ Box::new(WalletTxStatusTool::new(crate::web3::seams::engine())),+ Box::new(WalletTxReceiptTool::new(crate::web3::seams::engine())),+ Box::new(WalletLookupTxTool::new(crate::web3::seams::engine())),+ ]+}diff --git a/crates/openhuman-core/src/web3/wallet/tools.rs b/crates/openhuman-core/src/web3/wallet/tools.rsdeleted file mode 100644index b3bb311c08..0000000000--- a/crates/openhuman-core/src/web3/wallet/tools.rs+++ /dev/null@@ -1,8 +0,0 @@-//! The wallet agent tools.-//!-//! The tools live in `tinywallet_web3::tools::wallet`; they are re-exported here-//! so `tools/mod.rs` keeps exposing them under their historical path. Each is-//! built over the process-wide wallet engine-//! ([`crate::web3::seams::engine`]) at registration in `tools/ops.rs`.--pub use tinywallet_web3::tools::wallet::*;