support global config

This commit is contained in:
Dax Raad
2025-06-18 18:56:41 -04:00
parent 6a00e063c4
commit 6a3392385e
4 changed files with 16 additions and 42 deletions

View File

@@ -32,6 +32,7 @@ export namespace ModelsDev {
export const Provider = z
.object({
api: z.string().optional(),
name: z.string(),
env: z.array(z.string()),
id: z.string(),

View File

@@ -103,6 +103,7 @@ export namespace Provider {
if (!provider) {
const info = database[id]
if (!info) return
if (info.api) options["baseURL"] = info.api
providers[id] = {
source,
info,