We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent a592849 commit 6f2d5a2Copy full SHA for 6f2d5a2
1 file changed
src/llm.rs
@@ -206,16 +206,13 @@ impl TryFrom<Vec<u8>> for LlmOptions {
206
.filter_map(|v| v.as_str().map(|s| s.to_string()))
207
.collect(),
208
)
209
- } else if let Some(s) = json["tools_sse_urls"].as_str() {
210
- // Handle comma-separated string format - Browser runtime
211
- Some(s.split(',').map(|s| s.trim().to_string()).collect())
212
} else {
213
- None
+ json["tools_sse_urls"].as_str().map(|s| s.split(',').map(|s| s.trim().to_string()).collect())
214
};
215
216
Ok(LlmOptions {
217
- system_message: system_message,
218
- tools_sse_urls: tools_sse_urls,
+ system_message,
+ tools_sse_urls,
219
temperature: json["temperature"].as_f32(),
220
top_p: json["top_p"].as_f32(),
221
})
0 commit comments