ultisuite-client/lib/ai/ultiai-tool-groups.ts
R3D347HR4Y 9e9fd208ad
Some checks are pending
E2E / Playwright e2e (push) Waiting to run
feat(admin-settings): enhance admin settings with new components and layout improvements
- Introduced new components for managing admin settings, including AdminListControls, AdminSettingsCard, and TechBrandSelectLabel.
- Implemented dynamic loading for admin settings sections to optimize performance.
- Enhanced the layout of various admin settings sections for better user experience.
- Updated the AiAssistantSection to include LLM provider management and improved model selection.
- Refactored authentication settings to streamline configuration and improve accessibility.
2026-06-15 00:22:20 +02:00

54 lines
1.4 KiB
TypeScript

export type UltiAiToolGroup = {
id: string
label: string
description: string
}
/** Tool groups exposed to UltiAI via MCP (X-Ulti-Enabled-Tools). */
export const ULTIAI_TOOL_GROUPS: UltiAiToolGroup[] = [
{
id: "mail",
label: "Mail",
description: "Recherche, lecture, envoi, libellés et suppression de messages.",
},
{
id: "drive",
label: "Drive",
description: "Fichiers, dossiers, partages et déplacements.",
},
{
id: "contacts",
label: "Contacts",
description: "Carnets d'adresses et fiches contacts.",
},
{
id: "agenda",
label: "Agenda",
description: "Calendriers, événements, invitations et visioconférence.",
},
{
id: "search",
label: "Recherche suite",
description: "Index unifié mail, drive et contacts (pas le web public).",
},
{
id: "web_search",
label: "Recherche web",
description:
"Recherche en ligne (Brave, Bing, SearXNG, DuckDuckGo, API JSON). Même réglages que contacts — onglet Recherche.",
},
]
export const DEFAULT_ULTIAI_ENABLED_TOOLS = ULTIAI_TOOL_GROUPS.map((group) => group.id)
export function toggleUltiAiToolGroup(
enabledTools: string[],
groupId: string,
enabled: boolean,
): string[] {
const set = new Set(enabledTools)
if (enabled) set.add(groupId)
else set.delete(groupId)
return ULTIAI_TOOL_GROUPS.map((group) => group.id).filter((id) => set.has(id))
}