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.

Align Patrol assessment handoff target

rcourtman8176f2e8ca9e
diff --git a/docs/release-control/v6/internal/subsystems/ai-runtime.md b/docs/release-control/v6/internal/subsystems/ai-runtime.md
index d7d888b4d7..98aa84029d 100644
--- a/docs/release-control/v6/internal/subsystems/ai-runtime.md
+++ b/docs/release-control/v6/internal/subsystems/ai-runtime.md
@@ -86,7 +86,10 @@ runtime cost control, and shared AI transport surfaces.
instead of generic dashboard briefs. Source-owned handoff helpers may attach
bounded suggested prompts to that briefing, but those prompts are only input
starters; they must not auto-submit, bypass approval mode, or carry raw
- command payloads. While such a handoff is attached, the Assistant empty
+ command payloads. Patrol assessment handoffs must use the same
+ `patrol-assessment` target identity for live opens and restored sessions
+ rather than inheriting retired dashboard context. While such a handoff is
+ attached, the Assistant empty
message state must also remain source-named and must not fall back to generic
cluster/system starter prompts that compete with the attached briefing.
Reloaded Assistant sessions may consume the backend-owned
diff --git a/docs/release-control/v6/internal/subsystems/api-contracts.md b/docs/release-control/v6/internal/subsystems/api-contracts.md
index d199211016..07b8d9b330 100644
--- a/docs/release-control/v6/internal/subsystems/api-contracts.md
+++ b/docs/release-control/v6/internal/subsystems/api-contracts.md
@@ -514,6 +514,8 @@ the canonical monitored-system blocked payload.
structured handoff actions with approval ID/status/risk/target/request/expiry
metadata, action plan identity/policy/expiry, dry-run posture, and command
counts instead of pasting page-local UI text or raw command payloads into chat,
+ the drawer target must stay `patrol-assessment` rather than a retired
+ dashboard target,
and may derive visible action labels, safety notes, and approval-aware
suggested prompts plus first-turn prompt emphasis from that same safe metadata
plus the current disabled reason for a Patrol-owned recommended action when
diff --git a/docs/release-control/v6/internal/subsystems/frontend-primitives.md b/docs/release-control/v6/internal/subsystems/frontend-primitives.md
index ec77204c91..0fdbf787b5 100644
--- a/docs/release-control/v6/internal/subsystems/frontend-primitives.md
+++ b/docs/release-control/v6/internal/subsystems/frontend-primitives.md
@@ -211,6 +211,10 @@ work extends shared components instead of creating new local variants.
Session-load and new-conversation transitions must be success-bound: if the
underlying session operation fails, the shared drawer store must not clear or
replace the current scoped handoff context.
+ Live Patrol assessment drawer opens must use that same
+ `patrol-assessment`/`pulse-patrol-assessment` target identity rather than a
+ retired dashboard target, so first-open and restored-session chrome remain
+ source-named.
9. `frontend-modern/src/utils/platformSupportManifest.generated.ts` shared with `unified-resources`: the generated platform support projection is both a canonical unified-resource platform union boundary and a shared frontend source/platform vocabulary boundary.
10. `frontend-modern/src/utils/sourcePlatforms.ts` shared with `unified-resources`: the source platform normalizer is both a canonical unified-resource source adapter boundary and a shared frontend source/platform vocabulary boundary.
That shared boundary must preserve `availability` as the agentless
diff --git a/docs/release-control/v6/internal/subsystems/patrol-intelligence.md b/docs/release-control/v6/internal/subsystems/patrol-intelligence.md
index 6dfb75dde6..0a4e07a2fc 100644
--- a/docs/release-control/v6/internal/subsystems/patrol-intelligence.md
+++ b/docs/release-control/v6/internal/subsystems/patrol-intelligence.md
@@ -247,7 +247,11 @@ Patrol-specific presentation helpers.
kind when present, plus the current action-disabled reason when the visible
Patrol-owned action is unavailable, so Assistant explains the same
operator-facing priority and current availability shown in the summary card
- instead of inventing a separate next step. Active-finding
+ instead of inventing a separate next step. Assessment-level handoffs must
+ identify the drawer target as
+ `patrol-assessment` with `targetId=pulse-patrol-assessment`, matching saved
+ session restore semantics rather than the retired dashboard target.
+ Active-finding
summaries may include live pending approval posture only as safe metadata:
approval ID, pending status, risk, target, requested/expiry timestamps,
action plan identity, approval policy, plan expiry, dry-run posture, and
diff --git a/frontend-modern/src/features/patrol/__tests__/patrolInvestigationContextModel.test.ts b/frontend-modern/src/features/patrol/__tests__/patrolInvestigationContextModel.test.ts
index 00bad9f8c1..f84cba38ed 100644
--- a/frontend-modern/src/features/patrol/__tests__/patrolInvestigationContextModel.test.ts
+++ b/frontend-modern/src/features/patrol/__tests__/patrolInvestigationContextModel.test.ts
@@ -362,6 +362,11 @@ describe('patrolInvestigationContextModel', () => {
expect(handoff.context.handoffContext).toContain(
'Supporting Context: 100 recent changes · 29 correlations · 116 policy-covered resources',
);
+ expect(handoff.context).toMatchObject({
+ targetType: 'patrol-assessment',
+ targetId: 'pulse-patrol-assessment',
+ autonomousMode: false,
+ });
expect(handoff.context.context).toMatchObject({
recommendedNextStepTitle: 'Verify full coverage',
recommendedNextStepActionKind: 'run_patrol',
diff --git a/frontend-modern/src/features/patrol/patrolInvestigationContextModel.ts b/frontend-modern/src/features/patrol/patrolInvestigationContextModel.ts
index d768acd9f8..301a893f1e 100644
--- a/frontend-modern/src/features/patrol/patrolInvestigationContextModel.ts
+++ b/frontend-modern/src/features/patrol/patrolInvestigationContextModel.ts
@@ -550,7 +550,7 @@ export function buildPatrolAssessmentAssistantHandoff(
return {
prompt: buildPatrolAssessmentAssistantPrompt(input, title, description, handoffActions),
context: {
- targetType: 'dashboard',
+ targetType: 'patrol-assessment',
targetId: 'pulse-patrol-assessment',
autonomousMode: false,
handoffContext,