Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Question - can we get the token numbers input and output from the query transaction #30

Closed
converseKarl opened this issue Apr 23, 2024 · 4 comments
Assignees
Labels
question Further information is requested

Comments

@converseKarl
Copy link

use for logging/tracking/thresholds and bill costings

@adhityan adhityan added the question Further information is requested label Apr 24, 2024
@adhityan
Copy link
Collaborator

Today, you can get that from the Langsmith integration. It's unclear to me what other tools are out there that people might be interested in using to track this. Suggestions?

@converseKarl
Copy link
Author

Not everyone wants langsmith. It lacks in many areas but I can write my own in out token tracker with threshold alerting and map to analytics for billing.

@converseKarl
Copy link
Author

You might want to check as openai for example provides input tokens, completion and total. I'm sure its now capable of returning token usage, completion and total, meaning its easier to track the cost. I would say this is a seriously key feature to have in the library crucial to track cost otherwise it becomes a serious problem. Please can yo bump this as a high priority? and amazon bedrock.

https://js.langchain.com/v0.1/docs/modules/model_io/chat/token_usage_tracking/

@adhityan
Copy link
Collaborator

adhityan commented Oct 9, 2024

Token used is now sent back in every query response. Check out the updated documentation at https://llm-tools.mintlify.app/ for more details.

@adhityan adhityan closed this as completed Oct 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants