use clap::Parser;
#[derive(Debug, Clone, Parser)]
#[command(
name = "corelens",
version,
about = "Linux CPU topology and local AI workload monitor"
)]
pub struct Config {
#[arg(long, default_value_t = 500)]
pub refresh_ms: u64,
#[arg(long, default_value = "http://127.0.0.1:11434")]
pub ollama_url: String,
#[arg(long)]
pub debug_topology: bool,
}
impl Config {
pub fn refresh_interval_ms(&self) -> u64 {
self.refresh_ms.max(100)
}
}