From 66e0d31f68f39130e82dc9143a07272aa938b59d Mon Sep 17 00:00:00 2001 From: CREDO23 Date: Tue, 9 Dec 2025 08:45:18 +0000 Subject: [PATCH] feat: add update LLM preferences request/response schemas --- .../contracts/types/llm-config.types.ts | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/surfsense_web/contracts/types/llm-config.types.ts b/surfsense_web/contracts/types/llm-config.types.ts index 961d6145c..613245f34 100644 --- a/surfsense_web/contracts/types/llm-config.types.ts +++ b/surfsense_web/contracts/types/llm-config.types.ts @@ -158,6 +158,20 @@ export const getLLMPreferencesRequest = z.object({ export const getLLMPreferencesResponse = llmPreferences; +/** + * Update LLM preferences + */ +export const updateLLMPreferencesRequest = z.object({ + search_space_id: z.number(), + data: llmPreferences.pick({ + long_context_llm_id: true, + fast_llm_id: true, + strategic_llm_id: true, + }), +}); + +export const updateLLMPreferencesResponse = llmPreferences; + export type LLMConfig = z.infer; export type LiteLLMProvider = z.infer; export type GlobalLLMConfig = z.infer; @@ -175,3 +189,5 @@ export type DeleteLLMConfigResponse = z.infer; export type LLMPreferences = z.infer; export type GetLLMPreferencesRequest = z.infer; export type GetLLMPreferencesResponse = z.infer; +export type UpdateLLMPreferencesRequest = z.infer; +export type UpdateLLMPreferencesResponse = z.infer;