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

Function get

packages/arctic/src/provider/models.ts:174–214  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

172 }
173
174 export async function get() {
175 refresh()
176 const file = Bun.file(filepath)
177 const result = await file.json().catch(() => {})
178 const base = result ? (result as Record<string, Provider>) : (JSON.parse(await data()) as Record<string, Provider>)
179 for (const [id, provider] of Object.entries(LOCAL_PROVIDERS)) {
180 if (!base[id]) {
181 base[id] = provider
182 } else if (id === "alibaba") {
183 // Override alibaba models with local definitions (only mainline models)
184 base[id] = provider
185 }
186 }
187
188 // Add Antigravity provider locally since it's not in models.dev yet
189 if (!base["antigravity"]) {
190 base["antigravity"] = {
191 id: "antigravity",
192 name: "Antigravity",
193 env: [],
194 npm: "@ai-sdk/google", // Uses Google SDK internally
195 models: {
196 // Basic placeholder models - real ones are handled dynamically
197 "gemini-2.0-flash-thinking-exp-01-21": {
198 id: "gemini-2.0-flash-thinking-exp-01-21",
199 name: "Gemini 2.0 Flash Thinking",
200 release_date: "2025-01-21",
201 attachment: true,
202 reasoning: true,
203 temperature: true,
204 tool_call: true,
205 limit: { context: 1_000_000, output: 8192 },
206 cost: { input: 0, output: 0 },
207 options: {},
208 },
209 },
210 }
211 }
212
213 return base
214 }
215
216 export async function refresh() {
217 const file = Bun.file(filepath)

Callers

nothing calls this directly

Calls 3

dataFunction · 0.90
refreshFunction · 0.70
jsonMethod · 0.65

Tested by

no test coverage detected