mirror of
https://github.com/siteboon/claudecodeui.git
synced 2026-07-04 04:13:03 +08:00
* feat: add Claude and Codex effort controls * refactor: generic provider effort handling * fix: reconcile provider effort after model changes * fix: pass effort through external agent api * feat: add effort support for opencode * chore: update gpt fallback models * fix: use portal for showing effort dropdown --------- Co-authored-by: Haileyesus <118998054+blackmammoth@users.noreply.github.com>
14 lines
553 B
TypeScript
14 lines
553 B
TypeScript
import type { LLMProvider, ProviderModelOption } from '../../../types/app';
|
|
|
|
export const DEFAULT_EFFORT_VALUE = 'default';
|
|
|
|
export const FALLBACK_PROVIDER_EFFORT_VALUES: Partial<Record<LLMProvider, readonly string[]>> = {
|
|
claude: ['low', 'medium', 'high', 'xhigh', 'max'],
|
|
codex: ['low', 'medium', 'high', 'xhigh'],
|
|
opencode: ['none', 'low', 'medium', 'high', 'xhigh', 'max'],
|
|
};
|
|
|
|
export const toProviderEffortOptions = (
|
|
values: readonly string[],
|
|
): NonNullable<ProviderModelOption['effort']>['values'] => values.map((value) => ({ value }));
|