pub fn estimate_tokens(text: &str) -> i32
Estimate the number of tokens in a given text. We use this for example to estimate the expense of a chat request. The result is not accurate but it is cheap to calculate.