fix: title generation cost calculation

fixes #330
This commit is contained in:
Jing Hua 2023-06-07 19:51:14 +08:00
parent cb930e3e2c
commit 7bf6f7af87

View file

@ -189,7 +189,7 @@ const useSubmit = () => {
// update tokens used for generating title
if (countTotalTokens) {
const model = currChats[currentChatIndex].config.model;
const model = _defaultChatConfig.model;
updateTotalTokenUsed(model, [message], {
role: 'assistant',
content: title,