refac
This commit is contained in:
1 parent
de681aa543
commit
6732852ce6
2 files changed
+9
-14
No files matched your search
@@ -51,6 +51,10 @@
|
|||||||
label: $i18n.t('Status Updates'),
|
label: $i18n.t('Status Updates'),
|
||||||
description: $i18n.t('Displays status updates (e.g., web search progress) in the response')
|
description: $i18n.t('Displays status updates (e.g., web search progress) in the response')
|
||||||
},
|
},
|
||||||
|
memory: {
|
||||||
|
label: $i18n.t('Memory'),
|
||||||
|
description: $i18n.t('Inject stored memories into conversation context')
|
||||||
|
},
|
||||||
builtin_tools: {
|
builtin_tools: {
|
||||||
label: $i18n.t('Builtin Tools'),
|
label: $i18n.t('Builtin Tools'),
|
||||||
description: $i18n.t(
|
description: $i18n.t(
|
||||||
@@ -59,22 +63,12 @@
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
export let capabilities: {
|
type Capability = keyof typeof capabilityLabels;
|
||||||
file_context?: boolean;
|
|
||||||
vision?: boolean;
|
export let capabilities: Partial<Record<Capability, boolean>> = {};
|
||||||
file_upload?: boolean;
|
|
||||||
web_search?: boolean;
|
|
||||||
image_generation?: boolean;
|
|
||||||
code_interpreter?: boolean;
|
|
||||||
terminal?: boolean;
|
|
||||||
usage?: boolean;
|
|
||||||
citations?: boolean;
|
|
||||||
status_updates?: boolean;
|
|
||||||
builtin_tools?: boolean;
|
|
||||||
} = {};
|
|
||||||
|
|
||||||
// Hide file_context when file_upload is disabled
|
// Hide file_context when file_upload is disabled
|
||||||
$: visibleCapabilities = Object.keys(capabilityLabels).filter((cap) => {
|
$: visibleCapabilities = (Object.keys(capabilityLabels) as Capability[]).filter((cap) => {
|
||||||
if (cap === 'file_context' && !capabilities.file_upload) {
|
if (cap === 'file_context' && !capabilities.file_upload) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -108,6 +108,7 @@ export const DEFAULT_CAPABILITIES = {
|
|||||||
citations: true,
|
citations: true,
|
||||||
status_updates: true,
|
status_updates: true,
|
||||||
usage: undefined,
|
usage: undefined,
|
||||||
|
memory: true,
|
||||||
builtin_tools: true
|
builtin_tools: true
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|||||||
Reference in new issue
Block a user