MCPcopy Index your code
hub / github.com/anomalyco/opencode / model

Function model

packages/opencode/test/cli/run/runtime.boot.test.ts:8–57  ·  view source on GitHub ↗
(id: string, providerID: string, context: number, variants?: Record<string, Record<string, never>>)

Source from the content-addressed store, hash-verified

6import { createTuiResolvedConfig } from "../../fixture/tui-runtime"
7
8function model(id: string, providerID: string, context: number, variants?: Record<string, Record<string, never>>) {
9 return {
10 id,
11 providerID,
12 api: {
13 id: providerID,
14 url: `https://${providerID}.test`,
15 npm: `@ai-sdk/${providerID}`,
16 },
17 name: id,
18 capabilities: {
19 temperature: true,
20 reasoning: true,
21 attachment: true,
22 toolcall: true,
23 input: {
24 text: true,
25 audio: false,
26 image: false,
27 video: false,
28 pdf: false,
29 },
30 output: {
31 text: true,
32 audio: false,
33 image: false,
34 video: false,
35 pdf: false,
36 },
37 interleaved: false,
38 },
39 cost: {
40 input: 0,
41 output: 0,
42 cache: {
43 read: 0,
44 write: 0,
45 },
46 },
47 limit: {
48 context,
49 output: 8192,
50 },
51 status: "active" as const,
52 options: {},
53 headers: {},
54 release_date: "2026-01-01",
55 variants,
56 }
57}
58
59function config(input?: {
60 leader?: string

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected