update code to use new json based system prompt for routing (#493)

This commit is contained in:
Adil Hafeez 2025-05-30 17:40:46 -07:00 committed by GitHub
parent 8d12a9a6e0
commit 0d190a6e5c
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
12 changed files with 433 additions and 283 deletions

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?