claude-code - 💡(How to fix) Fix [Bug] Excessive token consumption from system prompt and slow response times in Claude Code [1 participants]

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…
GitHub stats
anthropics/claude-code#51747Fetched 2026-04-22 07:53:55
View on GitHub
Comments
0
Participants
1
Timeline
3
Reactions
0
Author
Participants
Timeline (top)
labeled ×3

Code Example

[]
RAW_BUFFERClick to expand / collapse

Bug Description I have removed all plugins and skills, and still I start up claude code, type hello, and it takes 30 seconds to respond. An immediate hit to 20k tokens is shown when it finally responds. Lately, it has not been able to complete even fairly simple tasks, and just a few interactions uses up the entire session period's tokens (I am a Pro level subscriber). The bottom line - when your system prompt that I cannot disable is this large, it prevents me from using claude code at all. On top of this, it does not appear to be able to successfully accomplish anything useful. It will often churn for 5 or six minutes when a simple update or change is requested. Not sure what y'all are doing but this is proving to be a major rip off. The immediate fix is to not count your system prompts in my usage, and secondly to ensure that whatever system prompt is needed is loaded once and not with every interaction. I'm off to look elsewhere - Anthropic is going to perish quickly if you allow this BS to continue. Perhaps you are not tracking sessions in a useful manner and are wasting huge compute resources as a result

Environment Info

  • Platform: darwin
  • Terminal: Apple_Terminal
  • Version: 2.1.116
  • Feedback ID: b4262466-ea39-406c-bee7-60e657081f69

Errors

[]

extent analysis

TL;DR

The most likely fix is to exclude system prompts from token counting and optimize the loading of system prompts to prevent redundant loading with every interaction.

Guidance

  • Investigate the token counting mechanism to determine why system prompts are being included in the token count, and consider modifying it to exclude these prompts.
  • Review the system prompt loading process to identify opportunities for optimization, such as loading the prompt only once per session instead of with every interaction.
  • Consider implementing a more efficient session tracking mechanism to reduce compute resource waste and improve overall performance.
  • Evaluate the current system architecture to identify potential bottlenecks or areas for improvement that may be contributing to the slow response times and high token usage.

Example

No code snippet is provided as the issue does not contain sufficient technical details to create a specific example.

Notes

The issue lacks detailed technical information, making it challenging to provide a comprehensive solution. The suggestions provided are based on the user's description of the problem and may require further investigation to implement effectively.

Recommendation

Apply workaround: Exclude system prompts from token counting and optimize the loading of system prompts. This is a temporary solution to alleviate the immediate issue, but a more permanent fix may require a deeper investigation into the system architecture and token counting mechanism.

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING