Ask a question to get started
Enter to sendā¢Shift+Enter new line
modelname_to_contextsize( modelname: str, ) -> int
modelname
str
The modelname we want to know the context size for.
Calculate the maximum number of tokens possible to generate for a model.
Example:
max_tokens = openai.modelname_to_contextsize("gpt-3.5-turbo-instruct")