chore: remove broken googleSearch grounding and /v1/search endpoint

This commit is contained in:
Nikketryhard
2026-02-15 17:08:46 -06:00
parent cc5f48967a
commit afa96b88a5
5 changed files with 80 additions and 0 deletions

View File

@@ -68,6 +68,9 @@ pub struct StreamingAccumulator {
pub api_provider: Option<String>,
/// Captured function calls from Google's response.
pub function_calls: Vec<CapturedFunctionCall>,
/// Captured grounding metadata from Google Search grounding.
/// Contains search queries, web results, and citations.
pub grounding_metadata: Option<serde_json::Value>,
}
impl StreamingAccumulator {
@@ -137,6 +140,15 @@ impl StreamingAccumulator {
info!(finish_reason = reason, "MITM: non-STOP finish reason");
}
}
// Capture grounding metadata (Google Search grounding results)
if let Some(gm) = candidate.get("groundingMetadata") {
self.grounding_metadata = Some(gm.clone());
debug!(
has_search_queries = gm.get("searchEntryPoint").is_some(),
has_web_results = gm.get("groundingChunks").is_some(),
"MITM: captured grounding metadata"
);
}
}
}
self.api_provider = Some("google".to_string());