[GH-ISSUE #511] Invalid OpenAI Token Limit #299

Closed
opened 2026-02-22 18:18:50 -05:00 by yindo · 1 comment
Owner

Originally created by @imbible on GitHub (Dec 31, 2023).
Original GitHub issue: https://github.com/Mintplex-Labs/anything-llm/issues/511

The Azure OpenAI has the GPT-4 turbo model, which has 128,000 tokens. I am able to select that from the dropdown list, but cannot save the settings.
Here is the option:
image
Here is the error message:
image
This is a screenshot from my Azure OpenAI Chat playground. As you can see, I do have the deployment with 128,000 tokens.
image

I believe this line is wrong.
https://github.com/Mintplex-Labs/anything-llm/blob/6d5968bf7e694aae8e68bbb4cd2e0e6f491f47d1/server/utils/helpers/updateENV.js#L296
I'm not sure if this is the root cause.

Originally created by @imbible on GitHub (Dec 31, 2023). Original GitHub issue: https://github.com/Mintplex-Labs/anything-llm/issues/511 The Azure OpenAI has the GPT-4 turbo model, which has 128,000 tokens. I am able to select that from the dropdown list, but cannot save the settings. Here is the option: <img width="263" alt="image" src="https://github.com/Mintplex-Labs/anything-llm/assets/4526968/cd941192-7823-44e0-8d59-c9cf72dc72ff"> Here is the error message: <img width="374" alt="image" src="https://github.com/Mintplex-Labs/anything-llm/assets/4526968/ce4c0ff5-2b27-46a5-8a2d-8ffda770eab4"> This is a screenshot from my Azure OpenAI Chat playground. As you can see, I do have the deployment with 128,000 tokens. <img width="208" alt="image" src="https://github.com/Mintplex-Labs/anything-llm/assets/4526968/4b21ae92-2985-4810-bc69-6e60798e3677"> I believe this line is wrong. https://github.com/Mintplex-Labs/anything-llm/blob/6d5968bf7e694aae8e68bbb4cd2e0e6f491f47d1/server/utils/helpers/updateENV.js#L296 I'm not sure if this is the root cause.
yindo added the bugIntegration Request labels 2026-02-22 18:18:50 -05:00
yindo closed this issue 2026-02-22 18:18:50 -05:00
Author
Owner

@timothycarambat commented on GitHub (Dec 31, 2023):

Ah, the token count for this model is indeed missing. Good catch. Will mark as bug

@timothycarambat commented on GitHub (Dec 31, 2023): Ah, the token count for this model is indeed missing. Good catch. Will mark as bug
yindo changed title from Invalid OpenAI Token Limit to [GH-ISSUE #511] Invalid OpenAI Token Limit 2026-06-05 14:34:34 -04:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: Mintplex-Labs/anything-llm#299