Skip to content

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

refactor(agent_chat): use shared inference params type for simple chat

Steven Enamakel55326812190f
diff --git a/crates/openhuman-core/src/agent_runs/agent_chat/controllers.rs b/crates/openhuman-core/src/agent_runs/agent_chat/controllers.rs
index 28ba45fd57..20afc84bdb 100644
--- a/crates/openhuman-core/src/agent_runs/agent_chat/controllers.rs
+++ b/crates/openhuman-core/src/agent_runs/agent_chat/controllers.rs
@@ -109,15 +109,15 @@ fn handle_agent_chat(ctx: crate::core::runtime::DispatchCtx, params: Map<String,
fn handle_agent_chat_simple(ctx: crate::core::runtime::DispatchCtx, params: Map<String, Value>) -> ControllerFuture {
Box::pin(async move {
- let params = deserialize_params::<AgentChatParams>(params)?;
+ let params = deserialize_params::<InferenceAgentChatParams>(params)?;
let config = ctx.load_config().await?;
crate::inference::host_runtime::ops::agent_chat_simple(
&ctx,
&config,
- &params.message,
- params.model_override,
- params.temperature,
- params.thread_id,
+ &params.common.message,
+ params.common.model_override,
+ params.common.temperature,
+ params.common.thread_id,
)
.await?
.into_cli_compatible_json()