MCPcopy Create free account
hub / github.com/freecodexyz/free-code / getDefaultOptionForUser

Function getDefaultOptionForUser

src/utils/model/modelOptions.ts:46–75  ·  view source on GitHub ↗
(fastMode = false)

Source from the content-addressed store, hash-verified

44}
45
46export function getDefaultOptionForUser(fastMode = false): ModelOption {
47 if (process.env.USER_TYPE === 'ant') {
48 const currentModel = renderDefaultModelSetting(
49 getDefaultMainLoopModelSetting(),
50 )
51 return {
52 value: null,
53 label: 'Default (recommended)',
54 description: `Use the default model for Ants (currently ${currentModel})`,
55 descriptionForModel: `Default model (currently ${currentModel})`,
56 }
57 }
58
59 // Subscribers
60 if (isClaudeAISubscriber()) {
61 return {
62 value: null,
63 label: 'Default (recommended)',
64 description: getClaudeAiUserDefaultModelDescription(fastMode),
65 }
66 }
67
68 // PAYG
69 const is3P = getAPIProvider() !== 'firstParty'
70 return {
71 value: null,
72 label: 'Default (recommended)',
73 description: `Use the default model (currently ${renderDefaultModelSetting(getDefaultMainLoopModelSetting())})${is3P ? '' : ` · ${formatModelPricing(COST_TIER_3_15)}`}`,
74 }
75}
76
77function getCustomSonnetOption(): ModelOption | undefined {
78 const is3P = getAPIProvider() !== 'firstParty'

Callers 1

getModelOptionsBaseFunction · 0.85

Calls 6

getAPIProviderFunction · 0.85
formatModelPricingFunction · 0.85
isClaudeAISubscriberFunction · 0.50

Tested by

no test coverage detected