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

Function normalizeAgentModel

packages/arctic/src/config/config.ts:537–560  ·  view source on GitHub ↗
(value: unknown)

Source from the content-addressed store, hash-verified

535 }
536
537 function normalizeAgentModel(value: unknown) {
538 if (typeof value !== "string") return value
539 const trimmed = value.trim()
540 if (!trimmed) return value
541 if (trimmed.includes("/")) return trimmed
542
543 const key = trimmed.toLowerCase()
544 const aliases: Record<string, string> = {
545 haiku: "anthropic/claude-haiku-4-5",
546 "claude-haiku": "anthropic/claude-haiku-4-5",
547 "claude-4-5-haiku": "anthropic/claude-haiku-4-5",
548 "claude-4.5-haiku": "anthropic/claude-haiku-4-5",
549 sonnet: "anthropic/claude-sonnet-4-5",
550 "claude-sonnet": "anthropic/claude-sonnet-4-5",
551 "claude-4-5-sonnet": "anthropic/claude-sonnet-4-5",
552 "claude-4.5-sonnet": "anthropic/claude-sonnet-4-5",
553 opus: "anthropic/claude-opus-4-5",
554 "claude-opus": "anthropic/claude-opus-4-5",
555 "claude-4-5-opus": "anthropic/claude-opus-4-5",
556 "claude-4.5-opus": "anthropic/claude-opus-4-5",
557 }
558
559 return aliases[key] ?? value
560 }
561
562 export const Command = z.object({
563 template: z.string(),

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected