YC (S26) | Open Computer History | Continuously record your company computer work, map your workflows, help you find work worth automating, and power your agents' context
Rust agentsagiaiai-memoryaudio-recordingcomputer-visionhermeshermes-agentllmlocal-ailocal-firstmachine-learningmcpmultimodalopenclawprivacyrewindscreen-recordingspeech-to-textycombinator
fix(artifacts): case-insensitive search query (unbreaks test-ubuntu) (#4567)
Louis Beaumont48377ce4f45a
diff --git a/crates/screenpipe-engine/src/routes/artifacts.rs b/crates/screenpipe-engine/src/routes/artifacts.rsindex 3cac155a3..5e2fa1b43 100644--- a/crates/screenpipe-engine/src/routes/artifacts.rs+++ b/crates/screenpipe-engine/src/routes/artifacts.rs@@ -790,6 +790,13 @@ pub(crate) struct ArtifactListResponse {}fn artifact_matches_query(item: &ArtifactItem, q: &str) -> bool {+ // Case-insensitive on BOTH sides: lowercase the query too, not just the+ // fields. Without this, a query with any uppercase (e.g. "Weekly Summary")+ // never matches because the haystack is lowercased but the needle isn't —+ // case-sensitive artifact search. The HTTP caller already lowercases, so+ // this is defensive (and is what the unit tests rely on).+ let q = q.to_lowercase();+ let q = q.as_str();item.title.to_lowercase().contains(q)|| item.source.to_lowercase().contains(q)|| item.path.to_lowercase().contains(q)