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(inference): update cloud provider factory with new options
Steven Enamakela63d05f909ed
diff --git a/crates/openhuman-core/src/inference/provider/factory/cloud_spec.rs b/crates/openhuman-core/src/inference/provider/factory/cloud_spec.rsindex df97fd5dce..b94a384f4b 100644--- a/crates/openhuman-core/src/inference/provider/factory/cloud_spec.rs+++ b/crates/openhuman-core/src/inference/provider/factory/cloud_spec.rs@@ -3,7 +3,7 @@use super::*;use tinyinference_llm::providers::openai::codex::OpenAiCodexRouting;use tinyinference_llm::providers::registry::{- CredentialResolver, ProviderBuildOptions, ProviderRegistry,+ CredentialResolver, ProviderBuildOptions, ProviderHttpClientBuilder, ProviderRegistry,};use tinyinference_llm::{ProviderKind, ProviderSpec};@@ -57,6 +57,8 @@ pub(super) fn build_cloud_model(user_agent: Option<&str>,codex: Option<&OpenAiCodexRouting>,http: Option<reqwest::Client>,+ http_builder: Option<ProviderHttpClientBuilder<'_>>,+ ca_bundle: Option<&str>,) -> anyhow::Result<Arc<dyn ChatModel<()>>> {log::debug!("[providers][cloud-spec] build slug={} kind={} auth={:?}",@@ -77,6 +79,8 @@ pub(super) fn build_cloud_model(user_agent,codex,http,+ http_builder,+ ca_bundle,..ProviderBuildOptions::default()},)diff --git a/crates/openhuman-core/src/inference/provider/factory/cloud_spec_tests.rs b/crates/openhuman-core/src/inference/provider/factory/cloud_spec_tests.rsindex 34ca5a9ebf..85ebba3c7e 100644--- a/crates/openhuman-core/src/inference/provider/factory/cloud_spec_tests.rs+++ b/crates/openhuman-core/src/inference/provider/factory/cloud_spec_tests.rs@@ -24,6 +24,8 @@ fn build(entry: &CloudProviderCreds, model: &str, key: &str) {None,None,None,+ None,+ None,).unwrap_or_else(|error| panic!("{} failed to build: {error}", entry.slug));}diff --git a/crates/openhuman-core/src/inference/provider/factory/credentials.rs b/crates/openhuman-core/src/inference/provider/factory/credentials.rsindex 36d1c4bd05..7ed2362cb7 100644--- a/crates/openhuman-core/src/inference/provider/factory/credentials.rs+++ b/crates/openhuman-core/src/inference/provider/factory/credentials.rs@@ -161,18 +161,3 @@ pub fn lookup_key_for_slug(slug: &str, config: &Config) -> anyhow::Result<StringOk(String::new())}-/// Return a safe-to-log representation of a URL endpoint: `scheme://host` only.-pub fn redact_endpoint(url: &str) -> String {- let trimmed = url.trim();- if let Some(rest) = trimmed.split_once("://") {- let scheme = rest.0;- let authority = rest.1.split('/').next().unwrap_or("");- if authority.contains('@') {- return "<redacted>".to_string();- }- let host = authority;- let host_no_query = host.split('?').next().unwrap_or(host);- return format!("{}://{}", scheme, host_no_query);- }- "<endpoint>".to_string()-}