MCPcopy Create free account
hub / github.com/AnukarOP/claude-code-leaked / getPlanModeV2AgentCount

Function getPlanModeV2AgentCount

source code/utils/planModeV2.ts:7–31  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

5import { isEnvDefinedFalsy, isEnvTruthy } from './envUtils.js'
6
7export function getPlanModeV2AgentCount(): number {
8 // Environment variable override takes precedence
9 if (process.env.CLAUDE_CODE_PLAN_V2_AGENT_COUNT) {
10 const count = parseInt(process.env.CLAUDE_CODE_PLAN_V2_AGENT_COUNT, 10)
11 if (!isNaN(count) && count > 0 && count <= 10) {
12 return count
13 }
14 }
15
16 const subscriptionType = getSubscriptionType()
17 const rateLimitTier = getRateLimitTier()
18
19 if (
20 subscriptionType === 'max' &&
21 rateLimitTier === 'default_claude_max_20x'
22 ) {
23 return 3
24 }
25
26 if (subscriptionType === 'enterprise' || subscriptionType === 'team') {
27 return 3
28 }
29
30 return 1
31}
32
33export function getPlanModeV2ExploreAgentCount(): number {
34 if (process.env.CLAUDE_CODE_PLAN_V2_EXPLORE_AGENT_COUNT) {

Callers 1

Calls 2

getSubscriptionTypeFunction · 0.85
getRateLimitTierFunction · 0.85

Tested by

no test coverage detected