@elizaos/app-core 2.0.0-alpha.335 → 2.0.0-alpha.337

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (62) hide show
  1. package/apps/app-lifeops/src/routes/lifeops-routes.d.ts.map +1 -1
  2. package/apps/app-lifeops/src/routes/lifeops-routes.js +10 -1
  3. package/i18n/locales/en.json +5 -5
  4. package/package.json +5 -5
  5. package/packages/agent/src/runtime/eliza.d.ts.map +1 -1
  6. package/packages/agent/src/runtime/eliza.js +7 -2
  7. package/packages/app-core/src/api/automations-compat-routes.js +1 -1
  8. package/packages/app-core/src/api/client-n8n.d.ts +4 -1
  9. package/packages/app-core/src/api/client-n8n.d.ts.map +1 -1
  10. package/packages/app-core/src/api/client-n8n.js +18 -0
  11. package/packages/app-core/src/api/client-types-chat.d.ts +37 -0
  12. package/packages/app-core/src/api/client-types-chat.d.ts.map +1 -1
  13. package/packages/app-core/src/api/n8n-routes.d.ts +6 -0
  14. package/packages/app-core/src/api/n8n-routes.d.ts.map +1 -1
  15. package/packages/app-core/src/api/n8n-routes.js +334 -0
  16. package/packages/app-core/src/components/character/CharacterEditorPanels.d.ts.map +1 -1
  17. package/packages/app-core/src/components/character/CharacterEditorPanels.js +192 -85
  18. package/packages/app-core/src/components/character/CharacterExperienceWorkspace.d.ts.map +1 -1
  19. package/packages/app-core/src/components/character/CharacterExperienceWorkspace.js +182 -31
  20. package/packages/app-core/src/components/character/CharacterHubView.d.ts.map +1 -1
  21. package/packages/app-core/src/components/character/CharacterHubView.js +253 -23
  22. package/packages/app-core/src/components/character/CharacterOverviewSection.d.ts +14 -1
  23. package/packages/app-core/src/components/character/CharacterOverviewSection.d.ts.map +1 -1
  24. package/packages/app-core/src/components/character/CharacterOverviewSection.js +35 -8
  25. package/packages/app-core/src/components/character/character-hub-helpers.d.ts.map +1 -1
  26. package/packages/app-core/src/components/character/character-hub-helpers.js +3 -7
  27. package/packages/app-core/src/components/pages/AutomationsView.d.ts.map +1 -1
  28. package/packages/app-core/src/components/pages/AutomationsView.js +523 -274
  29. package/packages/app-core/src/components/pages/HeartbeatForm.d.ts.map +1 -1
  30. package/packages/app-core/src/components/pages/HeartbeatForm.js +11 -13
  31. package/packages/app-core/src/components/pages/KnowledgeView.d.ts.map +1 -1
  32. package/packages/app-core/src/components/pages/KnowledgeView.js +20 -6
  33. package/packages/app-core/src/components/pages/RelationshipsGraphPanel.d.ts +2 -1
  34. package/packages/app-core/src/components/pages/RelationshipsGraphPanel.d.ts.map +1 -1
  35. package/packages/app-core/src/components/pages/RelationshipsGraphPanel.js +3 -3
  36. package/packages/app-core/src/components/pages/WorkflowGraphViewer.d.ts +0 -9
  37. package/packages/app-core/src/components/pages/WorkflowGraphViewer.d.ts.map +1 -1
  38. package/packages/app-core/src/components/pages/WorkflowGraphViewer.js +52 -26
  39. package/packages/app-core/src/components/pages/knowledge-detail.d.ts.map +1 -1
  40. package/packages/app-core/src/components/pages/knowledge-detail.js +28 -2
  41. package/packages/app-core/src/components/pages/page-scoped-conversations.d.ts +1 -1
  42. package/packages/app-core/src/components/pages/page-scoped-conversations.js +4 -4
  43. package/packages/app-core/src/components/pages/relationships/RelationshipsPersonPanels.d.ts +2 -1
  44. package/packages/app-core/src/components/pages/relationships/RelationshipsPersonPanels.d.ts.map +1 -1
  45. package/packages/app-core/src/components/pages/relationships/RelationshipsPersonPanels.js +69 -32
  46. package/packages/app-core/src/components/pages/relationships/RelationshipsSidebar.d.ts +1 -6
  47. package/packages/app-core/src/components/pages/relationships/RelationshipsSidebar.d.ts.map +1 -1
  48. package/packages/app-core/src/components/pages/relationships/RelationshipsSidebar.js +4 -4
  49. package/packages/app-core/src/components/pages/relationships/RelationshipsWorkspaceView.d.ts +2 -1
  50. package/packages/app-core/src/components/pages/relationships/RelationshipsWorkspaceView.d.ts.map +1 -1
  51. package/packages/app-core/src/components/pages/relationships/RelationshipsWorkspaceView.js +25 -15
  52. package/packages/app-core/src/i18n/locales/en.json +5 -5
  53. package/packages/app-core/src/registry/generate-apps.js +2 -2
  54. package/packages/app-core/src/runtime/eliza.d.ts.map +1 -1
  55. package/packages/app-core/src/runtime/eliza.js +6 -1
  56. package/packages/app-core/src/services/n8n-dispatch.d.ts +10 -2
  57. package/packages/app-core/src/services/n8n-dispatch.d.ts.map +1 -1
  58. package/packages/app-core/src/services/n8n-dispatch.js +102 -8
  59. package/packages/shared/src/contracts/lifeops.d.ts +4 -0
  60. package/packages/shared/src/contracts/lifeops.d.ts.map +1 -1
  61. package/packages/typescript/src/features/advanced-capabilities/clipboard/services/clipboardService.d.ts.map +1 -1
  62. package/packages/typescript/src/features/advanced-capabilities/clipboard/services/clipboardService.js +6 -1
@@ -1,8 +1,29 @@
1
- import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
1
+ import { jsxs as _jsxs, jsx as _jsx } from "react/jsx-runtime";
2
2
  import { Button, MetaPill, PagePanel } from "@elizaos/ui";
3
3
  import { formatDateTime } from "../../../utils/format";
4
4
  import { RelationshipsIdentityCluster } from "../RelationshipsIdentityCluster";
5
5
  import { buildAdditionalHighlights, profilePrimaryValue, profileSourceLabel, topContacts, } from "./relationships-utils";
6
+ const PANEL_PREVIEW_LIMIT = 4;
7
+ const CONVERSATION_PREVIEW_LIMIT = 2;
8
+ const MESSAGE_PREVIEW_LIMIT = 3;
9
+ const TEXT_PREVIEW_LENGTH = 420;
10
+ function boundedText(value, maxLength = TEXT_PREVIEW_LENGTH) {
11
+ const trimmed = value.trim();
12
+ return trimmed.length > maxLength
13
+ ? `${trimmed.slice(0, maxLength - 1)}...`
14
+ : trimmed;
15
+ }
16
+ function visibleItems(items, limit = PANEL_PREVIEW_LIMIT) {
17
+ return items.slice(0, limit);
18
+ }
19
+ function overflowCount(items, limit = PANEL_PREVIEW_LIMIT) {
20
+ return Math.max(0, items.length - limit);
21
+ }
22
+ function MoreItems({ count, children, }) {
23
+ if (count <= 0)
24
+ return null;
25
+ return (_jsxs("details", { className: "mt-3 rounded-xl border border-border/24 bg-card/24 px-3 py-2", children: [_jsxs("summary", { className: "cursor-pointer text-xs-tight font-semibold text-muted transition hover:text-txt", children: ["Show ", count, " more"] }), _jsx("div", { className: "mt-3 space-y-3", children: children })] }));
26
+ }
6
27
  function resolvePrimaryAvatar(person) {
7
28
  for (const profile of person.profiles) {
8
29
  if (profile.avatarUrl?.trim()) {
@@ -39,50 +60,66 @@ function relationshipCounterpartName(relationship, groupId) {
39
60
  }
40
61
  function ProfileCard({ person, profile, }) {
41
62
  const primaryValue = profilePrimaryValue(person, profile.source) ?? "Unknown profile";
42
- return (_jsx("div", { className: "rounded-xl border border-border/24 bg-card/35 px-3 py-3", children: _jsxs("div", { className: "flex items-start gap-3", children: [profile.avatarUrl ? (_jsx("img", { src: profile.avatarUrl, alt: "", className: "mt-0.5 h-10 w-10 rounded-full border border-border/24 object-cover" })) : null, _jsxs("div", { className: "min-w-0 flex-1", children: [_jsxs("div", { className: "flex flex-wrap items-center gap-2", children: [_jsx("div", { className: "text-2xs font-semibold uppercase tracking-[0.12em] text-muted/70", children: profileSourceLabel(profile.source) }), profile.canonical ? _jsx(MetaPill, { compact: true, children: "Canonical" }) : null] }), _jsx("div", { className: "mt-1 text-sm font-semibold text-txt", children: primaryValue }), _jsxs("div", { className: "mt-1 text-xs leading-5 text-muted", children: [profile.handle ? `Handle ${profile.handle}` : null, profile.handle && profile.userId ? " · " : null, profile.userId ? `ID ${profile.userId}` : null, !profile.handle && !profile.userId
43
- ? `Entity ${profile.entityId}`
44
- : null] }), profile.displayName && profile.displayName !== primaryValue ? (_jsxs("div", { className: "mt-1 text-xs leading-5 text-muted", children: ["Profile name ", profile.displayName] })) : null] })] }) }));
63
+ const secondary = profile.handle ??
64
+ (profile.displayName && profile.displayName !== primaryValue
65
+ ? profile.displayName
66
+ : null);
67
+ return (_jsx("div", { className: "rounded-xl border border-border/24 bg-card/35 px-3 py-3", children: _jsxs("div", { className: "flex items-start gap-3", children: [profile.avatarUrl ? (_jsx("img", { src: profile.avatarUrl, alt: "", className: "mt-0.5 h-10 w-10 rounded-full border border-border/24 object-cover" })) : null, _jsxs("div", { className: "min-w-0 flex-1", children: [_jsxs("div", { className: "flex flex-wrap items-center gap-2", children: [_jsx("div", { className: "text-2xs font-semibold uppercase tracking-[0.12em] text-muted/70", children: profileSourceLabel(profile.source) }), profile.canonical ? _jsx(MetaPill, { compact: true, children: "Canonical" }) : null] }), _jsx("div", { className: "mt-1 text-sm font-semibold text-txt", children: primaryValue }), secondary ? (_jsx("div", { className: "mt-1 text-xs leading-5 text-muted", children: profile.handle ? `Handle ${secondary}` : `Profile ${secondary}` })) : null] })] }) }));
45
68
  }
46
- export function RelationshipsPersonSummaryPanel({ person, onViewMemories, }) {
69
+ export function RelationshipsPersonSummaryPanel({ person, compact = false, onViewMemories, }) {
47
70
  const avatarUrl = resolvePrimaryAvatar(person);
48
71
  const contacts = topContacts(person);
49
72
  const hasProfiles = person.profiles.length > 0;
50
73
  const additionalHighlights = buildAdditionalHighlights(person);
51
- return (_jsxs(PagePanel, { variant: "padded", className: "space-y-4", children: [_jsxs("div", { className: "flex flex-wrap items-start justify-between gap-3", children: [_jsxs("div", { className: "flex items-start gap-4", children: [avatarUrl ? (_jsx("img", { src: avatarUrl, alt: "", className: "hidden h-16 w-16 rounded-2xl border border-border/24 object-cover shadow-sm sm:block" })) : null, _jsxs("div", { children: [_jsx("div", { className: "text-xs-tight font-semibold uppercase tracking-[0.16em] text-muted/70", children: "Canonical person" }), _jsx("div", { className: "mt-2 text-[1.75rem] font-semibold leading-tight text-txt", children: person.displayName }), _jsx("p", { className: "mt-3 max-w-2xl text-sm leading-6 text-muted", children: personSummary(person) })] })] }), _jsxs("div", { className: "flex flex-wrap items-center gap-2", children: [person.isOwner ? _jsx(MetaPill, { compact: true, children: "Owner" }) : null, _jsxs(MetaPill, { compact: true, children: [person.memberEntityIds.length, " identities"] }), _jsxs(MetaPill, { compact: true, children: [person.factCount, " facts"] }), _jsxs(MetaPill, { compact: true, children: [person.relationshipCount, " links"] }), onViewMemories ? (_jsx(Button, { type: "button", size: "sm", variant: "outline", className: "ml-1 h-7 rounded-full px-3 text-2xs font-semibold tracking-[0.12em]", onClick: () => onViewMemories(person.memberEntityIds), children: "View memories" })) : null] })] }), _jsxs("div", { className: "grid gap-4 lg:grid-cols-[minmax(0,1fr)_22rem]", children: [_jsxs("div", { className: "grid gap-3 sm:grid-cols-2", children: [_jsxs(PagePanel, { variant: "inset", className: "px-4 py-4", children: [_jsx("div", { className: "text-xs-tight uppercase tracking-[0.14em] text-muted/70", children: "Platforms" }), _jsx("div", { className: "mt-2 text-sm font-semibold text-txt", children: listValue(person.platforms, "No linked platforms") })] }), _jsxs(PagePanel, { variant: "inset", className: "px-4 py-4", children: [_jsx("div", { className: "text-xs-tight uppercase tracking-[0.14em] text-muted/70", children: "Last interaction" }), _jsx("div", { className: "mt-2 text-sm font-semibold text-txt", children: formatDateTime(person.lastInteractionAt, { fallback: "n/a" }) })] }), _jsxs(PagePanel, { variant: "inset", className: "px-4 py-4", children: [_jsx("div", { className: "text-xs-tight uppercase tracking-[0.14em] text-muted/70", children: "Categories" }), _jsx("div", { className: "mt-2 text-sm font-semibold text-txt", children: listValue(person.categories, "No categories") })] }), _jsxs(PagePanel, { variant: "inset", className: "px-4 py-4", children: [_jsx("div", { className: "text-xs-tight uppercase tracking-[0.14em] text-muted/70", children: "Tags" }), _jsx("div", { className: "mt-2 text-sm font-semibold text-txt", children: listValue(person.tags, "No tags") })] }), additionalHighlights.length > 0 ? (_jsxs(PagePanel, { variant: "surface", className: "sm:col-span-2 px-4 py-4", children: [_jsx("div", { className: "text-xs-tight uppercase tracking-[0.14em] text-muted/70", children: "Additional context" }), _jsx("div", { className: "mt-3 grid gap-2 sm:grid-cols-2", children: additionalHighlights.map((row) => (_jsxs("div", { className: "rounded-xl border border-border/24 bg-card/35 px-3 py-3", children: [_jsx("div", { className: "text-2xs font-semibold uppercase tracking-[0.12em] text-muted/70", children: row.label }), _jsx("div", { className: "mt-1 text-sm font-semibold text-txt", children: row.value })] }, `${row.label}:${row.value}`))) })] })) : null, _jsxs(PagePanel, { variant: "surface", className: "sm:col-span-2 px-4 py-4", children: [_jsx("div", { className: "text-xs-tight uppercase tracking-[0.14em] text-muted/70", children: "Reachability" }), contacts.length > 0 ? (_jsx("div", { className: "mt-3 grid gap-2 sm:grid-cols-2", children: contacts.map((contact) => (_jsxs("div", { className: "rounded-xl border border-border/24 bg-card/35 px-3 py-3", children: [_jsx("div", { className: "text-2xs font-semibold uppercase tracking-[0.12em] text-muted/70", children: contact.label }), _jsx("div", { className: "mt-1 text-sm font-semibold text-txt", children: contact.value })] }, `${contact.label}:${contact.value}`))) })) : (_jsx("p", { className: "mt-3 text-sm leading-6 text-muted", children: "No direct contact channels are stored for this person yet." }))] }), hasProfiles ? (_jsxs(PagePanel, { variant: "surface", className: "sm:col-span-2 px-4 py-4", children: [_jsx("div", { className: "text-xs-tight uppercase tracking-[0.14em] text-muted/70", children: "Profiles" }), _jsx("div", { className: "mt-3 grid gap-2 sm:grid-cols-2", children: person.profiles.map((profile) => (_jsx(ProfileCard, { person: person, profile: profile }, `${profile.source}:${profile.entityId}`))) })] })) : null] }), _jsx(PagePanel, { variant: "surface", className: "px-4 py-4", children: _jsx(RelationshipsIdentityCluster, { person: person }) })] })] }));
74
+ return (_jsxs(PagePanel, { variant: "padded", className: compact ? "space-y-3" : "space-y-4", children: [_jsxs("div", { className: "flex flex-wrap items-start justify-between gap-3", children: [_jsxs("div", { className: "flex min-w-0 items-start gap-3", children: [avatarUrl ? (_jsx("img", { src: avatarUrl, alt: "", className: `${compact ? "h-12 w-12 rounded-xl" : "h-16 w-16 rounded-2xl"} hidden border border-border/24 object-cover shadow-sm sm:block` })) : null, _jsxs("div", { className: "min-w-0", children: [_jsx("div", { className: "text-xs-tight font-semibold uppercase tracking-[0.16em] text-muted/70", children: "Canonical person" }), _jsx("div", { className: `${compact ? "mt-1 text-xl" : "mt-2 text-[1.75rem]"} break-words font-semibold leading-tight text-txt`, children: person.displayName }), _jsx("p", { className: "mt-2 max-w-2xl text-sm leading-6 text-muted", children: personSummary(person) })] })] }), _jsxs("div", { className: "flex flex-wrap items-center gap-2", children: [person.isOwner ? _jsx(MetaPill, { compact: true, children: "Owner" }) : null, _jsxs(MetaPill, { compact: true, children: [person.memberEntityIds.length, " identities"] }), _jsxs(MetaPill, { compact: true, children: [person.factCount, " facts"] }), _jsxs(MetaPill, { compact: true, children: [person.relationshipCount, " links"] }), onViewMemories ? (_jsx(Button, { type: "button", size: "sm", variant: "outline", className: "ml-1 h-7 rounded-full px-3 text-2xs font-semibold tracking-[0.12em]", onClick: () => onViewMemories(person.memberEntityIds), children: "View memories" })) : null] })] }), _jsxs("div", { className: compact
75
+ ? "space-y-3"
76
+ : "grid gap-4 lg:grid-cols-[minmax(0,1fr)_22rem]", children: [_jsxs("div", { className: "grid gap-3 sm:grid-cols-2", children: [_jsxs(PagePanel, { variant: "inset", className: "px-4 py-4", children: [_jsx("div", { className: "text-xs-tight uppercase tracking-[0.14em] text-muted/70", children: "Platforms" }), _jsx("div", { className: "mt-2 text-sm font-semibold text-txt", children: listValue(person.platforms, "No linked platforms") })] }), _jsxs(PagePanel, { variant: "inset", className: "px-4 py-4", children: [_jsx("div", { className: "text-xs-tight uppercase tracking-[0.14em] text-muted/70", children: "Last interaction" }), _jsx("div", { className: "mt-2 text-sm font-semibold text-txt", children: formatDateTime(person.lastInteractionAt, { fallback: "n/a" }) })] }), _jsxs(PagePanel, { variant: "inset", className: "px-4 py-4", children: [_jsx("div", { className: "text-xs-tight uppercase tracking-[0.14em] text-muted/70", children: "Categories" }), _jsx("div", { className: "mt-2 text-sm font-semibold text-txt", children: listValue(person.categories, "No categories") })] }), _jsxs(PagePanel, { variant: "inset", className: "px-4 py-4", children: [_jsx("div", { className: "text-xs-tight uppercase tracking-[0.14em] text-muted/70", children: "Tags" }), _jsx("div", { className: "mt-2 text-sm font-semibold text-txt", children: listValue(person.tags, "No tags") })] }), additionalHighlights.length > 0 ? (_jsxs(PagePanel, { variant: "surface", className: "sm:col-span-2 px-4 py-4", children: [_jsx("div", { className: "text-xs-tight uppercase tracking-[0.14em] text-muted/70", children: "Additional context" }), _jsx("div", { className: "mt-3 grid gap-2 sm:grid-cols-2", children: additionalHighlights.map((row) => (_jsxs("div", { className: "rounded-xl border border-border/24 bg-card/35 px-3 py-3", children: [_jsx("div", { className: "text-2xs font-semibold uppercase tracking-[0.12em] text-muted/70", children: row.label }), _jsx("div", { className: "mt-1 text-sm font-semibold text-txt", children: row.value })] }, `${row.label}:${row.value}`))) })] })) : null, _jsxs(PagePanel, { variant: "surface", className: "sm:col-span-2 px-4 py-4", children: [_jsx("div", { className: "text-xs-tight uppercase tracking-[0.14em] text-muted/70", children: "Reachability" }), contacts.length > 0 ? (_jsx("div", { className: "mt-3 grid gap-2 sm:grid-cols-2", children: contacts.map((contact) => (_jsxs("div", { className: "rounded-xl border border-border/24 bg-card/35 px-3 py-3", children: [_jsx("div", { className: "text-2xs font-semibold uppercase tracking-[0.12em] text-muted/70", children: contact.label }), _jsx("div", { className: "mt-1 text-sm font-semibold text-txt", children: contact.value })] }, `${contact.label}:${contact.value}`))) })) : (_jsx("p", { className: "mt-3 text-sm leading-6 text-muted", children: "No direct contact channels are stored for this person yet." }))] }), hasProfiles && !compact ? _jsx(ProfilesPanel, { person: person }) : null] }), compact ? (_jsxs("details", { className: "rounded-xl border border-border/24 bg-card/24 px-3 py-2", children: [_jsx("summary", { className: "cursor-pointer text-xs-tight font-semibold text-muted transition hover:text-txt", children: "Profiles and identity cluster" }), _jsxs("div", { className: "mt-3 space-y-3", children: [hasProfiles ? _jsx(ProfilesPanel, { person: person }) : null, _jsx(PagePanel, { variant: "surface", className: "px-4 py-4", children: _jsx(RelationshipsIdentityCluster, { person: person }) })] })] })) : (_jsx(PagePanel, { variant: "surface", className: "px-4 py-4", children: _jsx(RelationshipsIdentityCluster, { person: person }) }))] })] }));
77
+ }
78
+ function ProfilesPanel({ person }) {
79
+ return (_jsxs(PagePanel, { variant: "surface", className: "sm:col-span-2 px-4 py-4", children: [_jsx("div", { className: "text-xs-tight uppercase tracking-[0.14em] text-muted/70", children: "Profiles" }), _jsx("div", { className: "mt-3 grid gap-2 sm:grid-cols-2", children: person.profiles.map((profile) => (_jsx(ProfileCard, { person: person, profile: profile }, `${profile.source}:${profile.entityId}`))) })] }));
52
80
  }
53
81
  export function RelationshipsFactsPanel({ person, }) {
54
- return (_jsxs(PagePanel, { variant: "surface", className: "px-4 py-4", children: [_jsxs("div", { className: "flex items-center justify-between gap-3", children: [_jsxs("div", { children: [_jsx("div", { className: "text-xs-tight font-semibold uppercase tracking-[0.16em] text-muted/70", children: "Facts" }), _jsx("div", { className: "mt-2 text-lg font-semibold text-txt", children: "Stored claims and memory-backed notes" })] }), _jsx(MetaPill, { compact: true, children: person.facts.length })] }), person.facts.length === 0 ? (_jsx("p", { className: "mt-4 text-sm leading-6 text-muted", children: "No facts have been extracted for this person yet." })) : (_jsx("div", { className: "mt-4 space-y-3", children: person.facts.map((fact) => {
55
- const evidenceCount = fact.evidenceMessageIds?.length ?? 0;
56
- return (_jsxs("div", { className: "rounded-2xl border border-border/24 bg-card/32 px-3.5 py-3", children: [_jsxs("div", { className: "flex flex-wrap items-center gap-2", children: [_jsx(MetaPill, { compact: true, children: fact.sourceType }), fact.field ? (_jsx(MetaPill, { compact: true, children: fact.field })) : null, fact.extractedInformation?.scope ? (_jsx(MetaPill, { compact: true, children: fact.extractedInformation.scope })) : null, typeof fact.confidence === "number" ? (_jsxs(MetaPill, { compact: true, children: [Math.round(fact.confidence * 100), "% confidence"] })) : null, fact.provenance?.evaluatorName ? (_jsx(MetaPill, { compact: true, children: fact.provenance.evaluatorName })) : null, evidenceCount > 0 ? (_jsxs(MetaPill, { compact: true, children: [evidenceCount, " evidence"] })) : null] }), _jsx("div", { className: "mt-2 text-sm leading-6 text-txt", children: fact.text }), _jsx("div", { className: "mt-2 text-xs text-muted", children: fact.lastReinforced
57
- ? `Reinforced ${formatDateTime(fact.lastReinforced, { fallback: "n/a" })}`
58
- : formatDateTime(fact.updatedAt, {
59
- fallback: "No timestamp",
60
- }) }), fact.provenance?.source ||
61
- fact.provenance?.sourceTrajectoryId ? (_jsxs("div", { className: "mt-2 text-xs leading-5 text-muted", children: [fact.provenance?.source
62
- ? `Source ${fact.provenance.source}`
63
- : null, fact.provenance?.source &&
64
- fact.provenance?.sourceTrajectoryId
65
- ? " · "
66
- : null, fact.provenance?.sourceTrajectoryId
67
- ? `Trajectory ${fact.provenance.sourceTrajectoryId}`
68
- : null] })) : null] }, fact.id));
69
- }) }))] }));
82
+ const shownFacts = visibleItems(person.facts);
83
+ const hiddenFacts = person.facts.slice(PANEL_PREVIEW_LIMIT);
84
+ const renderFact = (fact) => {
85
+ const evidenceCount = fact.evidenceMessageIds?.length ?? 0;
86
+ return (_jsxs("div", { className: "rounded-xl border border-border/24 bg-card/32 px-3.5 py-3", children: [_jsxs("div", { className: "flex flex-wrap items-center gap-2", children: [_jsx(MetaPill, { compact: true, children: fact.sourceType }), fact.field ? _jsx(MetaPill, { compact: true, children: fact.field }) : null, fact.extractedInformation?.scope ? (_jsx(MetaPill, { compact: true, children: fact.extractedInformation.scope })) : null, typeof fact.confidence === "number" ? (_jsxs(MetaPill, { compact: true, children: [Math.round(fact.confidence * 100), "% confidence"] })) : null, evidenceCount > 0 ? (_jsxs(MetaPill, { compact: true, children: [evidenceCount, " evidence"] })) : null] }), _jsx("div", { className: "mt-2 text-sm leading-6 text-txt", children: boundedText(fact.text) }), _jsx("div", { className: "mt-2 text-xs text-muted", children: fact.lastReinforced
87
+ ? `Reinforced ${formatDateTime(fact.lastReinforced, { fallback: "n/a" })}`
88
+ : formatDateTime(fact.updatedAt, {
89
+ fallback: "No timestamp",
90
+ }) }), fact.provenance?.source ? (_jsxs("div", { className: "mt-2 text-xs leading-5 text-muted", children: ["Source ", fact.provenance.source] })) : null] }, fact.id));
91
+ };
92
+ return (_jsxs(PagePanel, { variant: "surface", className: "px-4 py-4", children: [_jsxs("div", { className: "flex items-center justify-between gap-3", children: [_jsxs("div", { children: [_jsx("div", { className: "text-xs-tight font-semibold uppercase tracking-[0.16em] text-muted/70", children: "Facts" }), _jsx("div", { className: "mt-2 text-lg font-semibold text-txt", children: "Stored claims and memory-backed notes" })] }), _jsx(MetaPill, { compact: true, children: person.facts.length })] }), person.facts.length === 0 ? (_jsx("p", { className: "mt-4 text-sm leading-6 text-muted", children: "No facts have been extracted for this person yet." })) : (_jsxs("div", { className: "mt-4 space-y-3", children: [shownFacts.map(renderFact), _jsx(MoreItems, { count: overflowCount(person.facts), children: hiddenFacts.map(renderFact) })] }))] }));
70
93
  }
71
94
  export function RelationshipsConnectionsPanel({ person, }) {
72
- return (_jsxs(PagePanel, { variant: "surface", className: "px-4 py-4", children: [_jsxs("div", { className: "flex items-center justify-between gap-3", children: [_jsxs("div", { children: [_jsx("div", { className: "text-xs-tight font-semibold uppercase tracking-[0.16em] text-muted/70", children: "Relationships" }), _jsx("div", { className: "mt-2 text-lg font-semibold text-txt", children: "Strongest adjacent people in the graph" })] }), _jsx(MetaPill, { compact: true, children: person.relationships.length })] }), person.relationships.length === 0 ? (_jsx("p", { className: "mt-4 text-sm leading-6 text-muted", children: "No cross-person relationship edges have been aggregated for this identity group yet." })) : (_jsx("div", { className: "mt-4 space-y-3", children: person.relationships.map((relationship) => (_jsxs("div", { className: "rounded-2xl border border-border/24 bg-card/32 px-3.5 py-3", children: [_jsxs("div", { className: "flex flex-wrap items-center gap-2", children: [_jsx(MetaPill, { compact: true, children: relationship.strength.toFixed(2) }), _jsx(MetaPill, { compact: true, children: relationship.sentiment }), _jsxs(MetaPill, { compact: true, children: [relationship.interactionCount, " msgs"] })] }), _jsx("div", { className: "mt-2 text-sm font-semibold text-txt", children: relationshipCounterpartName(relationship, person.groupId) }), _jsx("div", { className: "mt-1 text-xs uppercase tracking-[0.12em] text-muted/70", children: relationship.relationshipTypes.join(" • ") || "unknown" }), _jsxs("div", { className: "mt-2 text-xs text-muted", children: ["Last interaction", " ", formatDateTime(relationship.lastInteractionAt, {
73
- fallback: "n/a",
74
- })] })] }, relationship.id))) }))] }));
95
+ const shownRelationships = visibleItems(person.relationships);
96
+ const hiddenRelationships = person.relationships.slice(PANEL_PREVIEW_LIMIT);
97
+ const renderRelationship = (relationship) => (_jsxs("div", { className: "rounded-xl border border-border/24 bg-card/32 px-3.5 py-3", children: [_jsxs("div", { className: "flex flex-wrap items-center gap-2", children: [_jsx(MetaPill, { compact: true, children: relationship.strength.toFixed(2) }), _jsx(MetaPill, { compact: true, children: relationship.sentiment }), _jsxs(MetaPill, { compact: true, children: [relationship.interactionCount, " msgs"] })] }), _jsx("div", { className: "mt-2 text-sm font-semibold text-txt", children: relationshipCounterpartName(relationship, person.groupId) }), _jsx("div", { className: "mt-1 text-xs uppercase tracking-[0.12em] text-muted/70", children: relationship.relationshipTypes.join(" • ") || "unknown" }), _jsxs("div", { className: "mt-2 text-xs text-muted", children: ["Last interaction", " ", formatDateTime(relationship.lastInteractionAt, {
98
+ fallback: "n/a",
99
+ })] })] }, relationship.id));
100
+ return (_jsxs(PagePanel, { variant: "surface", className: "px-4 py-4", children: [_jsxs("div", { className: "flex items-center justify-between gap-3", children: [_jsxs("div", { children: [_jsx("div", { className: "text-xs-tight font-semibold uppercase tracking-[0.16em] text-muted/70", children: "Relationships" }), _jsx("div", { className: "mt-2 text-lg font-semibold text-txt", children: "Strongest adjacent people in the graph" })] }), _jsx(MetaPill, { compact: true, children: person.relationships.length })] }), person.relationships.length === 0 ? (_jsx("p", { className: "mt-4 text-sm leading-6 text-muted", children: "No cross-person relationship edges have been aggregated for this identity group yet." })) : (_jsxs("div", { className: "mt-4 space-y-3", children: [shownRelationships.map(renderRelationship), _jsx(MoreItems, { count: overflowCount(person.relationships), children: hiddenRelationships.map(renderRelationship) })] }))] }));
75
101
  }
76
102
  export function RelationshipsConversationsPanel({ person, }) {
77
- return (_jsxs(PagePanel, { variant: "surface", className: "px-4 py-4", children: [_jsxs("div", { className: "flex items-center justify-between gap-3", children: [_jsxs("div", { children: [_jsx("div", { className: "text-xs-tight font-semibold uppercase tracking-[0.16em] text-muted/70", children: "Recent conversations" }), _jsx("div", { className: "mt-2 text-lg font-semibold text-txt", children: "Latest room snippets linked to this person" })] }), _jsx(MetaPill, { compact: true, children: person.recentConversations.length })] }), person.recentConversations.length === 0 ? (_jsx("p", { className: "mt-4 text-sm leading-6 text-muted", children: "No recent room snippets are available for this person yet." })) : (_jsx("div", { className: "mt-4 grid gap-4 xl:grid-cols-2", children: person.recentConversations.map((conversation) => (_jsxs("div", { className: "rounded-2xl border border-border/24 bg-card/32 px-3.5 py-3", children: [_jsxs("div", { className: "flex items-center justify-between gap-3", children: [_jsx("div", { className: "text-sm font-semibold text-txt", children: conversation.roomName }), _jsx("div", { className: "text-xs-tight text-muted", children: formatDateTime(conversation.lastActivityAt, {
78
- fallback: "n/a",
79
- }) })] }), _jsx("div", { className: "mt-3 space-y-2", children: conversation.messages.map((message) => (_jsxs("div", { className: "rounded-xl bg-card/50 px-3 py-2.5", children: [_jsx("div", { className: "text-xs-tight font-semibold uppercase tracking-[0.12em] text-muted/70", children: message.speaker }), _jsx("div", { className: "mt-1 text-sm leading-6 text-txt", children: message.text })] }, message.id))) })] }, conversation.roomId))) }))] }));
103
+ const shownConversations = visibleItems(person.recentConversations, CONVERSATION_PREVIEW_LIMIT);
104
+ const hiddenConversations = person.recentConversations.slice(CONVERSATION_PREVIEW_LIMIT);
105
+ const renderConversation = (conversation) => (_jsxs("div", { className: "rounded-xl border border-border/24 bg-card/32 px-3.5 py-3", children: [_jsxs("div", { className: "flex items-center justify-between gap-3", children: [_jsx("div", { className: "min-w-0 truncate text-sm font-semibold text-txt", children: conversation.roomName }), _jsx("div", { className: "shrink-0 text-xs-tight text-muted", children: formatDateTime(conversation.lastActivityAt, {
106
+ fallback: "n/a",
107
+ }) })] }), _jsxs("div", { className: "mt-3 space-y-2", children: [conversation.messages
108
+ .slice(0, MESSAGE_PREVIEW_LIMIT)
109
+ .map((message) => (_jsxs("div", { className: "rounded-xl bg-card/50 px-3 py-2.5", children: [_jsx("div", { className: "text-xs-tight font-semibold uppercase tracking-[0.12em] text-muted/70", children: message.speaker }), _jsx("div", { className: "mt-1 text-sm leading-6 text-txt", children: boundedText(message.text, 300) })] }, message.id))), conversation.messages.length > MESSAGE_PREVIEW_LIMIT ? (_jsxs("div", { className: "text-xs-tight text-muted", children: [conversation.messages.length - MESSAGE_PREVIEW_LIMIT, " older messages hidden"] })) : null] })] }, conversation.roomId));
110
+ return (_jsxs(PagePanel, { variant: "surface", className: "px-4 py-4", children: [_jsxs("div", { className: "flex items-center justify-between gap-3", children: [_jsxs("div", { children: [_jsx("div", { className: "text-xs-tight font-semibold uppercase tracking-[0.16em] text-muted/70", children: "Recent conversations" }), _jsx("div", { className: "mt-2 text-lg font-semibold text-txt", children: "Latest room snippets linked to this person" })] }), _jsx(MetaPill, { compact: true, children: person.recentConversations.length })] }), person.recentConversations.length === 0 ? (_jsx("p", { className: "mt-4 text-sm leading-6 text-muted", children: "No recent room snippets are available for this person yet." })) : (_jsxs("div", { className: "mt-4 grid gap-4 xl:grid-cols-2", children: [shownConversations.map(renderConversation), _jsx("div", { className: "xl:col-span-2", children: _jsx(MoreItems, { count: overflowCount(person.recentConversations, CONVERSATION_PREVIEW_LIMIT), children: _jsx("div", { className: "grid gap-4 xl:grid-cols-2", children: hiddenConversations.map(renderConversation) }) }) })] }))] }));
80
111
  }
81
112
  export function RelationshipsRelevantMemoriesPanel({ person, }) {
82
- return (_jsxs(PagePanel, { variant: "surface", className: "px-4 py-4", children: [_jsxs("div", { className: "flex items-center justify-between gap-3", children: [_jsxs("div", { children: [_jsx("div", { className: "text-xs-tight font-semibold uppercase tracking-[0.16em] text-muted/70", children: "Relevant memories" }), _jsx("div", { className: "mt-2 text-lg font-semibold text-txt", children: "Message memories tied to this person" })] }), _jsx(MetaPill, { compact: true, children: person.relevantMemories.length })] }), person.relevantMemories.length === 0 ? (_jsx("p", { className: "mt-4 text-sm leading-6 text-muted", children: "No relevant memories are attached to this person yet." })) : (_jsx("div", { className: "mt-4 space-y-3", children: person.relevantMemories.map((memory) => (_jsxs("div", { className: "rounded-2xl border border-border/24 bg-card/32 px-3.5 py-3", children: [_jsxs("div", { className: "flex flex-wrap items-center gap-2", children: [_jsx(MetaPill, { compact: true, children: memory.sourceType }), memory.source ? (_jsx(MetaPill, { compact: true, children: memory.source })) : null, memory.roomName ? (_jsx(MetaPill, { compact: true, children: memory.roomName })) : null] }), _jsx("div", { className: "mt-2 text-xs-tight font-semibold uppercase tracking-[0.12em] text-muted/70", children: memory.speaker }), _jsx("div", { className: "mt-1 text-sm leading-6 text-txt", children: memory.text }), _jsx("div", { className: "mt-2 text-xs text-muted", children: formatDateTime(memory.createdAt, { fallback: "No timestamp" }) })] }, memory.id))) }))] }));
113
+ const shownMemories = visibleItems(person.relevantMemories);
114
+ const hiddenMemories = person.relevantMemories.slice(PANEL_PREVIEW_LIMIT);
115
+ const renderMemory = (memory) => (_jsxs("div", { className: "rounded-xl border border-border/24 bg-card/32 px-3.5 py-3", children: [_jsxs("div", { className: "flex flex-wrap items-center gap-2", children: [_jsx(MetaPill, { compact: true, children: memory.sourceType }), memory.source ? _jsx(MetaPill, { compact: true, children: memory.source }) : null, memory.roomName ? (_jsx(MetaPill, { compact: true, children: memory.roomName })) : null] }), _jsx("div", { className: "mt-2 text-xs-tight font-semibold uppercase tracking-[0.12em] text-muted/70", children: memory.speaker }), _jsx("div", { className: "mt-1 text-sm leading-6 text-txt", children: boundedText(memory.text) }), _jsx("div", { className: "mt-2 text-xs text-muted", children: formatDateTime(memory.createdAt, { fallback: "No timestamp" }) })] }, memory.id));
116
+ return (_jsxs(PagePanel, { variant: "surface", className: "px-4 py-4", children: [_jsxs("div", { className: "flex items-center justify-between gap-3", children: [_jsxs("div", { children: [_jsx("div", { className: "text-xs-tight font-semibold uppercase tracking-[0.16em] text-muted/70", children: "Relevant memories" }), _jsx("div", { className: "mt-2 text-lg font-semibold text-txt", children: "Message memories tied to this person" })] }), _jsx(MetaPill, { compact: true, children: person.relevantMemories.length })] }), person.relevantMemories.length === 0 ? (_jsx("p", { className: "mt-4 text-sm leading-6 text-muted", children: "No relevant memories are attached to this person yet." })) : (_jsxs("div", { className: "mt-4 space-y-3", children: [shownMemories.map(renderMemory), _jsx(MoreItems, { count: overflowCount(person.relevantMemories), children: hiddenMemories.map(renderMemory) })] }))] }));
83
117
  }
84
118
  export function RelationshipsUserPreferencesPanel({ person, }) {
85
- return (_jsxs(PagePanel, { variant: "surface", className: "px-4 py-4", children: [_jsxs("div", { className: "flex items-center justify-between gap-3", children: [_jsxs("div", { children: [_jsx("div", { className: "text-xs-tight font-semibold uppercase tracking-[0.16em] text-muted/70", children: "User personality preferences" }), _jsx("div", { className: "mt-2 text-lg font-semibold text-txt", children: "User-scoped guidance learned from interactions" })] }), _jsx(MetaPill, { compact: true, children: person.userPersonalityPreferences.length })] }), person.userPersonalityPreferences.length === 0 ? (_jsx("p", { className: "mt-4 text-sm leading-6 text-muted", children: "No user-scoped personality preferences have been learned for this person yet." })) : (_jsx("div", { className: "mt-4 space-y-3", children: person.userPersonalityPreferences.map((preference) => (_jsxs("div", { className: "rounded-2xl border border-border/24 bg-card/32 px-3.5 py-3", children: [_jsxs("div", { className: "flex flex-wrap items-center gap-2", children: [_jsx(MetaPill, { compact: true, children: preference.category ?? "preference" }), preference.source ? (_jsx(MetaPill, { compact: true, children: preference.source })) : null] }), _jsx("div", { className: "mt-2 text-sm leading-6 text-txt", children: preference.text }), preference.originalRequest ? (_jsxs("div", { className: "mt-2 text-xs leading-5 text-muted", children: ["Request: ", preference.originalRequest] })) : null, _jsx("div", { className: "mt-2 text-xs text-muted", children: formatDateTime(preference.createdAt, {
86
- fallback: "No timestamp",
87
- }) })] }, preference.id))) }))] }));
119
+ const shownPreferences = visibleItems(person.userPersonalityPreferences);
120
+ const hiddenPreferences = person.userPersonalityPreferences.slice(PANEL_PREVIEW_LIMIT);
121
+ const renderPreference = (preference) => (_jsxs("div", { className: "rounded-xl border border-border/24 bg-card/32 px-3.5 py-3", children: [_jsxs("div", { className: "flex flex-wrap items-center gap-2", children: [_jsx(MetaPill, { compact: true, children: preference.category ?? "preference" }), preference.source ? (_jsx(MetaPill, { compact: true, children: preference.source })) : null] }), _jsx("div", { className: "mt-2 text-sm leading-6 text-txt", children: boundedText(preference.text) }), preference.originalRequest ? (_jsxs("details", { className: "mt-2", children: [_jsx("summary", { className: "cursor-pointer text-xs leading-5 text-muted transition hover:text-txt", children: "Original request" }), _jsx("div", { className: "mt-1 text-xs leading-5 text-muted", children: boundedText(preference.originalRequest, 260) })] })) : null, _jsx("div", { className: "mt-2 text-xs text-muted", children: formatDateTime(preference.createdAt, {
122
+ fallback: "No timestamp",
123
+ }) })] }, preference.id));
124
+ return (_jsxs(PagePanel, { variant: "surface", className: "px-4 py-4", children: [_jsxs("div", { className: "flex items-center justify-between gap-3", children: [_jsxs("div", { children: [_jsx("div", { className: "text-xs-tight font-semibold uppercase tracking-[0.16em] text-muted/70", children: "User personality preferences" }), _jsx("div", { className: "mt-2 text-lg font-semibold text-txt", children: "User-scoped guidance learned from interactions" })] }), _jsx(MetaPill, { compact: true, children: person.userPersonalityPreferences.length })] }), person.userPersonalityPreferences.length === 0 ? (_jsx("p", { className: "mt-4 text-sm leading-6 text-muted", children: "No user-scoped personality preferences have been learned for this person yet." })) : (_jsxs("div", { className: "mt-4 space-y-3", children: [shownPreferences.map(renderPreference), _jsx(MoreItems, { count: overflowCount(person.userPersonalityPreferences), children: hiddenPreferences.map(renderPreference) })] }))] }));
88
125
  }
@@ -1,15 +1,10 @@
1
1
  import type { RelationshipsGraphSnapshot } from "../../../api/client-types-relationships";
2
- export declare function RelationshipsSidebar({ search, platform, platforms, graph, graphLoading, selectedPersonId, onSearchChange, onSearchClear, onPlatformChange, onRefreshGraph, onSelectPersonId, }: {
2
+ export declare function RelationshipsSidebar({ search, graph, selectedPersonId, onSearchChange, onSearchClear, onSelectPersonId, }: {
3
3
  search: string;
4
- platform: string;
5
- platforms: string[];
6
4
  graph: RelationshipsGraphSnapshot | null;
7
- graphLoading: boolean;
8
5
  selectedPersonId: string | null;
9
6
  onSearchChange: (value: string) => void;
10
7
  onSearchClear: () => void;
11
- onPlatformChange: (platform: string) => void;
12
- onRefreshGraph: () => void;
13
8
  onSelectPersonId: (personId: string) => void;
14
9
  }): import("react/jsx-runtime").JSX.Element;
15
10
  //# sourceMappingURL=RelationshipsSidebar.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"RelationshipsSidebar.d.ts","sourceRoot":"","sources":["../../../../../../../src/components/pages/relationships/RelationshipsSidebar.tsx"],"names":[],"mappings":"AASA,OAAO,KAAK,EAAE,0BAA0B,EAAE,MAAM,yCAAyC,CAAC;AAO1F,wBAAgB,oBAAoB,CAAC,EACnC,MAAM,EACN,QAAQ,EACR,SAAS,EACT,KAAK,EACL,YAAY,EACZ,gBAAgB,EAChB,cAAc,EACd,aAAa,EACb,gBAAgB,EAChB,cAAc,EACd,gBAAgB,GACjB,EAAE;IACD,MAAM,EAAE,MAAM,CAAC;IACf,QAAQ,EAAE,MAAM,CAAC;IACjB,SAAS,EAAE,MAAM,EAAE,CAAC;IACpB,KAAK,EAAE,0BAA0B,GAAG,IAAI,CAAC;IACzC,YAAY,EAAE,OAAO,CAAC;IACtB,gBAAgB,EAAE,MAAM,GAAG,IAAI,CAAC;IAChC,cAAc,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;IACxC,aAAa,EAAE,MAAM,IAAI,CAAC;IAC1B,gBAAgB,EAAE,CAAC,QAAQ,EAAE,MAAM,KAAK,IAAI,CAAC;IAC7C,cAAc,EAAE,MAAM,IAAI,CAAC;IAC3B,gBAAgB,EAAE,CAAC,QAAQ,EAAE,MAAM,KAAK,IAAI,CAAC;CAC9C,2CA2HA"}
1
+ {"version":3,"file":"RelationshipsSidebar.d.ts","sourceRoot":"","sources":["../../../../../../../src/components/pages/relationships/RelationshipsSidebar.tsx"],"names":[],"mappings":"AAOA,OAAO,KAAK,EAAE,0BAA0B,EAAE,MAAM,yCAAyC,CAAC;AAI1F,wBAAgB,oBAAoB,CAAC,EACnC,MAAM,EACN,KAAK,EACL,gBAAgB,EAChB,cAAc,EACd,aAAa,EACb,gBAAgB,GACjB,EAAE;IACD,MAAM,EAAE,MAAM,CAAC;IACf,KAAK,EAAE,0BAA0B,GAAG,IAAI,CAAC;IACzC,gBAAgB,EAAE,MAAM,GAAG,IAAI,CAAC;IAChC,cAAc,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;IACxC,aAAa,EAAE,MAAM,IAAI,CAAC;IAC1B,gBAAgB,EAAE,CAAC,QAAQ,EAAE,MAAM,KAAK,IAAI,CAAC;CAC9C,2CAuDA"}
@@ -1,15 +1,15 @@
1
1
  import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
- import { Button, MetaPill, PagePanel, SidebarContent, SidebarHeader, SidebarPanel, SidebarScrollRegion, } from "@elizaos/ui";
2
+ import { MetaPill, SidebarContent, SidebarHeader, SidebarPanel, SidebarScrollRegion, } from "@elizaos/ui";
3
3
  import { AppPageSidebar } from "../../shared/AppPageSidebar";
4
- import { RELATIONSHIPS_TOOLBAR_BUTTON_CLASS, summarizeHandles, } from "./relationships-utils";
5
- export function RelationshipsSidebar({ search, platform, platforms, graph, graphLoading, selectedPersonId, onSearchChange, onSearchClear, onPlatformChange, onRefreshGraph, onSelectPersonId, }) {
4
+ import { summarizeHandles } from "./relationships-utils";
5
+ export function RelationshipsSidebar({ search, graph, selectedPersonId, onSearchChange, onSearchClear, onSelectPersonId, }) {
6
6
  return (_jsxs(AppPageSidebar, { testId: "relationships-sidebar", collapsible: true, contentIdentity: "relationships", children: [_jsx(SidebarHeader, { search: {
7
7
  value: search,
8
8
  onChange: (event) => onSearchChange(event.target.value),
9
9
  placeholder: "Search people, aliases, handles",
10
10
  "aria-label": "Search people, aliases, handles",
11
11
  onClear: onSearchClear,
12
- } }), _jsxs(SidebarPanel, { children: [_jsxs(PagePanel.SummaryCard, { compact: true, className: "mt-2 space-y-3", children: [_jsxs("div", { className: "grid grid-cols-3 gap-2", children: [_jsxs("div", { className: "rounded-xl border border-border/24 bg-card/35 px-2.5 py-2", children: [_jsx("div", { className: "text-2xs uppercase tracking-[0.12em] text-muted/70", children: "People" }), _jsx("div", { className: "mt-1 text-sm font-semibold text-txt", children: graph?.stats.totalPeople ?? 0 })] }), _jsxs("div", { className: "rounded-xl border border-border/24 bg-card/35 px-2.5 py-2", children: [_jsx("div", { className: "text-2xs uppercase tracking-[0.12em] text-muted/70", children: "Links" }), _jsx("div", { className: "mt-1 text-sm font-semibold text-txt", children: graph?.stats.totalRelationships ?? 0 })] }), _jsxs("div", { className: "rounded-xl border border-border/24 bg-card/35 px-2.5 py-2", children: [_jsx("div", { className: "text-2xs uppercase tracking-[0.12em] text-muted/70", children: "IDs" }), _jsx("div", { className: "mt-1 text-sm font-semibold text-txt", children: graph?.stats.totalIdentities ?? 0 })] })] }), _jsxs("div", { children: [_jsx("div", { className: "text-xs-tight font-semibold uppercase tracking-[0.14em] text-muted/70", children: "Platform filter" }), _jsxs("div", { className: "mt-2 flex flex-wrap gap-1.5", children: [_jsx(Button, { type: "button", size: "sm", variant: "outline", className: `${RELATIONSHIPS_TOOLBAR_BUTTON_CLASS} ${platform === "all" ? "border-accent/40 bg-accent/14 text-txt" : ""}`, onClick: () => onPlatformChange("all"), children: "All" }), platforms.map((entry) => (_jsx(Button, { type: "button", size: "sm", variant: "outline", className: `${RELATIONSHIPS_TOOLBAR_BUTTON_CLASS} ${platform === entry ? "border-accent/40 bg-accent/14 text-txt" : ""}`, onClick: () => onPlatformChange(entry), children: entry }, entry)))] })] }), _jsx(Button, { type: "button", size: "sm", variant: "outline", className: RELATIONSHIPS_TOOLBAR_BUTTON_CLASS, onClick: onRefreshGraph, children: graphLoading ? "Refreshing…" : "Refresh graph" })] }), _jsx(SidebarContent.SectionLabel, { className: "mt-3", children: "People" }), _jsx(SidebarScrollRegion, { className: "mt-2", children: _jsx("div", { className: "space-y-1.5", children: graph?.people.map((person) => {
12
+ } }), _jsxs(SidebarPanel, { children: [_jsxs(SidebarContent.SectionLabel, { className: "mt-2", children: ["People ", graph ? `(${graph.people.length})` : ""] }), _jsx(SidebarScrollRegion, { className: "mt-2", children: _jsx("div", { className: "space-y-1.5", children: graph?.people.map((person) => {
13
13
  const active = person.primaryEntityId === selectedPersonId;
14
14
  return (_jsxs(SidebarContent.Item, { active: active, onClick: () => onSelectPersonId(person.primaryEntityId), "aria-current": active ? "page" : undefined, children: [_jsx(SidebarContent.ItemIcon, { active: active, children: person.displayName.charAt(0).toUpperCase() }), _jsxs("span", { className: "min-w-0 flex-1 text-left", children: [_jsx(SidebarContent.ItemTitle, { children: person.displayName }), _jsx(SidebarContent.ItemDescription, { children: person.isOwner
15
15
  ? `Owner · ${summarizeHandles(person) || person.platforms.join(" • ") || "Canonical profile"}`
@@ -1,6 +1,7 @@
1
1
  import { type ReactNode } from "react";
2
- export declare function RelationshipsWorkspaceView({ contentHeader, onViewMemories, }: {
2
+ export declare function RelationshipsWorkspaceView({ contentHeader, embedded, onViewMemories, }: {
3
3
  contentHeader?: ReactNode;
4
+ embedded?: boolean;
4
5
  onViewMemories?: (entityIds: string[]) => void;
5
6
  }): import("react/jsx-runtime").JSX.Element;
6
7
  //# sourceMappingURL=RelationshipsWorkspaceView.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"RelationshipsWorkspaceView.d.ts","sourceRoot":"","sources":["../../../../../../../src/components/pages/relationships/RelationshipsWorkspaceView.tsx"],"names":[],"mappings":"AACA,OAAO,EACL,KAAK,SAAS,EAMf,MAAM,OAAO,CAAC;AAyBf,wBAAgB,0BAA0B,CAAC,EACzC,aAAa,EACb,cAAc,GACf,EAAE;IACD,aAAa,CAAC,EAAE,SAAS,CAAC;IAC1B,cAAc,CAAC,EAAE,CAAC,SAAS,EAAE,MAAM,EAAE,KAAK,IAAI,CAAC;CAChD,2CA6PA"}
1
+ {"version":3,"file":"RelationshipsWorkspaceView.d.ts","sourceRoot":"","sources":["../../../../../../../src/components/pages/relationships/RelationshipsWorkspaceView.tsx"],"names":[],"mappings":"AACA,OAAO,EACL,KAAK,SAAS,EAMf,MAAM,OAAO,CAAC;AAyBf,wBAAgB,0BAA0B,CAAC,EACzC,aAAa,EACb,QAAgB,EAChB,cAAc,GACf,EAAE;IACD,aAAa,CAAC,EAAE,SAAS,CAAC;IAC1B,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,cAAc,CAAC,EAAE,CAAC,SAAS,EAAE,MAAM,EAAE,KAAK,IAAI,CAAC;CAChD,2CA+VA"}
@@ -1,5 +1,5 @@
1
- import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
2
- import { PageLayout, PagePanel } from "@elizaos/ui";
1
+ import { jsxs as _jsxs, jsx as _jsx, Fragment as _Fragment } from "react/jsx-runtime";
2
+ import { Button, MetaPill, PageLayout, PagePanel } from "@elizaos/ui";
3
3
  import { useCallback, useDeferredValue, useEffect, useRef, useState, } from "react";
4
4
  import { client } from "../../../api/client";
5
5
  import { useApp } from "../../../state";
@@ -9,7 +9,7 @@ import { RelationshipsCandidateMergesPanel } from "./RelationshipsCandidateMerge
9
9
  import { RelationshipsConnectionsPanel, RelationshipsConversationsPanel, RelationshipsFactsPanel, RelationshipsPersonSummaryPanel, RelationshipsRelevantMemoriesPanel, RelationshipsUserPreferencesPanel, } from "./RelationshipsPersonPanels";
10
10
  import { RelationshipsSidebar } from "./RelationshipsSidebar";
11
11
  import { buildRelationshipsGraphQuery, platformOptions, sortPeople, } from "./relationships-utils";
12
- export function RelationshipsWorkspaceView({ contentHeader, onViewMemories, }) {
12
+ export function RelationshipsWorkspaceView({ contentHeader, embedded = false, onViewMemories, }) {
13
13
  const { t, setTab } = useApp();
14
14
  const [search, setSearch] = useState("");
15
15
  const [platform, setPlatform] = useState("all");
@@ -105,16 +105,26 @@ export function RelationshipsWorkspaceView({ contentHeader, onViewMemories, }) {
105
105
  (() => {
106
106
  setTab("memories");
107
107
  });
108
- return (_jsx(PageLayout, { sidebar: _jsx(RelationshipsSidebar, { search: search, platform: platform, platforms: platforms, graph: graph, graphLoading: graphLoading, selectedPersonId: selectedPersonId, onSearchChange: setSearch, onSearchClear: () => setSearch(""), onPlatformChange: setPlatform, onRefreshGraph: () => {
109
- void loadGraph(buildRelationshipsGraphQuery(deferredSearch, platform));
110
- }, onSelectPersonId: setSelectedPersonId }), contentHeader: contentHeader, "data-testid": "relationships-view", children: _jsxs("div", { className: "flex min-h-0 flex-1 flex-col gap-4", children: [graphError ? (_jsx("div", { className: "rounded-2xl border border-danger/30 bg-danger/10 px-4 py-3 text-sm text-danger", children: graphError })) : null, detailError ? (_jsx("div", { className: "rounded-2xl border border-warning/30 bg-warning/10 px-4 py-3 text-sm text-warning", children: detailError })) : null, !graph && graphLoading ? (_jsx(PagePanel.Loading, { heading: t("common.loading", { defaultValue: "Loading…" }) })) : !graph || graph.people.length === 0 ? (_jsx(PagePanel.Empty, { variant: "panel", className: "min-h-[24rem]", description: "Connectors, relationships extraction, and confirmed identity links will populate this workspace.", title: "No relationships data available" })) : (_jsxs(_Fragment, { children: [_jsxs("div", { className: "grid gap-4 xl:grid-cols-[minmax(0,1.2fr)_minmax(0,0.8fr)]", children: [_jsx(PagePanel, { variant: "surface", className: "px-4 py-4", children: _jsx(RelationshipsGraphPanel, { snapshot: graph, selectedGroupId: selectedGroupId, onSelectGroupId: (groupId) => {
111
- const person = graph.people.find((entry) => entry.groupId === groupId);
112
- if (person) {
113
- setSelectedPersonId(person.primaryEntityId);
114
- }
115
- } }) }), displayDetail ? (_jsx("div", { className: isStaleDetail
116
- ? "pointer-events-none opacity-50 transition-opacity duration-200"
117
- : "transition-opacity duration-200", children: _jsx(RelationshipsPersonSummaryPanel, { person: displayDetail, onViewMemories: handleViewMemories }) })) : detailLoading ? (_jsx(PagePanel.Loading, { heading: "Loading person detail\u2026" })) : (_jsx(PagePanel.Empty, { variant: "panel", title: "Select a person", description: "Choose a person in the left rail or graph to inspect linked identities, facts, and conversation snippets." }))] }), displayDetail ? (_jsxs("div", { className: `grid gap-4 xl:grid-cols-2 ${isStaleDetail ? "pointer-events-none opacity-50 transition-opacity duration-200" : "transition-opacity duration-200"}`, children: [_jsx(RelationshipsFactsPanel, { person: displayDetail }), _jsx(RelationshipsConnectionsPanel, { person: displayDetail }), _jsx("div", { className: "xl:col-span-2", children: _jsx(RelationshipsConversationsPanel, { person: displayDetail }) }), _jsx(RelationshipsRelevantMemoriesPanel, { person: displayDetail }), _jsx(RelationshipsUserPreferencesPanel, { person: displayDetail })] })) : null, _jsx(RelationshipsCandidateMergesPanel, { graph: graph, onResolved: () => {
118
- void loadGraph(buildRelationshipsGraphQuery(deferredSearch, platform));
119
- } }), _jsxs(PagePanel, { variant: "surface", className: "px-4 py-4", children: [_jsx("div", { className: "flex items-center justify-between gap-3", children: _jsxs("div", { children: [_jsx("div", { className: "text-xs-tight font-semibold uppercase tracking-[0.16em] text-muted/70", children: "Activity feed" }), _jsx("div", { className: "mt-2 text-lg font-semibold text-txt", children: "Recent relationship, identity, and fact events" })] }) }), _jsx("div", { className: "mt-4", children: _jsx(RelationshipsActivityFeed, {}) })] })] }))] }) }));
108
+ const refreshGraph = () => {
109
+ void loadGraph(buildRelationshipsGraphQuery(deferredSearch, platform));
110
+ };
111
+ const toolbar = (_jsx(PagePanel, { variant: "surface", className: "px-3 py-3", children: _jsxs("div", { className: "flex flex-col gap-3 lg:flex-row lg:items-center lg:justify-between", children: [_jsxs("div", { className: "grid grid-cols-3 gap-2 sm:flex sm:flex-wrap", children: [_jsxs(MetaPill, { compact: true, children: [graph?.stats.totalPeople ?? 0, " people"] }), _jsxs(MetaPill, { compact: true, children: [graph?.stats.totalRelationships ?? 0, " links"] }), _jsxs(MetaPill, { compact: true, children: [graph?.stats.totalIdentities ?? 0, " identities"] })] }), _jsxs("div", { className: "flex min-w-0 flex-1 flex-col gap-2 sm:flex-row lg:max-w-3xl", children: [embedded ? (_jsxs(_Fragment, { children: [_jsx("label", { className: "sr-only", htmlFor: "relationships-search", children: "Search people, aliases, handles" }), _jsxs("div", { className: "relative min-w-0 flex-1", children: [_jsx("input", { id: "relationships-search", value: search, onChange: (event) => setSearch(event.target.value), placeholder: "Search people, aliases, handles", "aria-label": "Search people, aliases, handles", className: "h-9 w-full rounded-lg border border-border/35 bg-card/45 px-3 pr-16 text-sm text-txt outline-none transition focus:border-accent/55" }), search ? (_jsx(Button, { type: "button", size: "sm", variant: "ghost", className: "absolute right-1 top-1 h-7 rounded-md px-2 text-2xs", onClick: () => setSearch(""), children: "Clear" })) : null] })] })) : null, _jsx("label", { className: "sr-only", htmlFor: "relationships-platform", children: "Platform filter" }), _jsxs("select", { id: "relationships-platform", value: platform, onChange: (event) => setPlatform(event.target.value), "aria-label": "Platform filter", className: "h-9 rounded-lg border border-border/35 bg-card/45 px-3 text-sm text-txt outline-none transition focus:border-accent/55", children: [_jsx("option", { value: "all", children: "All platforms" }), platforms.map((entry) => (_jsx("option", { value: entry, children: entry }, entry)))] }), _jsx(Button, { type: "button", size: "sm", variant: "outline", className: "h-9 shrink-0 rounded-lg px-3", onClick: refreshGraph, children: graphLoading ? "Refreshing..." : "Refresh" })] })] }) }));
112
+ const content = (_jsxs("div", { className: `flex min-h-0 flex-1 flex-col ${embedded ? "gap-3" : "gap-4"}`, "data-testid": embedded ? "relationships-embedded-view" : undefined, children: [toolbar, graphError ? (_jsx("div", { className: "rounded-xl border border-danger/30 bg-danger/10 px-4 py-3 text-sm text-danger", children: graphError })) : null, detailError ? (_jsx("div", { className: "rounded-xl border border-warning/30 bg-warning/10 px-4 py-3 text-sm text-warning", children: detailError })) : null, !graph && graphLoading ? (_jsx(PagePanel.Loading, { heading: t("common.loading", { defaultValue: "Loading..." }) })) : !graph || graph.people.length === 0 ? (_jsx(PagePanel.Empty, { variant: "panel", className: embedded ? "min-h-[18rem]" : "min-h-[24rem]", description: search || platform !== "all"
113
+ ? "No people match the current relationship filters."
114
+ : "Connectors, relationships extraction, and confirmed identity links will populate this workspace.", title: search || platform !== "all"
115
+ ? "No matching relationships"
116
+ : "No relationships data available" })) : (_jsxs(_Fragment, { children: [_jsxs("div", { className: embedded
117
+ ? "grid min-h-0 gap-3 xl:grid-cols-[minmax(0,1.25fr)_minmax(20rem,0.75fr)]"
118
+ : "grid min-h-0 gap-4 xl:grid-cols-[minmax(0,1.35fr)_minmax(22rem,0.65fr)]", children: [_jsx(PagePanel, { variant: "surface", className: "px-3 py-3 sm:px-4 sm:py-4", children: _jsx(RelationshipsGraphPanel, { snapshot: graph, selectedGroupId: selectedGroupId, compact: embedded, onSelectGroupId: (groupId) => {
119
+ const person = graph.people.find((entry) => entry.groupId === groupId);
120
+ if (person) {
121
+ setSelectedPersonId(person.primaryEntityId);
122
+ }
123
+ } }) }), displayDetail ? (_jsx("div", { className: isStaleDetail
124
+ ? "pointer-events-none opacity-50 transition-opacity duration-200"
125
+ : "transition-opacity duration-200", children: _jsx(RelationshipsPersonSummaryPanel, { person: displayDetail, compact: embedded, onViewMemories: handleViewMemories }) })) : detailLoading ? (_jsx(PagePanel.Loading, { heading: "Loading person detail..." })) : (_jsx(PagePanel.Empty, { variant: "panel", title: "Select a person", description: "Choose a person from the list or graph to inspect linked identities, facts, and conversation snippets." }))] }), displayDetail ? (_jsxs("div", { className: `grid gap-3 xl:grid-cols-2 ${isStaleDetail ? "pointer-events-none opacity-50 transition-opacity duration-200" : "transition-opacity duration-200"}`, children: [_jsx(RelationshipsFactsPanel, { person: displayDetail }), _jsx(RelationshipsConnectionsPanel, { person: displayDetail }), _jsx("div", { className: "xl:col-span-2", children: _jsx(RelationshipsConversationsPanel, { person: displayDetail }) }), _jsx(RelationshipsRelevantMemoriesPanel, { person: displayDetail }), _jsx(RelationshipsUserPreferencesPanel, { person: displayDetail })] })) : null, !embedded ? (_jsxs(_Fragment, { children: [_jsx(RelationshipsCandidateMergesPanel, { graph: graph, onResolved: refreshGraph }), _jsxs(PagePanel, { variant: "surface", className: "px-4 py-4", children: [_jsx("div", { className: "flex items-center justify-between gap-3", children: _jsxs("div", { children: [_jsx("div", { className: "text-xs-tight font-semibold uppercase tracking-[0.16em] text-muted/70", children: "Activity feed" }), _jsx("div", { className: "mt-2 text-lg font-semibold text-txt", children: "Recent relationship, identity, and fact events" })] }) }), _jsx("div", { className: "mt-4 max-h-[24rem] overflow-auto pr-1", children: _jsx(RelationshipsActivityFeed, {}) })] })] })) : null] }))] }));
126
+ if (embedded) {
127
+ return content;
128
+ }
129
+ return (_jsx(PageLayout, { sidebar: _jsx(RelationshipsSidebar, { search: search, graph: graph, selectedPersonId: selectedPersonId, onSearchChange: setSearch, onSearchClear: () => setSearch(""), onSelectPersonId: setSelectedPersonId }), contentHeader: contentHeader, "data-testid": "relationships-view", children: content }));
120
130
  }
@@ -3024,7 +3024,7 @@
3024
3024
  "lifeopspage.agentGithubConnectedRestarting": "Agent GitHub{{githubHandle}} connected and the cloud runtime is restarting.",
3025
3025
  "lifeopspage.agentGithubConnected": "Agent GitHub{{githubHandle}} connected.",
3026
3026
  "lifeopspage.notLinked": "Not linked",
3027
- "lifeopspage.githubDetailsPartial": "Some GitHub cloud details are still unavailable. You can still connect accounts.",
3027
+ "lifeopspage.githubDetailsPartial": "GitHub details unavailable.",
3028
3028
  "lifeopspage.githubDetailsLoadFailed": "GitHub connection details failed to load.",
3029
3029
  "lifeopspage.githubLinkFailed": "Failed to link GitHub to this agent.",
3030
3030
  "lifeopspage.enabled": "LifeOps enabled.",
@@ -3039,7 +3039,7 @@
3039
3039
  "lifeopspage.agentGithubDisconnected": "Agent GitHub disconnected.",
3040
3040
  "lifeopspage.disconnectAgentGithubFailed": "Failed to disconnect agent GitHub.",
3041
3041
  "lifeopspage.cloudRequired": "Cloud required",
3042
- "lifeopspage.noCloudAgent": "No cloud agent",
3042
+ "lifeopspage.noCloudAgent": "No agent",
3043
3043
  "lifeopspage.loadingState": "Loading LifeOps app state",
3044
3044
  "lifeopspage.waitingRuntime": "Waiting for LifeOps runtime",
3045
3045
  "lifeopspage.enableTitle": "Your personal assistant for calendar, email, and routines",
@@ -3055,7 +3055,7 @@
3055
3055
  "lifeopspage.enabling": "Enabling…",
3056
3056
  "lifeopspage.enable": "Enable LifeOps",
3057
3057
  "lifeopspage.disableHint": "You can disable LifeOps at any time.",
3058
- "lifeopspage.setupTitle": "Setup",
3058
+ "lifeopspage.setupTitle": "Access",
3059
3059
  "lifeopspage.setupDescription": "Connect Google, GitHub, and messaging accounts.",
3060
3060
  "lifeopspage.disable": "Disable LifeOps",
3061
3061
  "lifeopsworkspace.user": "User",
@@ -3114,8 +3114,8 @@
3114
3114
  "lifeopssettings.googleConnected": "Google connected",
3115
3115
  "lifeopssettings.local": "Local",
3116
3116
  "lifeopssettings.cloud": "Cloud",
3117
- "lifeopssettings.localModeDescription": "Tokens stay on this device. LifeOps can only access Google while the app is running.",
3118
- "lifeopssettings.cloudModeDescription": "Tokens live in Eliza Cloud. The agent can check Google on your behalf even when the app is closed.",
3117
+ "lifeopssettings.localModeDescription": "This device only.",
3118
+ "lifeopssettings.cloudModeDescription": "Background access.",
3119
3119
  "lifeopssettings.user": "User",
3120
3120
  "lifeopssettings.capabilityCalendar": "Cal",
3121
3121
  "lifeopssettings.capabilityMail": "Mail",
@@ -174,8 +174,8 @@ const CURATED_APPS = [
174
174
  {
175
175
  id: "clawville",
176
176
  npmName: "@clawville/app-clawville",
177
- displayName: "Clawville",
178
- description: "Claw-machine-themed multiplayer arcade.",
177
+ displayName: "ClawVille",
178
+ description: "Sea-themed agent world with skill-learning buildings, NPC chat, and Solana wallet identity.",
179
179
  subtype: "game",
180
180
  launchType: "server-launch",
181
181
  icon: "Gamepad2",
@@ -1 +1 @@
1
- {"version":3,"file":"eliza.d.ts","sourceRoot":"","sources":["../../../../../src/runtime/eliza.ts"],"names":[],"mappings":"A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hD;AAyoBD,MAAM,WAAW,0BAA2B,SAAQ,uBAAuB;IACzE,oEAAoE;IACpE,mBAAmB,CAAC,EAAE,yBAAyB,CAAC;CACjD;AAED,wBAAsB,gBAAgB,CACpC,IAAI,GAAE,0BAA+B,GACpC,OAAO,CAAC,OAAO,CAAC,UAAU,CAAC,OAAO,wBAAwB,CAAC,CAAC,CAAC,CAqB/D;AAED,MAAM,WAAW,oBAAqB,SAAQ,iBAAiB;IAC7D,oEAAoE;IACpE,mBAAmB,CAAC,EAAE,yBAAyB,CAAC;CACjD;AAuOD,wBAAsB,sBAAsB,CAC1C,GAAG,EAAE,OAAO,GACX,OAAO,CAAC,MAAM,GAAG,IAAI,CAAC,CAwBxB;AAED,wBAAgB,iCAAiC,IAAI,MAAM,EAAE,CAE5D;AAED,wBAAsB,UAAU,CAC9B,OAAO,CAAC,EAAE,oBAAoB,GAC7B,OAAO,CAAC,OAAO,CAAC,UAAU,CAAC,OAAO,kBAAkB,CAAC,CAAC,CAAC,CA+JzD"}
@@ -58,6 +58,11 @@ function getAutonomyService(runtime) {
58
58
  }
59
59
  return null;
60
60
  }
61
+ async function startAndRegisterAutonomyService(runtime) {
62
+ const service = await AutonomyService.start(runtime);
63
+ runtime.services.set("AUTONOMY", [service]);
64
+ return service;
65
+ }
61
66
  function syncBrandEnvAliases() {
62
67
  syncElizaEnvAliases();
63
68
  syncAppEnvToEliza();
@@ -270,7 +275,7 @@ async function repairRuntimeAfterBoot(runtime) {
270
275
  await registerTrackCTrainingCrons(runtime);
271
276
  if (!runtime.getService("AUTONOMY")) {
272
277
  try {
273
- await AutonomyService.start(runtime);
278
+ await startAndRegisterAutonomyService(runtime);
274
279
  logger.info("[eliza] AutonomyService started after SQL compatibility repair");
275
280
  }
276
281
  catch (error) {
@@ -8,8 +8,10 @@
8
8
  * Mode selection mirrors n8n-routes proxy:
9
9
  * - Cloud mode → POST ${cloudBaseUrl}/api/v1/agents/${agentId}/n8n/workflows/{id}/execute
10
10
  * Authorization: Bearer ${cloud.apiKey}
11
- * - Local mode → POST ${sidecar.host}/rest/workflows/{id}/run
12
- * X-N8N-API-KEY: ${sidecar.getApiKey()}
11
+ * - Local mode → GET workflow via /api/v1 with X-N8N-API-KEY, then
12
+ * POST ${sidecar.host}/rest/workflows/{id}/run with the
13
+ * local owner n8n-auth cookie. n8n's manual run endpoint is
14
+ * an internal UI route and does not accept API-key auth.
13
15
  * - Disabled → immediate `{ ok: false, error: "n8n disabled" }` (no fetch)
14
16
  *
15
17
  * This module is I/O only — it does not own the sidecar lifecycle, and
@@ -34,6 +36,7 @@ export interface N8nDispatchConfigLike extends N8nModeConfigLike {
34
36
  localEnabled?: boolean;
35
37
  host?: string | null;
36
38
  apiKey?: string;
39
+ stateDir?: string;
37
40
  };
38
41
  }
39
42
  export interface N8nDispatchResult {
@@ -75,6 +78,11 @@ export interface CreateN8nDispatchServiceOptions {
75
78
  * a deterministic value.
76
79
  */
77
80
  resolveAgentId?: (runtime: AgentRuntime) => string;
81
+ /**
82
+ * Local-only auth hook. Tests inject a deterministic cookie; production
83
+ * reads the sidecar owner credentials and logs in to n8n.
84
+ */
85
+ getLocalOwnerCookie?: (host: string, config: N8nDispatchConfigLike) => Promise<string | null>;
78
86
  }
79
87
  /**
80
88
  * Construct the dispatch service. The returned value is registered under
@@ -1 +1 @@
1
- {"version":3,"file":"n8n-dispatch.d.ts","sourceRoot":"","sources":["../../../../../src/services/n8n-dispatch.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAEH,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,eAAe,CAAC;AAGlD,OAAO,EAAE,KAAK,iBAAiB,EAAkB,MAAM,eAAe,CAAC;AAGvE;;;;GAIG;AACH,MAAM,WAAW,qBAAsB,SAAQ,iBAAiB;IAC9D,KAAK,CAAC,EAAE;QACN,OAAO,CAAC,EAAE,OAAO,CAAC;QAClB,MAAM,CAAC,EAAE,MAAM,CAAC;QAChB,OAAO,CAAC,EAAE,MA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