Added support for gpt-4 128k
With yesterday's release GPT-4 128k is available in the API. Updated limits (but left default) with the new values from https://help.openai.com/en/articles/8555510-gpt-4-turbo
Summary by CodeRabbit
- New Feature: Added support for the new GPT-4 128k model in the
TokenLimitsclass. This update allows users to utilize the increased token limit and response tokens of the GPT-4 model, enhancing the capabilities of their AI applications. Please note that theknowledgeCutOffvalue has also been updated for this model.
CodeRabbit
Walkthrough
This change introduces support for the new GPT-4 128k model in the TokenLimits class. It adds a case for the gpt-4-1106-preview model, setting appropriate token limits and updating the knowledge cut-off value. The default values remain unaffected.
Changes
| File | Summary |
|---|---|
| src/limits.ts | Updated TokenLimits class to include support for the new GPT-4 128k model. Added a case for gpt-4-1106-preview, set maxTokens to 128000, responseTokens to 4000, and updated knowledgeCutOff. Default values remain unchanged. |
ππ»
In the land of code, where the shadows lie,
A new model emerges, reaching for the sky.
With tokens aplenty, it's ready to fly,
GPT-4 is here, oh my, oh my! ππ
Uplevel your code reviews with CodeRabbit Pro
CodeRabbit Pro
If you like this project, please support us by purchasing the Pro version. The Pro version has advanced context, superior noise reduction and several proprietary improvements compared to the open source version. Moreover, CodeRabbit Pro is free for open source projects.
@jimmystridh thanks for your PR. We tried the new model yesterday and found that itβs severely rate limited right now - 100 requests per day (100 RPD). We can merge this PR as soon as the limit is increased by OpenAI. Cheers!
https://www.threads.net/@firtoz/post/Cze1ZLmorg3/?igshid=NTc4MTIwNjQ2YQ== seems like it's happening
Limits raised to 10,000 RPD. I think it's time to merge.
@harjotgill
@harjotgill When will this be merged?
Let's make this happen together!