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(core): remove channel context block builder
Steven Enamakel57006ac7fa4b
diff --git a/crates/openhuman-core/src/channels/runtime/dispatch/helpers.rs b/crates/openhuman-core/src/channels/runtime/dispatch/helpers.rsindex 4704a5d869..545325ac73 100644--- a/crates/openhuman-core/src/channels/runtime/dispatch/helpers.rs+++ b/crates/openhuman-core/src/channels/runtime/dispatch/helpers.rs@@ -53,60 +53,6 @@ pub(super) fn spawn_typing_task(})}-/// Build the `[Channel context]` block for a channel turn.-pub(super) fn build_channel_context_block(msg: &traits::ChannelMessage) -> String {- tokio_util::task::AbortOnDropHandle::new(tokio::spawn(async move {- let mut accumulated = String::new();- let mut last_thinking_update = None;- const THINKING_UPDATE_INTERVAL_MS: u128 = 2000;-- while let Some(progress) = progress.recv().await {- match progress {- AgentProgress::TextDelta { delta, .. } => {- accumulated.push_str(&delta);- if let Err(error) = channel- .update_draft(&reply_target, &draft_id, &accumulated)- .await- {- tracing::debug!("Draft update failed: {error}");- }- }- AgentProgress::ThinkingDelta { .. } => {- if accumulated.is_empty() {- let now = std::time::Instant::now();- let should_update = match last_thinking_update {- None => true,- Some(last) => {- now.duration_since(last).as_millis() > THINKING_UPDATE_INTERVAL_MS- }- };-- if should_update {- if let Err(error) = channel- .update_draft(&reply_target, &draft_id, "Thinking...")- .await- {- tracing::debug!("Thinking update failed: {error}");- }- last_thinking_update = Some(now);- }- }- }- AgentProgress::ToolCallStarted { tool_name, .. } if accumulated.is_empty() => {- let _ = channel- .update_draft(- &reply_target,- &draft_id,- &format!("Working ({tool_name})..."),- )- .await;- }- _ => {}- }- }- }))-}-/// Build the `[Channel context]` block for a channel turn.////// Reminders and scheduled tasks created from this chat are delivered back to