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

Clean up max_token selection #418

Open
Kav-K opened this issue Nov 16, 2023 · 0 comments
Open

Clean up max_token selection #418

Kav-K opened this issue Nov 16, 2023 · 0 comments

Comments

@Kav-K
Copy link
Owner

Kav-K commented Nov 16, 2023

Currently, when setting max_tokens for a conversation buffer memory within langchain, we use simple string selection to set the token limit to 29,000 if the model is a gpt-4 model, and 100,000 if the model is one of the preview models (these are 128k context)

It would be nicer to have some sort of get_max_conversation_tokens where it would return the correct bound for a conversation buffer memory given the model name

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant