feat(opencode): add Devin provider support - #39301
Conversation
|
Thanks for updating your PR! It now meets our contributing guidelines. 👍 |
Resumen de lo intentadoImplementaciónSe agregó Devin como bundled provider en OpenCode via
Problema encontradoEl provider funciona correctamente, pero la API de Devin/Cognition (
La API de Alternativas evaluadas
ConclusiónEl provider está correctamente implementado del lado de OpenCode. No funciona con cuentas individuales de Devin porque la API de Devin/Cognition lo bloquea a nivel de plan. Para que sea usable se necesita:
|
Issue for this PR
Closes #24072
Type of change
What does this PR do?
Adds Devin.ai as a provider in OpenCode via the
ai-sdk-devinnpm package (v0.3.6), which wraps Devin/Cognition LLM models through the AI SDK interface.Changes:
packages/opencode/package.json— addedai-sdk-devin: "0.3.6"dependencypackages/opencode/src/provider/provider.ts:ai-sdk-devintoBUNDLED_PROVIDERSfor SDK creation via the bundled loader mechanismcustom(dep)that detectsDEVIN_API_KEYenv var and exposes adiscoverModels()function for dynamic model discovery from the Devin APIDEVIN_API_KEYis set, enabling auto-activation without configThe custom loader follows the same pattern used by GitLab, Snowflake Cortex, Cloudflare Workers AI, and other bundled providers. The
discoverModels()function lazily importsai-sdk-devin, calls itsmodels()API, and constructs Model objects withapi.npm: "ai-sdk-devin"so model calls route through the bundled provider SDK loader.How did you verify your code works?
bun typecheckpasses across all 30 packages in the monorepo (0 errors)bun installresolves and installsai-sdk-devin@0.3.6successfullyCustomLoader,Info,ModeltypesScreenshots / recordings
N/A — provider configuration change, no UI.
Checklist