MCPcopy Create free account
hub / github.com/arctic-cli/interface / copilotModelCandidates

Function copilotModelCandidates

packages/arctic/src/provider/pricing.ts:151–170  ·  view source on GitHub ↗
(modelId: string)

Source from the content-addressed store, hash-verified

149 }
150
151 function copilotModelCandidates(modelId: string): string[] {
152 const base = extractModelId(modelId).toLowerCase()
153 const candidates = new Set([base])
154 const queue = [base]
155 const transforms = [stripThinkingSuffix, stripReasoningEffort]
156
157 while (queue.length > 0) {
158 const current = queue.pop()
159 if (!current) continue
160 for (const transform of transforms) {
161 const next = transform(current)
162 if (!candidates.has(next)) {
163 candidates.add(next)
164 queue.push(next)
165 }
166 }
167 }
168
169 return Array.from(candidates)
170 }
171
172 /**
173 * Get pricing information for a specific model (sync - cached data only)

Callers 1

getCopilotMultiplierFunction · 0.85

Calls 4

extractModelIdFunction · 0.85
transformFunction · 0.85
pushMethod · 0.80
addMethod · 0.45

Tested by

no test coverage detected