feat(cliproxy): add thinking budget validator module

- validate user-provided thinking values against model capabilities

- clamp out-of-range budgets, map invalid levels to closest valid

- export constants for budget bounds (MIN=0, MAX=100000)

- support off/auto/level names and numeric budgets

Refs #307
This commit is contained in:
kaitranntt committed 2026-01-08 15:18:29 -05:00
1 parent f290aae4cb
commit 82ef6804bb
2 files changed
+333

No files matched your search

+13
View File
@@ -152,3 +152,16 @@ export {
resetAuthToDefaults,
getAuthSummary,
} from './auth-token-manager';
// Thinking validator
export type { ThinkingValidationResult } from './thinking-validator';
export {
validateThinking,
THINKING_LEVEL_BUDGETS,
VALID_THINKING_LEVELS,
THINKING_OFF_VALUES,
THINKING_AUTO_VALUE,
THINKING_BUDGET_MIN,
THINKING_BUDGET_MAX,
THINKING_BUDGET_DEFAULT_MIN,
} from './thinking-validator';