From 6acfea7787408d2dcf7d33411cf67af6dae26d57 Mon Sep 17 00:00:00 2001 From: Adil Hafeez Date: Tue, 8 Oct 2024 20:28:32 -0700 Subject: [PATCH] bug fix - send all parameter irrespective of type earlier we were only sending parameter if the type is string --- arch/src/stream_context.rs | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/arch/src/stream_context.rs b/arch/src/stream_context.rs index e80c824a..1979a183 100644 --- a/arch/src/stream_context.rs +++ b/arch/src/stream_context.rs @@ -697,10 +697,9 @@ impl StreamContext { let tool_params_dict: HashMap = match v.as_object() { Some(obj) => obj .iter() - .filter_map(|(key, value)| { - value - .as_str() - .map(|str_value| (key.clone(), str_value.to_string())) + .map(|(key, value)| { + // Convert each value to a string, regardless of its type + (key.clone(), value.to_string()) }) .collect(), None => HashMap::new(), // Return an empty HashMap if v is not an object