MCPcopy Index your code
hub / github.com/TanStack/ai / getTextAdapter

Function getTextAdapter

packages/ai-code-mode/models-eval/run-eval.ts:193–211  ·  view source on GitHub ↗
(
  provider: EvalProvider,
  modelId: string,
)

Source from the content-addressed store, hash-verified

191}
192
193function getTextAdapter(
194 provider: EvalProvider,
195 modelId: string,
196): AnyTextAdapter {
197 switch (provider) {
198 case 'ollama':
199 return ollamaText(modelId)
200 case 'openai':
201 return openaiText(modelId as 'gpt-4o-mini')
202 case 'anthropic':
203 return anthropicText(modelId as 'claude-haiku-4-5')
204 case 'gemini':
205 return geminiText(modelId as 'gemini-2.5-flash')
206 case 'grok':
207 return grokText(modelId as 'grok-build-0.1')
208 case 'groq':
209 return groqText(modelId as 'llama-3.3-70b-versatile')
210 }
211}
212
213/**
214 * The max-output-tokens cap lives in provider-native `modelOptions` keys (the

Callers 1

mainFunction · 0.85

Calls 6

ollamaTextFunction · 0.90
openaiTextFunction · 0.90
anthropicTextFunction · 0.90
geminiTextFunction · 0.90
grokTextFunction · 0.90
groqTextFunction · 0.90

Tested by

no test coverage detected