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: re-detect device tier when boundaries change, update store + UI accordingly
Louis Beaumont229904b20a69
diff --git a/apps/screenpipe-app-tauri/components/settings/ai-presets.tsx b/apps/screenpipe-app-tauri/components/settings/ai-presets.tsxindex ee93da347..6f74a57da 100644--- a/apps/screenpipe-app-tauri/components/settings/ai-presets.tsx+++ b/apps/screenpipe-app-tauri/components/settings/ai-presets.tsx@@ -896,7 +896,7 @@ const AISection = ({}case "anthropic": {- // Hardcoded model list — Claude Pro/Max subscription models+ // Hardcoded model list — Anthropic API modelssetModels([{ id: "claude-opus-4-6", name: "Claude Opus 4.6", provider: "anthropic" },{ id: "claude-sonnet-4-6", name: "Claude Sonnet 4.5", provider: "anthropic" },@@ -1083,7 +1083,7 @@ const AISection = ({<AIProviderCardtype="anthropic"title="Claude.ai"- description="Use your Claude Pro/Max subscription or Anthropic API key"+ description="Use your Anthropic API key"imageSrc="/images/claude-ai.svg"selected={(settingsPreset?.provider as string) === "anthropic"}onClick={() => {diff --git a/apps/screenpipe-app-tauri/components/settings/pipes-section.tsx b/apps/screenpipe-app-tauri/components/settings/pipes-section.tsxindex 9e04a530e..f1d89efdd 100644--- a/apps/screenpipe-app-tauri/components/settings/pipes-section.tsx+++ b/apps/screenpipe-app-tauri/components/settings/pipes-section.tsx@@ -1472,7 +1472,7 @@ export function PipesSection() {: pipe.config.schedule || "manual"}>{(pipe.config.trigger?.events?.length || 0) + (pipe.config.trigger?.custom?.length || 0) > 0- ? `⚡ ${(pipe.config.trigger?.events?.length || 0) + (pipe.config.trigger?.custom?.length || 0)} trigger${((pipe.config.trigger?.events?.length || 0) + (pipe.config.trigger?.custom?.length || 0)) > 1 ? "s" : ""}`+ ? `› ${(pipe.config.trigger?.events?.length || 0) + (pipe.config.trigger?.custom?.length || 0)} trigger${((pipe.config.trigger?.events?.length || 0) + (pipe.config.trigger?.custom?.length || 0)) > 1 ? "s" : ""}`: humanizeSchedule(pipe.config.schedule)}</span>@@ -1830,7 +1830,7 @@ export function PipesSection() {{/* Show built-in event triggers (from pipe.md frontmatter) */}{(pipe.config.trigger?.events || []).map((event: string, i: number) => (<div key={`ev-${i}`} className="flex items-center gap-1.5 group/item">- <span className="text-xs bg-muted/50 border px-3 py-1.5 flex-1 font-mono">⚡ {event.replace(/_/g, " ")}</span>+ <span className="text-xs bg-muted/50 border px-3 py-1.5 flex-1 font-mono">› {event.replace(/_/g, " ")}</span><button className="text-xs text-muted-foreground/0 group-hover/item:text-muted-foreground hover:!text-destructive transition-all duration-150" onClick={() => {const updated = (pipe.config.trigger?.events || []).filter((_: string, j: number) => j !== i);const newTrigger = { ...pipe.config.trigger, events: updated };@@ -1842,7 +1842,7 @@ export function PipesSection() {{/* Show custom plain-language triggers */}{(pipe.config.trigger?.custom || []).map((trigger: string, i: number) => (<div key={i} className="flex items-center gap-1.5 group/item">- <span className="text-xs bg-muted/50 px-2 py-1 rounded flex-1 font-mono">⚡ {trigger}</span>+ <span className="text-xs bg-muted/50 px-2 py-1 rounded flex-1 font-mono">› {trigger}</span><button className="text-xs text-muted-foreground/0 group-hover/item:text-muted-foreground hover:!text-destructive transition-all duration-150" onClick={() => {const updated = (pipe.config.trigger?.custom || []).filter((_: string, j: number) => j !== i);const newTrigger = { ...pipe.config.trigger, custom: updated };diff --git a/apps/screenpipe-app-tauri/src-tauri/Cargo.lock b/apps/screenpipe-app-tauri/src-tauri/Cargo.lockindex f1bf30b69..f2436e0ca 100644--- a/apps/screenpipe-app-tauri/src-tauri/Cargo.lock+++ b/apps/screenpipe-app-tauri/src-tauri/Cargo.lock@@ -9616,7 +9616,7 @@ dependencies = [[[package]]name = "screenpipe-app"-version = "2.2.267"+version = "2.2.270"dependencies = ["anyhow","arboard",@@ -9718,7 +9718,7 @@ dependencies = [[[package]]name = "screenpipe-audio"-version = "0.3.232"+version = "0.3.233"dependencies = ["anyhow","audiopipe",@@ -9773,7 +9773,7 @@ dependencies = [[[package]]name = "screenpipe-config"-version = "0.3.232"+version = "0.3.233"dependencies = ["dirs 6.0.0","serde",@@ -9785,7 +9785,7 @@ dependencies = [[[package]]name = "screenpipe-connect"-version = "0.3.232"+version = "0.3.233"dependencies = ["anyhow","async-trait",@@ -9811,7 +9811,7 @@ dependencies = [[[package]]name = "screenpipe-core"-version = "0.3.232"+version = "0.3.233"dependencies = ["accessibility","accessibility-sys",@@ -9855,7 +9855,7 @@ dependencies = [[[package]]name = "screenpipe-db"-version = "0.3.232"+version = "0.3.233"dependencies = ["anyhow","chrono",@@ -9880,7 +9880,7 @@ dependencies = [[[package]]name = "screenpipe-engine"-version = "0.3.232"+version = "0.3.233"dependencies = ["anyhow","async-trait",@@ -9943,7 +9943,7 @@ dependencies = [[[package]]name = "screenpipe-events"-version = "0.3.232"+version = "0.3.233"dependencies = ["anyhow","chrono",@@ -9959,7 +9959,7 @@ dependencies = [[[package]]name = "screenpipe-screen"-version = "0.3.232"+version = "0.3.233"dependencies = ["accessibility-sys","anyhow",@@ -9995,7 +9995,7 @@ dependencies = [[[package]]name = "screenpipe-vault"-version = "0.3.232"+version = "0.3.233"dependencies = ["argon2","chacha20poly1305",diff --git a/apps/screenpipe-app-tauri/src-tauri/src/store.rs b/apps/screenpipe-app-tauri/src-tauri/src/store.rsindex bd3832313..c9745476b 100644--- a/apps/screenpipe-app-tauri/src-tauri/src/store.rs+++ b/apps/screenpipe-app-tauri/src-tauri/src/store.rs@@ -737,18 +737,40 @@ pub fn init_store(app: &AppHandle) -> Result<SettingsStore, String> {}};- // One-time tier detection. Two cases:+ // Tier detection. Two cases:// - New install: detect tier AND apply tier defaults (video_quality, power_mode, etc.)// - Existing user upgrading: detect tier for DB/channel config but do NOT override// their existing capture settings (they may have customized video_quality etc.)- if store.recording.device_tier.is_none() {- let tier = screenpipe_config::detect_tier();- tracing::info!("detected hardware tier: {:?}", tier);- if is_new_store {- screenpipe_config::apply_tier_defaults(&mut store.recording, tier);+ // Also re-detect if the stored tier doesn't match current hardware classification+ // (e.g. tier boundaries changed in an update).+ {+ let detected = screenpipe_config::detect_tier();+ let stored_tier = store.recording.device_tier.as_deref()+ .and_then(screenpipe_config::DeviceTier::from_str_loose);+ if stored_tier != Some(detected) {+ tracing::info!(+ "hardware tier changed: {:?} -> {:?}",+ stored_tier, detected+ );+ if is_new_store || store.recording.device_tier.is_none() {+ screenpipe_config::apply_tier_defaults(&mut store.recording, detected);+ } else if stored_tier.is_some() {+ // Tier boundary changed in update — only fix engine if it would OOM+ // (user on parakeet/parakeet-mlx but now classified as Low)+ if detected == screenpipe_config::DeviceTier::Low+ && (store.recording.audio_transcription_engine == "parakeet"+ || store.recording.audio_transcription_engine == "parakeet-mlx")+ {+ tracing::warn!(+ "device reclassified as Low tier — switching from {} to whisper-tiny to prevent OOM",+ store.recording.audio_transcription_engine+ );+ store.recording.audio_transcription_engine = "whisper-tiny".to_string();+ }+ }+ store.recording.device_tier = Some(detected.as_str().to_string());+ should_save = true;}- store.recording.device_tier = Some(tier.as_str().to_string());- should_save = true;}// One-time migration: move default Haiku users to Qwen3.5 Flash