fix(core): restore degradation settings and clean combo stream output

Persist background degradation settings as structured data so they can
be reloaded during node startup without double-encoding JSON.

Update settings validation to accept the missing fields used by the
API and align models.dev sync interval bounds with millisecond-based
values.

Also strip omniModel tags when they are wrapped by either literal
escaped newlines or actual newline characters, and adjust the combo
routing test to match the cleaned streamed content.
This commit is contained in:
diegosouzapw
2026-04-13 14:35:26 -03:00
parent 0856854c81
commit 7efa672976
5 changed files with 29 additions and 5 deletions

View File

@@ -88,5 +88,8 @@ export const updateSettingsSchema = z.object({
skillsmpApiKey: z.string().max(200).optional(),
// models.dev sync settings
modelsDevSyncEnabled: z.boolean().optional(),
modelsDevSyncInterval: z.number().int().min(3600).max(604800).optional(),
modelsDevSyncInterval: z.number().int().min(1000).max(604800000).optional(),
// Missing settings
lkgpEnabled: z.boolean().optional(),
backgroundDegradation: z.unknown().optional(),
});