revert model name for token counting

This commit is contained in:
Adil Hafeez 2025-05-30 13:18:10 -07:00
parent d4e79e1d5a
commit 75cb87783a
No known key found for this signature in database
GPG key ID: 9B18EF7691369645

View file

@ -14,13 +14,7 @@ pub fn token_count(model_name: &str, text: &str) -> Result<usize, String> {
);
"gpt-4"
}
true => {
if model_name.starts_with("gpt-4.1") {
"gpt-4o"
} else {
model_name
}
}
true => model_name
};
// Consideration: is it more expensive to instantiate the BPE object every time, or to contend the singleton?