MCPcopy Create free account
hub / github.com/cortexkit/magic-context / getAvailableModels

Function getAvailableModels

packages/cli/src/lib/opencode-helpers.ts:26–33  ·  view source on GitHub ↗
(binary?: string | null)

Source from the content-addressed store, hash-verified

24}
25
26export function getAvailableModels(binary?: string | null): string[] {
27 const output = runOpenCode(["models"], binary);
28 if (output === null) return [];
29 return output
30 .split("\n")
31 .map((l) => l.trim())
32 .filter(Boolean);
33}

Callers 2

runSetupFunction · 0.90

Calls 1

runOpenCodeFunction · 0.85

Tested by

no test coverage detected