Skip to content
This repository has been archived by the owner on Apr 18, 2024. It is now read-only.

Commit

Permalink
add total tokens to cohere client embed
Browse files Browse the repository at this point in the history
  • Loading branch information
patcher9 committed Mar 17, 2024
1 parent bbee8a3 commit 89888b4
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/cohere.js
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,7 @@ export default function initCohere({ llm, dokuUrl, apiKey, environment, applicat
model: model,
prompt: prompt,
promptTokens: response.meta["billedUnits"]["inputTokens"],
totalTokens: response.meta["billedUnits"]["inputTokens"],
};

await sendData(data, dokuUrl, apiKey);
Expand Down

0 comments on commit 89888b4

Please sign in to comment.