diff --git a/src/shared/remote-config/schema.ts b/src/shared/remote-config/schema.ts index 5f0cb9de..7f014c17 100644 --- a/src/shared/remote-config/schema.ts +++ b/src/shared/remote-config/schema.ts @@ -87,6 +87,17 @@ export const VertexSettingsSchema = z.object({ vertexRegion: z.string().optional(), }) +export const LiteLLMModelSchema = z.object({ + id: z.string(), + thinkingBudgetTokens: z.number().optional(), + promptCachingEnabled: z.boolean().optional(), +}) + +export const LiteLLMSchema = z.object({ + models: z.array(LiteLLMModelSchema).optional(), + baseUrl: z.string().optional(), +}) + // Provider settings schema // Each provider becomes an optional field const ProviderSettingsSchema = z.object({ @@ -94,6 +105,7 @@ const ProviderSettingsSchema = z.object({ AwsBedrock: AwsBedrockSettingsSchema.optional(), Cline: ClineSettingsSchema.optional(), Vertex: VertexSettingsSchema.optional(), + LiteLLM: LiteLLMSchema.optional(), }) export const AllowedMCPServerSchema = z.object({ @@ -153,12 +165,21 @@ export const RemoteConfigSchema = z.object({ }) // Type inference from schemas +export type RemoteConfig = z.infer export type MCPServer = z.infer -export type OpenAiCompatibleModel = z.infer +export type GlobalInstructionsFile = z.infer + +export type ProviderSettings = z.infer + export type OpenAiCompatible = z.infer +export type OpenAiCompatibleModel = z.infer + +export type AwsBedrockSettings = z.infer export type AwsBedrockModel = z.infer export type AwsBedrockCustomModel = z.infer -export type AwsBedrockSettings = z.infer -export type ProviderSettings = z.infer -export type RemoteConfig = z.infer -export type GlobalInstructionsFile = z.infer + +export type VertexSettings = z.infer +export type VertexModel = z.infer + +export type LiteLLMSettings = z.infer +export type LiteLLMModel = z.infer