pub fn is_rate_limit_allowed(current_tokens: f64, cost: f64) -> bool
Check if an action is allowed under rate limiting (token bucket).