Display Claude tokenizer in the UI if Claude model is used

This commit is contained in:
Cohee
2023-07-05 14:49:45 +03:00
parent 9c3823a616
commit 5c39327450
3 changed files with 6 additions and 5 deletions

View File

@@ -937,7 +937,7 @@ function countTokens(messages, full = false) {
return token_count;
}
function getTokenizerModel() {
export function getTokenizerModel() {
// OpenAI models always provide their own tokenizer
if (oai_settings.chat_completion_source == chat_completion_sources.OPENAI) {
return oai_settings.openai_model;