Skip to content

armgit / Pulse

Public Imported from GitHub
0

Real-time monitoring dashboard for Proxmox VE, PBS, Docker, Kubernetes, TrueNAS and vSphere. Self-hosted, with alerts for failed backups, full disks, unhealthy containers and offline nodes.

rename AI services settings to assistant and patrol

rcourtmanc2bb93e24318
diff --git a/docs/release-control/v6/internal/subsystems/frontend-primitives.md b/docs/release-control/v6/internal/subsystems/frontend-primitives.md
index fc9b0d3f96..16a566f436 100644
--- a/docs/release-control/v6/internal/subsystems/frontend-primitives.md
+++ b/docs/release-control/v6/internal/subsystems/frontend-primitives.md
@@ -300,6 +300,14 @@ work extends shared components instead of creating new local variants.
likewise expose `/patrol` as the canonical route and navigation target,
keeping legacy `/ai` entry points as thin compatibility redirects rather
than a second Patrol-branded primary route.
+19. Keep the shared `system-ai` settings shell product-first.
+ `frontend-modern/src/components/Settings/AISettings.tsx`,
+ `frontend-modern/src/components/Settings/settingsHeaderMeta.ts`,
+ `frontend-modern/src/components/Settings/settingsNavCatalog.ts`,
+ `frontend-modern/src/components/Settings/useAISettingsState.ts`, and
+ `frontend-modern/src/utils/aiSettingsPresentation.ts` must present that
+ surface to operators as `Assistant & Patrol` plus provider/model
+ configuration rather than as a generic `AI Services` shell.
## Forbidden Paths
@@ -1586,6 +1594,14 @@ configuration controls may point at the shared provider settings route or model
catalog, but they should describe those controls as Patrol/provider surfaces
rather than falling back to generic `AI Settings`, `AI Model`, or `AI circuit
breaker` copy inside the Patrol shell itself.
+That same product-first naming rule also applies to the shared `system-ai`
+settings shell: `frontend-modern/src/components/Settings/AISettings.tsx`,
+`frontend-modern/src/components/Settings/settingsHeaderMeta.ts`,
+`frontend-modern/src/components/Settings/settingsNavCatalog.ts`,
+`frontend-modern/src/components/Settings/useAISettingsState.ts`, and
+`frontend-modern/src/utils/aiSettingsPresentation.ts` must present that surface
+to operators as `Assistant & Patrol` plus provider/model configuration rather
+than as a generic `AI Services` shell.
On the main Patrol page, though, that same governed activity context belongs
inside `frontend-modern/src/features/patrol/PatrolIntelligenceSummary.tsx`
alongside the verification readout rather than as a second full-width band
diff --git a/frontend-modern/src/components/Settings/AISettings.tsx b/frontend-modern/src/components/Settings/AISettings.tsx
index d4ee0b3cc3..11c7c21121 100644
--- a/frontend-modern/src/components/Settings/AISettings.tsx
+++ b/frontend-modern/src/components/Settings/AISettings.tsx
@@ -22,8 +22,8 @@ export const AISettings: Component = () => {
return (
<>
<SettingsPanel
- title="AI Services"
- description="Configure AI providers, models, Pulse Assistant, and Patrol."
+ title="Assistant & Patrol"
+ description="Configure providers, models, Pulse Assistant, and Patrol."
icon={
<svg
class="w-5 h-5 text-blue-600 dark:text-blue-300"
@@ -49,7 +49,7 @@ export const AISettings: Component = () => {
}}
disabled={state.loading() || state.saving() || state.loadError()}
containerClass="items-center gap-2"
- ariaLabel="Enable AI services"
+ ariaLabel="Enable Assistant and Patrol"
label={
<span class="text-xs font-medium text-muted">
{state.form.enabled ? 'Enabled' : 'Disabled'}
diff --git a/frontend-modern/src/components/Settings/__tests__/AISettings.test.tsx b/frontend-modern/src/components/Settings/__tests__/AISettings.test.tsx
index 48c47902d3..275863c436 100644
--- a/frontend-modern/src/components/Settings/__tests__/AISettings.test.tsx
+++ b/frontend-modern/src/components/Settings/__tests__/AISettings.test.tsx
@@ -301,7 +301,7 @@ describe('AISettings load failure error state', () => {
renderComponent();
await waitFor(() => {
- expect(screen.getByText(/Unable to load Pulse Assistant settings/)).toBeInTheDocument();
+ expect(screen.getByText(/Unable to load Assistant & Patrol settings/)).toBeInTheDocument();
});
// Retry button should be present
@@ -317,7 +317,7 @@ describe('AISettings load failure error state', () => {
renderComponent();
await waitFor(() => {
- expect(screen.getByText(/Unable to load Pulse Assistant settings/)).toBeInTheDocument();
+ expect(screen.getByText(/Unable to load Assistant & Patrol settings/)).toBeInTheDocument();
});
// Now mock a successful response for retry
@@ -337,7 +337,7 @@ describe('AISettings load failure error state', () => {
});
// Error banner should be gone
- expect(screen.queryByText(/Unable to load Pulse Assistant settings/)).not.toBeInTheDocument();
+ expect(screen.queryByText(/Unable to load Assistant & Patrol settings/)).not.toBeInTheDocument();
// Verify retry actually called getSettings again
expect(getSettingsMock).toHaveBeenCalledTimes(2);
@@ -471,7 +471,7 @@ describe('AISettings quickstart enablement flow', () => {
expect(getSettingsMock).toHaveBeenCalledTimes(1);
});
- fireEvent.click(screen.getByRole('button', { name: /enable ai services/i }));
+ fireEvent.click(screen.getByRole('button', { name: /enable assistant and patrol/i }));
await waitFor(() => {
expect(updateSettingsMock).toHaveBeenCalledWith({ enabled: true });
@@ -499,7 +499,7 @@ describe('AISettings quickstart enablement flow', () => {
expect(getSettingsMock).toHaveBeenCalledTimes(1);
});
- fireEvent.click(screen.getByRole('button', { name: /enable ai services/i }));
+ fireEvent.click(screen.getByRole('button', { name: /enable assistant and patrol/i }));
expect(updateSettingsMock).not.toHaveBeenCalled();
expect(
diff --git a/frontend-modern/src/components/Settings/__tests__/settingsArchitecture.test.ts b/frontend-modern/src/components/Settings/__tests__/settingsArchitecture.test.ts
index 38fff4096f..a65c78b9c6 100644
--- a/frontend-modern/src/components/Settings/__tests__/settingsArchitecture.test.ts
+++ b/frontend-modern/src/components/Settings/__tests__/settingsArchitecture.test.ts
@@ -352,7 +352,7 @@ const canonicalShellTitleExpectations = [
},
{
tab: 'system-ai',
- title: 'AI Services',
+ title: 'Assistant & Patrol',
source: aiSettingsPanelSource,
},
{
@@ -394,7 +394,7 @@ const canonicalShellTitleExpectations = [
describe('Settings architecture guardrails', () => {
it('keeps the primary AI settings toggle explicitly addressable and runtime-backed', () => {
- expect(aiSettingsPanelSource).toContain('ariaLabel="Enable AI services"');
+ expect(aiSettingsPanelSource).toContain('ariaLabel="Enable Assistant and Patrol"');
expect(aiSettingsPanelSource).toContain('await state.handleEnableRequest(newValue)');
});
diff --git a/frontend-modern/src/components/Settings/settingsHeaderMeta.ts b/frontend-modern/src/components/Settings/settingsHeaderMeta.ts
index 481caa2f04..a37afb00dd 100644
--- a/frontend-modern/src/components/Settings/settingsHeaderMeta.ts
+++ b/frontend-modern/src/components/Settings/settingsHeaderMeta.ts
@@ -30,8 +30,8 @@ export const SETTINGS_HEADER_META: SettingsHeaderMetaMap = {
description: 'Manage backup/snapshot polling plus configuration export and import workflows.',
},
'system-ai': {
- title: 'AI Services',
- description: 'Configure AI providers, models, Pulse Assistant, and Patrol.',
+ title: 'Assistant & Patrol',
+ description: 'Configure providers, models, Pulse Assistant, and Patrol.',
},
'system-relay': {
title: 'Remote Access',
diff --git a/frontend-modern/src/components/Settings/settingsNavCatalog.ts b/frontend-modern/src/components/Settings/settingsNavCatalog.ts
index 112f0119c0..9668bde076 100644
--- a/frontend-modern/src/components/Settings/settingsNavCatalog.ts
+++ b/frontend-modern/src/components/Settings/settingsNavCatalog.ts
@@ -126,7 +126,7 @@ export const SETTINGS_NAV_GROUPS: SettingsNavGroup[] = [
},
{
id: 'system-ai',
- label: 'AI Services',
+ label: 'Assistant & Patrol',
icon: Sparkles,
iconProps: { strokeWidth: 2 },
},
diff --git a/frontend-modern/src/components/Settings/useAISettingsState.ts b/frontend-modern/src/components/Settings/useAISettingsState.ts
index 662a28a087..1042ef1c7a 100644
--- a/frontend-modern/src/components/Settings/useAISettingsState.ts
+++ b/frontend-modern/src/components/Settings/useAISettingsState.ts
@@ -701,7 +701,7 @@ export const useAISettingsState = () => {
resetForm(updated);
syncModelCatalogForSettings(updated);
void runProviderPreflight(updated);
- notificationStore.success('Pulse Assistant settings saved');
+ notificationStore.success('Assistant & Patrol settings saved');
} catch (error) {
logger.error('[AISettings] Failed to save settings:', error);
notificationStore.error(getAISettingsSaveErrorMessage(error instanceof Error ? error.message : ''));
diff --git a/frontend-modern/src/utils/__tests__/aiSettingsPresentation.test.ts b/frontend-modern/src/utils/__tests__/aiSettingsPresentation.test.ts
index 9c1dcbc9db..143fc0fad8 100644
--- a/frontend-modern/src/utils/__tests__/aiSettingsPresentation.test.ts
+++ b/frontend-modern/src/utils/__tests__/aiSettingsPresentation.test.ts
@@ -89,7 +89,7 @@ describe('aiSettingsPresentation', () => {
).toEqual({
containerClassName: 'bg-amber-50 dark:bg-amber-900 text-amber-800 dark:text-amber-200',
dotClassName: 'bg-amber-400',
- summary: 'Configure at least one provider above to enable Pulse Assistant features',
+ summary: 'Configure at least one provider above to enable Pulse Assistant and Patrol.',
});
});
@@ -114,10 +114,10 @@ describe('aiSettingsPresentation', () => {
it('returns canonical ai settings loading and chat-session copy', () => {
expect(getAISettingsLoadingState()).toEqual({
- text: 'Loading Pulse Assistant settings...',
+ text: 'Loading Assistant & Patrol settings...',
});
expect(getAISettingsLoadErrorMessage()).toBe(
- 'Unable to load Pulse Assistant settings. Your configuration could not be retrieved.',
+ 'Unable to load Assistant & Patrol settings. Your configuration could not be retrieved.',
);
expect(getAISettingsRetryLabel()).toBe('Retry');
expect(getAIChatSessionsLoadingState()).toEqual({
@@ -139,11 +139,11 @@ describe('aiSettingsPresentation', () => {
expect(getAISessionDiffErrorMessage('git unavailable')).toBe('git unavailable');
expect(getAISessionRevertErrorMessage()).toBe('Unable to revert the session.');
expect(getAISessionRevertErrorMessage('conflict')).toBe('conflict');
- expect(getAISettingsSaveErrorMessage()).toBe('Unable to save Pulse Assistant settings.');
+ expect(getAISettingsSaveErrorMessage()).toBe('Unable to save Assistant & Patrol settings.');
expect(getAISettingsSaveErrorMessage('bad request')).toBe('bad request');
expect(getAICredentialsClearErrorMessage()).toBe('Unable to clear credentials.');
expect(getAICredentialsClearErrorMessage('permission denied')).toBe('permission denied');
- expect(getAISettingsToggleErrorMessage()).toBe('Unable to update Pulse Assistant settings.');
+ expect(getAISettingsToggleErrorMessage()).toBe('Unable to update Assistant & Patrol settings.');
expect(getAISettingsToggleErrorMessage('rate limited')).toBe('rate limited');
});
});
diff --git a/frontend-modern/src/utils/aiSettingsPresentation.ts b/frontend-modern/src/utils/aiSettingsPresentation.ts
index ef102573e3..bcfd1d0d1c 100644
--- a/frontend-modern/src/utils/aiSettingsPresentation.ts
+++ b/frontend-modern/src/utils/aiSettingsPresentation.ts
@@ -24,7 +24,7 @@ const AI_OAUTH_ERROR_MESSAGES: Record<string, string> = {
export const AI_SETTINGS_LOAD_MODELS_ERROR = 'Unable to load models.';
export const AI_SETTINGS_LOAD_CHAT_SESSIONS_ERROR = 'Unable to load chat sessions.';
export const AI_SETTINGS_LOAD_FAILURE_MESSAGE =
- 'Unable to load Pulse Assistant settings. Your configuration could not be retrieved.';
+ 'Unable to load Assistant & Patrol settings. Your configuration could not be retrieved.';
export const AI_SETTINGS_LOAD_RETRY_LABEL = 'Retry';
export function getAIProviderTestResultTextClass(success: boolean): string {
@@ -71,7 +71,7 @@ export function getAISettingsReadinessPresentation(
return {
containerClassName: 'bg-amber-50 dark:bg-amber-900 text-amber-800 dark:text-amber-200',
dotClassName: 'bg-amber-400',
- summary: 'Configure at least one provider above to enable Pulse Assistant features',
+ summary: 'Configure at least one provider above to enable Pulse Assistant and Patrol.',
};
}
@@ -81,7 +81,7 @@ export function getAIOAuthErrorMessage(errorCode: string): string {
export function getAISettingsLoadingState() {
return {
- text: 'Loading Pulse Assistant settings...',
+ text: 'Loading Assistant & Patrol settings...',
} as const;
}
@@ -132,7 +132,7 @@ export function getAISessionRevertErrorMessage(message?: string | null) {
export function getAISettingsSaveErrorMessage(message?: string | null) {
const detail = (message || '').trim();
- return detail || 'Unable to save Pulse Assistant settings.';
+ return detail || 'Unable to save Assistant & Patrol settings.';
}
export function getAICredentialsClearErrorMessage(message?: string | null) {
@@ -142,5 +142,5 @@ export function getAICredentialsClearErrorMessage(message?: string | null) {
export function getAISettingsToggleErrorMessage(message?: string | null) {
const detail = (message || '').trim();
- return detail || 'Unable to update Pulse Assistant settings.';
+ return detail || 'Unable to update Assistant & Patrol settings.';
}
diff --git a/tests/integration/tests/10-v6-license-activation.spec.ts b/tests/integration/tests/10-v6-license-activation.spec.ts
index 0693eb4292..258f9e5eff 100644
--- a/tests/integration/tests/10-v6-license-activation.spec.ts
+++ b/tests/integration/tests/10-v6-license-activation.spec.ts
@@ -226,7 +226,7 @@ test.describe.serial('V6 license activation flow', () => {
expect(ent.subscription_state).toBe('active');
await page.goto('/settings/system-ai');
- await expect(page.getByRole('heading', { name: 'AI Services' }).first()).toBeVisible();
+ await expect(page.getByRole('heading', { name: 'Assistant & Patrol' }).first()).toBeVisible();
const preSettingsRes = await apiRequest(page, '/api/settings/ai');
expect(preSettingsRes.ok(), `AI settings request failed: ${preSettingsRes.status()}`).toBeTruthy();
@@ -236,7 +236,7 @@ test.describe.serial('V6 license activation flow', () => {
expect(preSettings.quickstart_credits_remaining).toBe(25);
expect(preSettings.quickstart_blocked_reason || '').toBe('');
- const enableAI = page.getByRole('button', { name: 'Enable AI services' });
+ const enableAI = page.getByRole('button', { name: 'Enable Assistant and Patrol' });
await expect(enableAI).toBeVisible();
if (await page.getByText(/^Disabled$/).isVisible()) {
await enableAI.click();
diff --git a/tests/integration/tests/51-quickstart-cross-surface.spec.ts b/tests/integration/tests/51-quickstart-cross-surface.spec.ts
index 83d31463d2..b7b4e957ed 100644
--- a/tests/integration/tests/51-quickstart-cross-surface.spec.ts
+++ b/tests/integration/tests/51-quickstart-cross-surface.spec.ts
@@ -479,7 +479,7 @@ test.describe("Quickstart cross-surface browser contract", () => {
});
await page.goto("/settings/system-ai", { waitUntil: "domcontentloaded" });
- await expect(page.getByRole("heading", { name: "AI Services", level: 1 })).toBeVisible();
+ await expect(page.getByRole("heading", { name: "Assistant & Patrol", level: 1 })).toBeVisible();
const response = await browserApiRequest(page, "/api/settings/ai/update", "PUT", {
enabled: true,
@@ -652,9 +652,9 @@ test.describe("Quickstart cross-surface browser contract", () => {
});
await page.goto("/settings/system-ai", { waitUntil: "domcontentloaded" });
- await expect(page.getByRole("heading", { name: "AI Services", level: 1 })).toBeVisible();
+ await expect(page.getByRole("heading", { name: "Assistant & Patrol", level: 1 })).toBeVisible();
- await page.getByRole("button", { name: "Enable AI services" }).click();
+ await page.getByRole("button", { name: "Enable Assistant and Patrol" }).click();
await expect.poll(() => surface.updateRequests.length).toBe(1);
expect(surface.updateRequests[0]).toMatchObject({ enabled: true });
diff --git a/tests/integration/tests/52-ai-settings-provider-setup.spec.ts b/tests/integration/tests/52-ai-settings-provider-setup.spec.ts
index d64aad7dc5..78e8e02abc 100644
--- a/tests/integration/tests/52-ai-settings-provider-setup.spec.ts
+++ b/tests/integration/tests/52-ai-settings-provider-setup.spec.ts
@@ -107,7 +107,7 @@ test.describe("AI settings provider setup", () => {
});
await page.goto("/settings/system-ai", { waitUntil: "domcontentloaded" });
- await expect(page.getByRole("heading", { name: "AI Services", level: 1 })).toBeVisible();
+ await expect(page.getByRole("heading", { name: "Assistant & Patrol", level: 1 })).toBeVisible();
await page.getByRole("button", { name: /enable ai services/i }).click();
const setupDialog = page.getByRole("dialog", { name: "Set up Pulse Assistant" });