refactor(core): inject models options

This commit is contained in:
Dax Raad 2026-07-20 15:18:03 -04:00
commit 0aa4031dd0
8 changed files with 370 additions and 417 deletions

View file

@ -68,6 +68,11 @@ const processEffect = Effect.fnUntraced(function* (options: Options) {
database: {
path: process.env.OPENCODE_DB,
},
models: {
url: process.env.OPENCODE_MODELS_URL,
file: process.env.OPENCODE_MODELS_PATH,
fetch: !["1", "true"].includes(process.env.OPENCODE_DISABLE_MODELS_FETCH?.toLowerCase() ?? ""),
},
service:
serviceOptions === undefined
? undefined