You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Github Copilot - Too Many Requests with Claude #430
After using for a number of things this evening with github copilot, I get the following error:
AI_RetryError: Failed after 3 attempts. Last error: Too Many Requests
This is with using Claude Sonnet 4 through copilot. When switching to another model, it seems to work fine. I presume I've just been using it too heavily? If so - maybe there might be a better error message that could suggest to try a different model?
The Claude models and other available models, except for GPT-4.1 and GPT-4o, fall under the category of ‘Premium Models’ on GitHub Copilot.
GitHub Copilot has specific limitations in place for using these models: Copilot Usage per Plan.
Each 'Premium Model' has a different multiplier
e.g.
Claude Sonnet 4 has a multiplier of 1, meaning that one prompt == to one premium request.
Gemini 2.0 Flash has a multiplier of 0.25, meaning that four prompts == to one premium request.
GPT-4o and GPT-4.1 are the base models and are considered ‘unlimited’ in terms of usage. However, there are rate limits in place for high usage and during periods of high demand.
Reacted by JonBoyleCoding, Joshua Germon and shiyan-salt
I hit my limit on copilot and got this too. GPT 4.1 seems incredibly dumb, worse than OpenAI's agent with it, anyone else experienced the same? Is it a prompt issue?
I hit my limit on copilot and got this too. GPT 4.1 seems incredibly dumb, worse than OpenAI's agent with it, anyone else experienced the same? Is it a prompt issue?
Both the GPT models seemed pretty poor to me. They kept doing only one thing at a time and then asked if I wanted it to do the next thing. When it actually did something it was rather poor and did things wrong. Claude seemed amazing. Never got a chance to test Gemini.
I did also hit the wall after using the Claude 3.7 with AI_RetryError: Failed after 3 attempts. Last error: Too Many Requests. Switching to GPT-4o works.
Is it a opencode issue or just a cost/usage topic as @nielsjaspers stated?
To check if you used your limit of premium request on Github Copilot, just open VSCode with it configured, then click on the Copilot icon in the bottom right corner:
I did also hit the wall after using the Claude 3.7 with AI_RetryError: Failed after 3 attempts. Last error: Too Many Requests. Switching to GPT-4o works.
Is it a opencode issue or just a cost/usage topic as @nielsjaspers stated?
This is also because GitHub Copilot limits premium models very hard. Has nothing to do with OpenCode
I suppose then the feature request here is that rather than just reporting too many requests, to somehow determine when the limits have been reached and present when the allowance resets.
Codecompanion nvim recently fixed this by setting X-Initiator header to be agent for every request other than the initial prompt. Then each agent call is not counted as premium request. Opencode should also add this.
Some great ideas above, but I think it would also be great if we could preview remaining quota (or usage) for premium interactions just like with other Copilot extensions. Maybe display it in the bottom bar next to cost whenever a premium model is selected? The endpoint others use for this is: https://api.github.com/copilot_internal/user (requires passing Bearer token in Authorization header).
I also notice today that asking the same question/task in opencode uses significantly more of my quota than doing the same thing in VSCode directly. I'm sure there are a whole bunch of optimizations they are doing in VSCode but given the billing/usage is request based now it would be great if there some things opencode could do minimize the # of requests.
I tried the fix in the latest version, it is much better, but it looks like it's still possibly double counting. I have 300 requests per month, and my first request put me up to 0.7% used, and my second request put me up to 1.3% used. This would mean that my quota is essentially 150, but is it possible that it's sending an extra request somewhere?
Activity
JonBoyleCoding commentedon Jun 26, 2025
Interestingly it's more than that. gpt-4o works, but not much else.
JonBoyleCoding commentedon Jun 26, 2025
I can confirm I reached a limit of some kind, on PRs I get the following message:
I guess I'll just have to wait then! I'll try experimenting with local models in the mean time.
nielsjaspers commentedon Jun 26, 2025
The Claude models and other available models, except for GPT-4.1 and GPT-4o, fall under the category of ‘Premium Models’ on GitHub Copilot.
GitHub Copilot has specific limitations in place for using these models: Copilot Usage per Plan.
Each 'Premium Model' has a different multiplier
e.g.
GPT-4o and GPT-4.1 are the base models and are considered ‘unlimited’ in terms of usage. However, there are rate limits in place for high usage and during periods of high demand.
joshgermon commentedon Jun 27, 2025
I hit my limit on copilot and got this too. GPT 4.1 seems incredibly dumb, worse than OpenAI's agent with it, anyone else experienced the same? Is it a prompt issue?
JonBoyleCoding commentedon Jun 27, 2025
Both the GPT models seemed pretty poor to me. They kept doing only one thing at a time and then asked if I wanted it to do the next thing. When it actually did something it was rather poor and did things wrong. Claude seemed amazing. Never got a chance to test Gemini.
danriedl commentedon Jun 27, 2025
I did also hit the wall after using the Claude 3.7 with
AI_RetryError: Failed after 3 attempts. Last error: Too Many Requests. Switching toGPT-4oworks.Is it a opencode issue or just a cost/usage topic as @nielsjaspers stated?
douglascamata commentedon Jun 27, 2025
To check if you used your limit of premium request on Github Copilot, just open VSCode with it configured, then click on the Copilot icon in the bottom right corner:
nielsjaspers commentedon Jun 27, 2025
This is also because GitHub Copilot limits premium models very hard. Has nothing to do with OpenCode
JonBoyleCoding commentedon Jun 27, 2025
I suppose then the feature request here is that rather than just reporting too many requests, to somehow determine when the limits have been reached and present when the allowance resets.
mozbz commentedon Jun 30, 2025
Codecompanion nvim recently fixed this by setting X-Initiator header to be agent for every request other than the initial prompt. Then each agent call is not counted as premium request. Opencode should also add this.
wykwit commentedon Jul 1, 2025
Some great ideas above, but I think it would also be great if we could preview remaining quota (or usage) for premium interactions just like with other Copilot extensions. Maybe display it in the bottom bar next to cost whenever a premium model is selected? The endpoint others use for this is: https://api.github.com/copilot_internal/user (requires passing Bearer token in Authorization header).
mhuggins7278 commentedon Jul 1, 2025
I also notice today that asking the same question/task in opencode uses significantly more of my quota than doing the same thing in VSCode directly. I'm sure there are a whole bunch of optimizations they are doing in VSCode but given the billing/usage is request based now it would be great if there some things opencode could do minimize the # of requests.
fix: Copilot Premium Requests
graemefolk commentedon Jul 3, 2025
I tried the fix in the latest version, it is much better, but it looks like it's still possibly double counting. I have 300 requests per month, and my first request put me up to 0.7% used, and my second request put me up to 1.3% used. This would mean that my quota is essentially 150, but is it possible that it's sending an extra request somewhere?
thdxr commentedon Jul 3, 2025
we send one request to generate the title for the session - we need to tweak this to use a cheaper model but haven't structured that yet
fix: refresh orchestration follow-up after anomalyco#414 (anomalyco#430)
fix: keep step cluster collapse consistent (anomalyco#430)