Co-authored-by: opencode <opencode@sst.dev> Co-authored-by: Aiden Cline <63023139+rekram1-node@users.noreply.github.com> Co-authored-by: Aiden Cline <rekram1-node@users.noreply.github.com> Co-authored-by: Luke Parker <10430890+Hona@users.noreply.github.com> Co-authored-by: opencode-agent[bot] <219766164+opencode-agent[bot]@users.noreply.github.com> Co-authored-by: Adam <2363879+adamdotdevin@users.noreply.github.com> Co-authored-by: opencode-agent[bot] <opencode-agent[bot]@users.noreply.github.com> Co-authored-by: Brendan Allan <14191578+Brendonovich@users.noreply.github.com> Co-authored-by: Victor Navarro <vn4varro@gmail.com> Co-authored-by: Aarav Sareen <96787824+arvsrn@users.noreply.github.com> Co-authored-by: Frank <frank@anoma.ly> Co-authored-by: Dax Raad <d@ironbay.co> Co-authored-by: Dax <mail@thdxr.com> Co-authored-by: Nabs <nabil@instafork.com> Co-authored-by: usrnk1 <7547651+usrnk1@users.noreply.github.com> Co-authored-by: Brendan Allan <git@brendonovich.dev> Co-authored-by: Vladimir Glafirov <vglafirov@gitlab.com> Co-authored-by: AidenGeunGeun <eastlandwyvern@gmail.com> Co-authored-by: Mark <geraint0923@users.noreply.github.com> Co-authored-by: Aiden Cline <aidenpcline@gmail.com> Co-authored-by: David Hill <1879069+iamdavidhill@users.noreply.github.com> Co-authored-by: Jay <air@live.ca> Co-authored-by: Jay <53023+jayair@users.noreply.github.com> Co-authored-by: BB84 <110078428+BB-84C@users.noreply.github.com> Co-authored-by: Dustin Deus <deusdustin@gmail.com> Co-authored-by: Jack <jack@anoma.ly> Co-authored-by: Sebastian <hasta84@gmail.com> Co-authored-by: Jérôme Benoit <jerome.benoit@sap.com> Co-authored-by: Test User <test@test.com> Co-authored-by: Simon Klee <hello@simonklee.dk> Co-authored-by: Rahul A Mistry <149420892+ProdigyRahul@users.noreply.github.com> Co-authored-by: Qiping Li <liqiping1991@gmail.com> Co-authored-by: liqiping <liqiping@msh.team> Co-authored-by: OpeOginni <107570612+OpeOginni@users.noreply.github.com> Co-authored-by: Matthias Reso <13337103+mreso@users.noreply.github.com> Co-authored-by: tobwen <1864057+tobwen@users.noreply.github.com>
56 lines
1.4 KiB
TypeScript
56 lines
1.4 KiB
TypeScript
const model_id = "claude-3-7-sonnet"
|
|
|
|
export const popularProviders = [
|
|
"opencode",
|
|
"opencode-go",
|
|
"anthropic",
|
|
"github-copilot",
|
|
"openai",
|
|
"google",
|
|
"openrouter",
|
|
"vercel",
|
|
]
|
|
|
|
const provider = {
|
|
id: "anthropic",
|
|
name: "Anthropic",
|
|
models: {
|
|
[model_id]: {
|
|
id: model_id,
|
|
name: "Claude 3.7 Sonnet",
|
|
cost: { input: 1, output: 1 },
|
|
variants: { fast: {}, thinking: {} },
|
|
},
|
|
},
|
|
}
|
|
|
|
const popular = [
|
|
{ id: "opencode", name: "OpenCode Zen", models: {} },
|
|
{ id: "opencode-go", name: "OpenCode Go", models: {} },
|
|
{ id: "openai", name: "OpenAI", models: {} },
|
|
provider,
|
|
{ id: "google", name: "Google", models: {} },
|
|
{ id: "github-copilot", name: "GitHub Copilot", models: {} },
|
|
]
|
|
|
|
const catalog = [
|
|
...popular,
|
|
{ id: "openrouter", name: "OpenRouter", models: {} },
|
|
{ id: "vercel", name: "Vercel AI Gateway", models: {} },
|
|
{ id: "302ai", name: "302.AI", models: {} },
|
|
{ id: "abacus", name: "Abacus", models: {} },
|
|
{ id: "abliteration", name: "abliteration.ai", models: {} },
|
|
{ id: "alibaba", name: "Alibaba", models: {} },
|
|
{ id: "alibaba-cn", name: "Alibaba (China)", models: {} },
|
|
{ id: "alibaba-coding-plan", name: "Alibaba Coding Plan", models: {} },
|
|
]
|
|
|
|
export function useProviders() {
|
|
return {
|
|
all: () => new Map(catalog.map((item) => [item.id, item])),
|
|
default: () => ({ anthropic: model_id }),
|
|
connected: () => [provider],
|
|
paid: () => [provider],
|
|
popular: () => popular,
|
|
}
|
|
}
|