(opts: {
context: number
output: number
input?: number
cost?: Provider.Model["cost"]
npm?: string
})
| 57 | }) |
| 58 | |
| 59 | function createModel(opts: { |
| 60 | context: number |
| 61 | output: number |
| 62 | input?: number |
| 63 | cost?: Provider.Model["cost"] |
| 64 | npm?: string |
| 65 | }): Provider.Model { |
| 66 | return { |
| 67 | id: "test-model", |
| 68 | providerID: "test", |
| 69 | name: "Test", |
| 70 | limit: { |
| 71 | context: opts.context, |
| 72 | input: opts.input, |
| 73 | output: opts.output, |
| 74 | }, |
| 75 | cost: opts.cost ?? { input: 0, output: 0, cache: { read: 0, write: 0 } }, |
| 76 | capabilities: { |
| 77 | toolcall: true, |
| 78 | attachment: false, |
| 79 | reasoning: false, |
| 80 | temperature: true, |
| 81 | input: { text: true, image: false, audio: false, video: false }, |
| 82 | output: { text: true, image: false, audio: false, video: false }, |
| 83 | }, |
| 84 | api: { npm: opts.npm ?? "@ai-sdk/anthropic" }, |
| 85 | options: {}, |
| 86 | } as Provider.Model |
| 87 | } |
| 88 | |
| 89 | const wide = () => ProviderTest.fake({ model: createModel({ context: 100_000, output: 32_000 }) }) |
| 90 |
no outgoing calls
no test coverage detected