@agenticprimitives/home 0.0.0-alpha.1 → 0.0.0-alpha.4

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.
@@ -0,0 +1,137 @@
1
+ import type { CanonicalAgentId } from '@agenticprimitives/types';
2
+ import type { VaultRef } from '@agenticprimitives/vault';
3
+ import type { AuditRefV1 } from './types.js';
4
+ import type { HomeActionDescriptorV1 } from './types.js';
5
+ /** Endeavor lifecycle (spec 332 §5 `EndeavorV1.lifecycle`), projected as-is. */
6
+ export type EndeavorLifecycle = 'proposed' | 'adopted' | 'active' | 'suspended' | 'satisfied' | 'abandoned';
7
+ export declare const ENDEAVOR_LIFECYCLES: readonly EndeavorLifecycle[];
8
+ /** Participation roles (spec 332 §3 `apcoord:role/*`) — ontology structure, never authority. */
9
+ export type EndeavorParticipationRole = 'sponsor' | 'coordinator' | 'contributor' | 'validator' | 'beneficiary' | 'observer';
10
+ /** The seven separate facts (ADR-0054 §4) a contribution entry may honestly
11
+ * report. Projected, never collapsed: allocated ≠ committed ≠ performing. */
12
+ export type ContributionStateFact = 'capable' | 'available' | 'allocated' | 'committed' | 'authorized' | 'performing' | 'satisfied';
13
+ export declare const CONTRIBUTION_STATE_FACTS: readonly ContributionStateFact[];
14
+ /** The exact plan revision a contribution binds to (spec 332 §5 `PlanRevisionRef`). */
15
+ export interface HomePlanRevisionRefV1 {
16
+ planId: string;
17
+ revision: number;
18
+ /** Content hash of steps+edges+milestones — commitments bind to THIS, exactly. */
19
+ hash: string;
20
+ }
21
+ /** One Endeavor row for list/board/overview surfaces (spec 334 §8). */
22
+ export interface HomeEndeavorSummaryV1 {
23
+ type: 'ap.home.endeavor-summary.v1';
24
+ endeavorId: string;
25
+ managingPrincipal: CanonicalAgentId;
26
+ title: string;
27
+ lifecycle: EndeavorLifecycle;
28
+ /** Outcome progress facts, projected honestly from `PlanStepSatisfied` events. */
29
+ stepsTotal: number;
30
+ stepsSatisfied: number;
31
+ /** The viewing principal's role, when they participate. */
32
+ viewerRole?: EndeavorParticipationRole;
33
+ deadline?: string;
34
+ updatedAt: string;
35
+ }
36
+ /** One allocation/commitment for THIS principal — the My Work row (spec 334 §7). */
37
+ export interface HomeContributionEntryV1 {
38
+ type: 'ap.home.contribution-entry.v1';
39
+ endeavorId: string;
40
+ endeavorTitle: string;
41
+ managingPrincipal: CanonicalAgentId;
42
+ participant: CanonicalAgentId;
43
+ /** PlanSteps this entry covers. */
44
+ stepIds: string[];
45
+ /** The exact adopted plan revision the entry is scoped to. */
46
+ planRef: HomePlanRevisionRefV1;
47
+ status: ContributionStateFact;
48
+ allocationId?: string;
49
+ commitmentId?: string;
50
+ deadline?: string;
51
+ updatedAt: string;
52
+ }
53
+ /** A pending DecisionRequest for THIS approver — the render half; the
54
+ * transport half is the interactions card (spec 334 §8, spec 333). Pressing
55
+ * an action only PROPOSES a signed command — it grants nothing (spec 310 §6.3). */
56
+ export interface HomeDecisionCardV1 {
57
+ type: 'ap.home.decision-card.v1';
58
+ decisionId: string;
59
+ endeavorId: string;
60
+ managingPrincipal: CanonicalAgentId;
61
+ /** The declared approver (spec 333 ApprovalRequirement) — steward status never substitutes. */
62
+ approver: CanonicalAgentId;
63
+ /** spec 333 decision kind (open vocabulary; app renders the label). */
64
+ decisionKind: string;
65
+ title: string;
66
+ summary?: string;
67
+ requestedAt: string;
68
+ dueAt?: string;
69
+ allowedActions: HomeActionDescriptorV1[];
70
+ }
71
+ /** Executing-run states, as A2A/fulfillment task states — projected, not owned. */
72
+ export type AgentRunState = 'submitted' | 'working' | 'input-required' | 'completed' | 'failed' | 'canceled' | 'rejected';
73
+ /** A Task/ServiceExecution bound to a commitment (spec 334 §8) — Agent Runs +
74
+ * Endeavor detail rows. Bound by refs per the adapter provenance contract
75
+ * (spec 332 §10), so the run trace joins the durable plan. */
76
+ export interface HomeAgentRunEntryV1 {
77
+ type: 'ap.home.agent-run-entry.v1';
78
+ taskId: string;
79
+ endeavorId: string;
80
+ commitmentId: string;
81
+ stepId?: string;
82
+ state: AgentRunState;
83
+ /** Count of recorded checkpoints on the run. */
84
+ checkpoints: number;
85
+ artifactRefs: VaultRef[];
86
+ receiptRef?: string;
87
+ startedAt: string;
88
+ updatedAt: string;
89
+ }
90
+ /** An EndeavorCollection roll-up (spec 333) — Portfolio surface (later wave). */
91
+ export interface HomePortfolioSummaryV1 {
92
+ type: 'ap.home.portfolio-summary.v1';
93
+ collectionId: string;
94
+ managingPrincipal: CanonicalAgentId;
95
+ title: string;
96
+ endeavorCount: number;
97
+ byLifecycle: Partial<Record<EndeavorLifecycle, number>>;
98
+ updatedAt: string;
99
+ }
100
+ /** The principal's offers/reservations vs active commitments (spec 333
101
+ * resources) — Workload surface (later wave). Counts only; never authority. */
102
+ export interface HomeCapacitySummaryV1 {
103
+ type: 'ap.home.capacity-summary.v1';
104
+ principal: CanonicalAgentId;
105
+ offersOpen: number;
106
+ reservations: number;
107
+ activeCommitments: number;
108
+ nextDeadline?: string;
109
+ updatedAt: string;
110
+ }
111
+ export type HomeCoordinationAlertKind = 'request-accepted' | 'request-declined' | 'request-answered' | 'step-blocked' | 'deadline-near' | 'decision-overdue';
112
+ export declare const COORDINATION_ALERT_KINDS: readonly HomeCoordinationAlertKind[];
113
+ /** A coordination notification for Messages + Activity (spec 334 §5/§8) —
114
+ * backed by serving-plane audit rows; a display row, never a command. */
115
+ export interface HomeCoordinationAlertV1 {
116
+ type: 'ap.home.coordination-alert.v1';
117
+ alertId: string;
118
+ alertKind: HomeCoordinationAlertKind;
119
+ /** The principal this alert is FOR. */
120
+ subject: CanonicalAgentId;
121
+ managingPrincipal: CanonicalAgentId;
122
+ endeavorId?: string;
123
+ requestId?: string;
124
+ title: string;
125
+ summary?: string;
126
+ at: string;
127
+ auditRef?: AuditRefV1;
128
+ }
129
+ export type EndeavorSummaryValidationError = 'bad_type' | 'missing_endeavor_id' | 'missing_managing_principal' | 'empty_title' | 'bad_lifecycle' | 'bad_step_counts' | 'bad_updated_at';
130
+ export declare function validateHomeEndeavorSummary(s: HomeEndeavorSummaryV1): EndeavorSummaryValidationError[];
131
+ export type ContributionEntryValidationError = 'bad_type' | 'missing_endeavor_id' | 'missing_participant' | 'no_steps' | 'bad_plan_ref' | 'bad_status' | 'committed_without_commitment_id';
132
+ export declare function validateHomeContributionEntry(e: HomeContributionEntryV1): ContributionEntryValidationError[];
133
+ export type DecisionCardValidationError = 'bad_type' | 'missing_decision_id' | 'missing_endeavor_id' | 'missing_approver' | 'empty_title' | 'no_actions' | 'duplicate_action_id';
134
+ export declare function validateHomeDecisionCard(card: HomeDecisionCardV1): DecisionCardValidationError[];
135
+ export type CoordinationAlertValidationError = 'bad_type' | 'missing_alert_id' | 'bad_alert_kind' | 'missing_subject' | 'empty_title' | 'bad_at';
136
+ export declare function validateHomeCoordinationAlert(a: HomeCoordinationAlertV1): CoordinationAlertValidationError[];
137
+ //# sourceMappingURL=coordination.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"coordination.d.ts","sourceRoot":"","sources":["../src/coordination.ts"],"names":[],"mappings":"AAOA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,0BAA0B,CAAC;AACjE,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,0BAA0B,CAAC;AACzD,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,YAAY,CAAC;AAC7C,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,YAAY,CAAC;AAEzD,gFAAgF;AAChF,MAAM,MAAM,iBAAiB,GACzB,UAAU,GACV,SAAS,GACT,QAAQ,GACR,WAAW,GACX,WAAW,GACX,WAAW,CAAC;AAEhB,eAAO,MAAM,mBAAmB,EAAE,SAAS,iBAAiB,EAOlD,CAAC;AAEX,gGAAgG;AAChG,MAAM,MAAM,yBAAyB,GACjC,SAAS,GACT,aAAa,GACb,aAAa,GACb,WAAW,GACX,aAAa,GACb,UAAU,CAAC;AAEf;8EAC8E;AAC9E,MAAM,MAAM,qBAAqB,GAC7B,SAAS,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BAAuB,GACzB,gCAAgC,EAAE,CAmBpC;AAED,MAAM,MAAM,2BAA2B,GACnC,UAAU,GACV,qBAAqB,GACrB,qBAAqB,GACrB,kBAAkB,GAClB,aAAa,GACb,YAAY,GACZ,qBAAqB,CAAC;AAE1B,wBAAgB,wBAAwB,CAAC,IAAI,EAAE,kBAAkB,GAAG,2BAA2B,EAAE,CAehG;AAED,MAAM,MAAM,gCAAgC,GACxC,UAAU,GACV,kBAAkB,GAClB,gBAAgB,GAChB,iBAAiB,GACjB,aAAa,GACb,QAAQ,CAAC;AAEb,wBAAgB,6BAA6B,CAC3C,CAAC,EAAE,uBAAuB,GACzB,gCAAgC,EAAE,CASpC"}
@@ -0,0 +1,113 @@
1
+ // Portable Home coordination projections (spec 334 §8) — the render-half
2
+ // contracts a Home app projects over spec-332/333 coordination records and
3
+ // audit rows. All seven are PROJECTIONS: none is a source of truth and none
4
+ // carries authority (allocation ≠ commitment ≠ authorization — ADR-0054 §4;
5
+ // the authority packages stay the only grant surface). No routes, UI,
6
+ // storage, or branding here (ADR-0021).
7
+ export const ENDEAVOR_LIFECYCLES = [
8
+ 'proposed',
9
+ 'adopted',
10
+ 'active',
11
+ 'suspended',
12
+ 'satisfied',
13
+ 'abandoned',
14
+ ];
15
+ export const CONTRIBUTION_STATE_FACTS = [
16
+ 'capable',
17
+ 'available',
18
+ 'allocated',
19
+ 'committed',
20
+ 'authorized',
21
+ 'performing',
22
+ 'satisfied',
23
+ ];
24
+ export const COORDINATION_ALERT_KINDS = [
25
+ 'request-accepted',
26
+ 'request-declined',
27
+ 'request-answered',
28
+ 'step-blocked',
29
+ 'deadline-near',
30
+ 'decision-overdue',
31
+ ];
32
+ // ─── Fail-closed structural validation (same discipline as validate.ts) ───
33
+ const isIsoDate = (s) => typeof s === 'string' && !Number.isNaN(Date.parse(s));
34
+ export function validateHomeEndeavorSummary(s) {
35
+ const errors = [];
36
+ if (s.type !== 'ap.home.endeavor-summary.v1')
37
+ errors.push('bad_type');
38
+ if (!s.endeavorId?.trim())
39
+ errors.push('missing_endeavor_id');
40
+ if (!s.managingPrincipal)
41
+ errors.push('missing_managing_principal');
42
+ if (!s.title?.trim())
43
+ errors.push('empty_title');
44
+ if (!ENDEAVOR_LIFECYCLES.includes(s.lifecycle))
45
+ errors.push('bad_lifecycle');
46
+ if (!Number.isInteger(s.stepsTotal) || !Number.isInteger(s.stepsSatisfied) ||
47
+ s.stepsTotal < 0 || s.stepsSatisfied < 0 || s.stepsSatisfied > s.stepsTotal) {
48
+ errors.push('bad_step_counts');
49
+ }
50
+ if (!isIsoDate(s.updatedAt))
51
+ errors.push('bad_updated_at');
52
+ return errors;
53
+ }
54
+ export function validateHomeContributionEntry(e) {
55
+ const errors = [];
56
+ if (e.type !== 'ap.home.contribution-entry.v1')
57
+ errors.push('bad_type');
58
+ if (!e.endeavorId?.trim())
59
+ errors.push('missing_endeavor_id');
60
+ if (!e.participant)
61
+ errors.push('missing_participant');
62
+ if (!Array.isArray(e.stepIds) || e.stepIds.length === 0)
63
+ errors.push('no_steps');
64
+ if (!e.planRef?.planId?.trim() || !e.planRef?.hash?.trim() || !Number.isInteger(e.planRef?.revision)) {
65
+ errors.push('bad_plan_ref');
66
+ }
67
+ if (!CONTRIBUTION_STATE_FACTS.includes(e.status))
68
+ errors.push('bad_status');
69
+ // A committed (or later) fact must carry the commitment it rests on — the
70
+ // seven facts stay separate; "committed" is never asserted without its record.
71
+ if ((e.status === 'committed' || e.status === 'performing' || e.status === 'satisfied') &&
72
+ !e.commitmentId?.trim()) {
73
+ errors.push('committed_without_commitment_id');
74
+ }
75
+ return errors;
76
+ }
77
+ export function validateHomeDecisionCard(card) {
78
+ const errors = [];
79
+ if (card.type !== 'ap.home.decision-card.v1')
80
+ errors.push('bad_type');
81
+ if (!card.decisionId?.trim())
82
+ errors.push('missing_decision_id');
83
+ if (!card.endeavorId?.trim())
84
+ errors.push('missing_endeavor_id');
85
+ if (!card.approver)
86
+ errors.push('missing_approver');
87
+ if (!card.title?.trim())
88
+ errors.push('empty_title');
89
+ if (!Array.isArray(card.allowedActions) || card.allowedActions.length === 0) {
90
+ errors.push('no_actions');
91
+ }
92
+ else if (new Set(card.allowedActions.map((a) => a.actionId)).size !== card.allowedActions.length) {
93
+ errors.push('duplicate_action_id');
94
+ }
95
+ return errors;
96
+ }
97
+ export function validateHomeCoordinationAlert(a) {
98
+ const errors = [];
99
+ if (a.type !== 'ap.home.coordination-alert.v1')
100
+ errors.push('bad_type');
101
+ if (!a.alertId?.trim())
102
+ errors.push('missing_alert_id');
103
+ if (!COORDINATION_ALERT_KINDS.includes(a.alertKind))
104
+ errors.push('bad_alert_kind');
105
+ if (!a.subject)
106
+ errors.push('missing_subject');
107
+ if (!a.title?.trim())
108
+ errors.push('empty_title');
109
+ if (!isIsoDate(a.at))
110
+ errors.push('bad_at');
111
+ return errors;
112
+ }
113
+ //# sourceMappingURL=coordination.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"coordination.js","sourceRoot":"","sources":["../src/coordination.ts"],"names":[],"mappings":"AAAA,yEAAyE;AACzE,2EAA2E;AAC3E,4EAA4E;AAC5E,4EAA4E;AAC5E,sEAAsE;AACtE,wCAAwC;AAgBxC,MAAM,CAAC,MAAM,mBAAmB,GAAiC;IAC/D,UAAU;IACV,SAAS;IACT,QAAQ;IACR,WAAW;IACX,WAAW;IACX,WAAW;CACH,CAAC;AAsBX,MAAM,CAAC,MAAM,wBAAwB,GAAqC;IACxE,SAAS;IACT,WAAW;IACX,WAAW;IACX,WAAW;IACX,YAAY;IACZ,YAAY;IACZ,WAAW;CACH,CAAC;AA0HX,MAAM,CAAC,MAAM,wBAAwB,GAAyC;IAC5E,kBAAkB;IAClB,kBAAkB;IAClB,kBAAkB;IAClB,cAAc;IACd,eAAe;IACf,kBAAkB;CACV,CAAC;AAmBX,6EAA6E;AAE7E,MAAM,SAAS,GAAG,CAAC,CAAS,EAAW,EAAE,CAAC,OAAO,CAAC,KAAK,QAAQ,IAAI,CAAC,MAAM,C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AAQ,CAAC,CAAC,CAAC,SAAS,CAAC;QAAE,MAAM,CAAC,IAAI,CAAC,gBAAgB,CAAC,CAAC;IACnF,IAAI,CAAC,CAAC,CAAC,OAAO;QAAE,MAAM,CAAC,IAAI,CAAC,iBAAiB,CAAC,CAAC;IAC/C,IAAI,CAAC,CAAC,CAAC,KAAK,EAAE,IAAI,EAAE;QAAE,MAAM,CAAC,IAAI,CAAC,aAAa,CAAC,CAAC;IACjD,IAAI,CAAC,SAAS,CAAC,CAAC,CAAC,EAAE,CAAC;QAAE,MAAM,CAAC,IAAI,CAAC,QAAQ,CAAC,CAAC;IAC5C,OAAO,MAAM,CAAC;AAChB,CAAC"}
package/dist/index.d.ts CHANGED
@@ -4,4 +4,5 @@ export declare const SPEC_REF = "specs/310-agentic-trust-home-control-plane-and-
4
4
  export { type ProofRefV1, type PolicyRefV1, type AuditRefV1, type EndpointRefV1, type StoreRefV1, type AppRefV1, type HomeSurfaceKind, type HomeSurfaceDescriptorV1, type HomeEndpointSetV1, type HomeCapabilityCardV1, type HomeCryptoProfileDescriptorV1, type HomeInboxBindingV1, type HomeManifestV1, type HomeContextV1, type ManagedAgentEntryV1, type ConnectedAppGrantV1, type HomeCardUiProfile, type HomeActionCardKind, type HomeActionDescriptorV1, type HomeActionCardV1, type HomeControlEventV1, } from './types.js';
5
5
  export { type ManifestValidationError, validateHomeManifest, isManifestCurrent, type ManifestVerificationPort, type CardValidationError, validateHomeActionCard, resolveCardAction, } from './validate.js';
6
6
  export { type HomeInboxSummaryV1, projectHomeInboxSummary } from './projection.js';
7
+ export { type EndeavorLifecycle, ENDEAVOR_LIFECYCLES, type EndeavorParticipationRole, type ContributionStateFact, CONTRIBUTION_STATE_FACTS, type HomePlanRevisionRefV1, type HomeEndeavorSummaryV1, type HomeContributionEntryV1, type HomeDecisionCardV1, type AgentRunState, type HomeAgentRunEntryV1, type HomePortfolioSummaryV1, type HomeCapacitySummaryV1, type HomeCoordinationAlertKind, COORDINATION_ALERT_KINDS, type HomeCoordinationAlertV1, type EndeavorSummaryValidationError, validateHomeEndeavorSummary, type ContributionEntryValidationError, validateHomeContributionEntry, type DecisionCardValidationError, validateHomeDecisionCard, type CoordinationAlertValidationError, validateHomeCoordinationAlert, } from './coordination.js';
7
8
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAUA,eAAO,MAAM,YAAY,4BAA4B,CAAC;AACtD,eAAO,MAAM,cAAc,EAAG,cAAuB,CAAC;AACtD,eAAO,MAAM,QAAQ,4DAA4D,CAAC;AAElF,OAAO,EACL,KAAK,UAAU,EACf,KAAK,WAAW,EAChB,KAAK,UAAU,EACf,KAAK,aAAa,EAClB,KAAK,UAAU,EACf,KAAK,QAAQ,EACb,KAAK,eAAe,EACpB,KAAK,uBAAuB,EAC5B,KAAK,iBAAiB,EACtB,KAAK,oBAAoB,EACzB,KAAK,6BAA6B,EAClC,KAAK,kBAAkB,EACvB,KAAK,cAAc,EACnB,KAAK,aAAa,EAClB,KAAK,mBAAmB,EACxB,KAAK,mBAAmB,EACxB,KAAK,iBAAiB,EACtB,KAAK,kBAAkB,EACvB,KAAK,sBAAsB,EAC3B,KAAK,gBAAgB,EACrB,KAAK,kBAAkB,GACxB,MAAM,YAAY,CAAC;AAEpB,OAAO,EACL,KAAK,uBAAuB,EAC5B,oBAAoB,EACpB,iBAAiB,EACjB,KAAK,wBAAwB,EAC7B,KAAK,mBAAmB,EACxB,sBAAsB,EACtB,iBAAiB,GAClB,MAAM,eAAe,CAAC;AAEvB,OAAO,EAAE,KAAK,kBAAkB,EAAE,uBAAuB,EAAE,MAAM,iBAAiB,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAUA,eAAO,MAAM,YAAY,4BAA4B,CAAC;AACtD,eAAO,MAAM,cAAc,EAAG,cAAuB,CAAC;AACtD,eAAO,MAAM,QAA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PACKAGE_STATUS = 'w1-contracts';
12
12
  export const SPEC_REF = 'specs/310-agentic-trust-home-control-plane-and-inbox.md';
13
13
  export { validateHomeManifest, isManifestCurrent, validateHomeActionCard, resolveCardAction, } from './validate.js';
14
14
  export { projectHomeInboxSummary } from './projection.js';
15
+ // Coordination projections (spec 334 §8) — portable render contracts over the
16
+ // spec-332/333 coordination records + audit rows. Projections only: none is a
17
+ // source of truth and none carries authority.
18
+ export { ENDEAVOR_LIFECYCLES, CONTRIBUTION_STATE_FACTS, COORDINATION_ALERT_KINDS, validateHomeEndeavorSummary, validateHomeContributionEntry, validateHomeDecisionCard, validateHomeCoordinationAlert, } from './coordination.js';
15
19
  //# sourceMappingURL=index.js.map
package/dist/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,8EAA8E;AAC9E,+EAA+E;AAC/E,mEAAmE;AACnE,4EAA4E;AAC5E,EAAE;AACF,uEAAuE;AACvE,+EAA+E;AAC/E,oEAAoE;AACpE,oEAAoE;AAEpE,MAAM,CAAC,MAAM,YAAY,GAAG,yBAAyB,CAAC;AACtD,MAAM,CAAC,MAAM,cAAc,GAAG,cAAuB,CAAC;AACtD,MAAM,CAAC,MAAM,QAAQ,GAAG,yDAAyD,CAAC;AA0BlF,OAAO,EAEL,oBAAoB,EACpB,iBAAiB,EAGjB,sBAAsB,EACtB,iBAAiB,GAClB,MAAM,eAAe,CAAC;AAEvB,OAAO,EAA2B,uBAAuB,EAAE,MAAM,iBAAiB,CAAC"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,8EAA8E;AAC9E,+EAA+E;AAC/E,mEAAmE;AACnE,4EAA4E;AAC5E,EAAE;AACF,uEAAuE;AACvE,+EAA+E;AAC/E,oEAAoE;AACpE,oEAAoE;AAEpE,MAAM,CAAC,MAAM,YAAY,GAAG,yBAAyB,CAAC;AACtD,MAAM,CAAC,MAAM,cAAc,GAAG,cAAuB,CAAC;AACtD,MAAM,CAAC,MAAM,QAAQ,GAAG,yDAAyD,CAAC;AA0BlF,OAAO,EAEL,oBAAoB,EACpB,iBAAiB,EAGjB,sBAAsB,EACtB,iBAAiB,GAClB,MAAM,eAAe,CAAC;AAEvB,OAAO,EAA2B,uBAAuB,EAAE,MAAM,iBAAiB,CAAC;AAEnF,8EAA8E;AAC9E,8EAA8E;AAC9E,8CAA8C;AAC9C,OAAO,EAEL,mBAAmB,EAGnB,wBAAwB,EAUxB,wBAAwB,EAGxB,2BAA2B,EAE3B,6BAA6B,EAE7B,wBAAwB,EAExB,6BAA6B,GAC9B,MAAM,mBAAmB,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@agenticprimitives/home",
3
- "version": "0.0.0-alpha.1",
3
+ "version": "0.0.0-alpha.4",
4
4
  "description": "Portable Agentic Trust Home contracts (spec 310): signed Home manifests, surface descriptors, inbox bindings, action cards, managed-agent/connected-app projections, control-plane events. Schema + validation + deterministic projection only — no routes, UI, or branding.",
5
5
  "license": "MIT",
6
6
  "repository": {
@@ -31,8 +31,8 @@
31
31
  "access": "public"
32
32
  },
33
33
  "dependencies": {
34
- "@agenticprimitives/fabric": "0.0.0-alpha.1",
35
- "@agenticprimitives/types": "1.0.0-alpha.17",
34
+ "@agenticprimitives/fabric": "0.0.0-alpha.4",
35
+ "@agenticprimitives/types": "1.0.0-alpha.20",
36
36
  "@agenticprimitives/vault": "0.0.0-alpha.2"
37
37
  },
38
38
  "devDependencies": {