Skip to content

Commit

Permalink
fix: Update context size for multiple models in model.rs
Browse files Browse the repository at this point in the history
- Fix a typo in the model.rs file
- Update the context size for the model `gpt-3.5-turbo-16k` from `16_384` to `16_385`
- Increase the context size for the model `gpt-3.5-turbo` from `4096` to `16_385`
  • Loading branch information
zurawiki committed Mar 20, 2024
1 parent a88091f commit bf3adc9
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions tiktoken-rs/src/model.rs
Original file line number Diff line number Diff line change
Expand Up @@ -51,10 +51,10 @@ pub fn get_context_size(model: &str) -> usize {
return 16_385;
}
if starts_with_any!(model, "gpt-3.5-turbo-16k") {
return 16_384;
return 16_385;
}
if starts_with_any!(model, "gpt-3.5-turbo") {
return 4096;
return 16_385;
}
if starts_with_any!(model, "text-davinci-002", "text-davinci-003") {
return 4097;
Expand Down

0 comments on commit bf3adc9

Please sign in to comment.