Skip to content

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

fix: bump High tier to ≥24GB, Mid/Low use whisper-tiny

Louis Beaumont6b4fa55361f3
diff --git a/crates/screenpipe-config/src/defaults.rs b/crates/screenpipe-config/src/defaults.rs
index 6f1ae8556..fe55d5298 100644
--- a/crates/screenpipe-config/src/defaults.rs
+++ b/crates/screenpipe-config/src/defaults.rs
@@ -16,7 +16,7 @@ const PARAKEET_MIN_MACOS_MAJOR: u32 = 26;
/// Used to select conservative or aggressive default settings on first launch.
#[derive(Clone, Copy, Debug, PartialEq, Eq)]
pub enum DeviceTier {
- /// High-end: ≥16 GB RAM and ≥8 cores
+ /// High-end: ≥24 GB RAM and ≥8 cores (safe for parakeet ~2GB)
High,
/// Mid-range: ≥12 GB or (≥8 GB and ≥6 cores)
Mid,
@@ -51,7 +51,7 @@ impl DeviceTier {
/// (parakeet-mlx) consume too much of the unified memory and cause
/// silent crashes on macOS.
pub fn classify_tier(ram_gb: u64, cores: u64) -> DeviceTier {
- if ram_gb >= 16 && cores >= 8 {
+ if ram_gb >= 24 && cores >= 8 {
DeviceTier::High
} else if ram_gb >= 12 || (ram_gb > 8 && cores >= 6) {
DeviceTier::Mid
@@ -64,7 +64,7 @@ pub fn classify_tier(ram_gb: u64, cores: u64) -> DeviceTier {
///
/// | Tier | Criteria |
/// |------|---------------------------------------|
-/// | High | ≥16 GB RAM and ≥8 cores |
+/// | High | ≥24 GB RAM and ≥8 cores |
/// | Mid | ≥12 GB or (≥8 GB and ≥6 cores) |
/// | Low | everything else |
pub fn detect_tier() -> DeviceTier {
@@ -208,10 +208,11 @@ pub fn macos_major_version() -> Option<u32> {
/// stability issues. On macOS we default to the proven Whisper engine.
/// On Windows/Linux, parakeet is stable and remains the default.
pub fn best_engine_for_platform(tier: DeviceTier) -> &'static str {
- if tier == DeviceTier::Low {
+ if tier == DeviceTier::Low || tier == DeviceTier::Mid {
return "whisper-tiny";
}
+ // High tier only (≥24GB RAM) — safe for large models
#[cfg(target_os = "macos")]
{
"whisper-large-v3-turbo-quantized"
@@ -235,7 +236,7 @@ pub fn is_engine_unsafe(engine: &str, tier: DeviceTier) -> bool {
return false;
}
- if tier == DeviceTier::Low {
+ if tier == DeviceTier::Low || tier == DeviceTier::Mid {
return true;
}
@@ -336,10 +337,13 @@ mod tests {
}
#[test]
- fn parakeet_unsafe_on_low_tier() {
+ fn parakeet_unsafe_on_low_and_mid_tier() {
assert!(is_engine_unsafe("parakeet", DeviceTier::Low));
assert!(is_engine_unsafe("parakeet-mlx", DeviceTier::Low));
+ assert!(is_engine_unsafe("parakeet", DeviceTier::Mid));
+ assert!(is_engine_unsafe("parakeet-mlx", DeviceTier::Mid));
assert!(!is_engine_unsafe("whisper-tiny", DeviceTier::Low));
+ assert!(!is_engine_unsafe("whisper-tiny", DeviceTier::Mid));
assert!(!is_engine_unsafe(
"whisper-large-v3-turbo-quantized",
DeviceTier::High
@@ -364,13 +368,17 @@ mod tests {
fn classify_high_tier() {
// M4 Max 128GB, 16 cores
assert_eq!(classify_tier(128, 16), DeviceTier::High);
- // Boundary: exactly 16 GB, 8 cores
- assert_eq!(classify_tier(16, 8), DeviceTier::High);
+ // Boundary: exactly 24 GB, 8 cores
+ assert_eq!(classify_tier(24, 8), DeviceTier::High);
+ // 16 GB, 8 cores → Mid now (parakeet too heavy for 16GB)
+ assert_eq!(classify_tier(16, 8), DeviceTier::Mid);
}
#[test]
fn classify_mid_tier() {
- // 16 GB but only 4 cores → not High (needs ≥8 cores), but ≥12 GB → Mid
+ // 16 GB, 8 cores → Mid (not enough RAM for parakeet)
+ assert_eq!(classify_tier(16, 8), DeviceTier::Mid);
+ // 16 GB but only 4 cores → ≥12 GB → Mid
assert_eq!(classify_tier(16, 4), DeviceTier::Mid);
// 12 GB, 2 cores → ≥12 GB alone qualifies for Mid
assert_eq!(classify_tier(12, 2), DeviceTier::Mid);