@agenticprimitives/fabric 0.0.0-alpha.4 → 0.0.0-alpha.8
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.
- package/CLAUDE.md +22 -2
- package/README.md +16 -16
- package/dist/case-emissions.d.ts +95 -0
- package/dist/case-emissions.d.ts.map +1 -0
- package/dist/case-emissions.js +208 -0
- package/dist/case-emissions.js.map +1 -0
- package/dist/case-machine.d.ts +28 -2
- package/dist/case-machine.d.ts.map +1 -1
- package/dist/case-machine.js +34 -7
- package/dist/case-machine.js.map +1 -1
- package/dist/cloudflare/index.d.ts +1 -0
- package/dist/cloudflare/index.d.ts.map +1 -1
- package/dist/cloudflare/index.js +4 -0
- package/dist/cloudflare/index.js.map +1 -1
- package/dist/cloudflare/interaction-store.d.ts +55 -0
- package/dist/cloudflare/interaction-store.d.ts.map +1 -0
- package/dist/cloudflare/interaction-store.js +230 -0
- package/dist/cloudflare/interaction-store.js.map +1 -0
- package/dist/cloudflare/principal-gateway-do.d.ts +118 -2
- package/dist/cloudflare/principal-gateway-do.d.ts.map +1 -1
- package/dist/cloudflare/principal-gateway-do.js +182 -7
- package/dist/cloudflare/principal-gateway-do.js.map +1 -1
- package/dist/communicative-act.d.ts +24 -1
- package/dist/communicative-act.d.ts.map +1 -1
- package/dist/communicative-act.js +28 -0
- package/dist/communicative-act.js.map +1 -1
- package/dist/delivery-envelope.d.ts.map +1 -1
- package/dist/delivery-envelope.js +0 -1
- package/dist/delivery-envelope.js.map +1 -1
- package/dist/enum-retirement.d.ts +43 -0
- package/dist/enum-retirement.d.ts.map +1 -0
- package/dist/enum-retirement.js +93 -0
- package/dist/enum-retirement.js.map +1 -0
- package/dist/exchange-record.d.ts +35 -4
- package/dist/exchange-record.d.ts.map +1 -1
- package/dist/exchange-record.js.map +1 -1
- package/dist/exchange-reducer.d.ts +32 -4
- package/dist/exchange-reducer.d.ts.map +1 -1
- package/dist/exchange-reducer.js +75 -1
- package/dist/exchange-reducer.js.map +1 -1
- package/dist/exchange-state.d.ts +30 -8
- package/dist/exchange-state.d.ts.map +1 -1
- package/dist/exchange-state.js +12 -10
- package/dist/exchange-state.js.map +1 -1
- package/dist/inbox-doc.d.ts +2 -2
- package/dist/inbox-doc.d.ts.map +1 -1
- package/dist/inbox-doc.js.map +1 -1
- package/dist/inbox-projection.d.ts +2 -2
- package/dist/inbox-projection.d.ts.map +1 -1
- package/dist/inbox-projection.js.map +1 -1
- package/dist/index.d.ts +21 -3
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +32 -2
- package/dist/index.js.map +1 -1
- package/dist/interaction-machines.d.ts +136 -0
- package/dist/interaction-machines.d.ts.map +1 -0
- package/dist/interaction-machines.js +174 -0
- package/dist/interaction-machines.js.map +1 -0
- package/dist/interaction-profile.d.ts +126 -0
- package/dist/interaction-profile.d.ts.map +1 -0
- package/dist/interaction-profile.js +192 -0
- package/dist/interaction-profile.js.map +1 -0
- package/dist/interaction-record.d.ts +168 -0
- package/dist/interaction-record.d.ts.map +1 -0
- package/dist/interaction-record.js +108 -0
- package/dist/interaction-record.js.map +1 -0
- package/dist/interactions/machine.d.ts +2 -2
- package/dist/interactions/machine.d.ts.map +1 -1
- package/dist/interactions/machine.js +2 -2
- package/dist/interactions/machine.js.map +1 -1
- package/dist/interactions/store.d.ts +9 -0
- package/dist/interactions/store.d.ts.map +1 -1
- package/dist/interactions/store.js +57 -2
- package/dist/interactions/store.js.map +1 -1
- package/dist/messaging/board.d.ts +3 -3
- package/dist/messaging/board.d.ts.map +1 -1
- package/dist/messaging/board.js +2 -2
- package/dist/messaging/board.js.map +1 -1
- package/dist/messaging/conversation-interaction.d.ts +66 -0
- package/dist/messaging/conversation-interaction.d.ts.map +1 -0
- package/dist/messaging/conversation-interaction.js +139 -0
- package/dist/messaging/conversation-interaction.js.map +1 -0
- package/dist/messaging/delivery.d.ts +2 -2
- package/dist/messaging/delivery.d.ts.map +1 -1
- package/dist/messaging/delivery.js +8 -1
- package/dist/messaging/delivery.js.map +1 -1
- package/dist/messaging/envelope.d.ts +7 -3
- package/dist/messaging/envelope.d.ts.map +1 -1
- package/dist/messaging/envelope.js +18 -1
- package/dist/messaging/envelope.js.map +1 -1
- package/dist/messaging/hash.d.ts +8 -2
- package/dist/messaging/hash.d.ts.map +1 -1
- package/dist/messaging/hash.js +6 -0
- package/dist/messaging/hash.js.map +1 -1
- package/dist/messaging/inbox-assistant.d.ts +16 -4
- package/dist/messaging/inbox-assistant.d.ts.map +1 -1
- package/dist/messaging/inbox-assistant.js +27 -4
- package/dist/messaging/inbox-assistant.js.map +1 -1
- package/dist/messaging/index.d.ts +4 -1
- package/dist/messaging/index.d.ts.map +1 -1
- package/dist/messaging/index.js +4 -0
- package/dist/messaging/index.js.map +1 -1
- package/dist/messaging/projector.d.ts +3 -3
- package/dist/messaging/projector.d.ts.map +1 -1
- package/dist/messaging/projector.js.map +1 -1
- package/dist/messaging/receipts.d.ts +3 -3
- package/dist/messaging/receipts.d.ts.map +1 -1
- package/dist/messaging/receipts.js.map +1 -1
- package/dist/messaging/rules.d.ts +10 -3
- package/dist/messaging/rules.d.ts.map +1 -1
- package/dist/messaging/rules.js +8 -1
- package/dist/messaging/rules.js.map +1 -1
- package/dist/messaging/store.d.ts +4 -4
- package/dist/messaging/store.d.ts.map +1 -1
- package/dist/messaging/store.js +5 -3
- package/dist/messaging/store.js.map +1 -1
- package/dist/messaging/types.d.ts +30 -0
- package/dist/messaging/types.d.ts.map +1 -1
- package/dist/messaging/types.js +3 -0
- package/dist/messaging/types.js.map +1 -1
- package/dist/messaging/vault-store.d.ts +2 -2
- package/dist/messaging/vault-store.d.ts.map +1 -1
- package/dist/protocol-binding.d.ts +71 -0
- package/dist/protocol-binding.d.ts.map +1 -0
- package/dist/protocol-binding.js +0 -0
- package/dist/protocol-binding.js.map +1 -0
- package/dist/record-catalog.d.ts.map +1 -1
- package/dist/record-catalog.js +7 -0
- package/dist/record-catalog.js.map +1 -1
- package/package.json +7 -7
|
@@ -1,11 +1,13 @@
|
|
|
1
|
-
import type { MessageEnvelopeV1,
|
|
1
|
+
import type { MessageEnvelopeV1, MessageEventType, MessageId, Hex32, ContextRefV1 } from './messaging/index.js';
|
|
2
2
|
import { hashMessageEnvelope } from './messaging/index.js';
|
|
3
3
|
import type { AuthorityRef } from './interactions/index.js';
|
|
4
4
|
import type { AuthorityTier } from '@agenticprimitives/tool-policy';
|
|
5
5
|
import type { CanonicalAgentId } from '@agenticprimitives/types';
|
|
6
6
|
import type { VaultRef } from '@agenticprimitives/vault';
|
|
7
7
|
import type { ExecState, CaseState } from './exchange-state.js';
|
|
8
|
+
import type { DecisionState } from './interaction-machines.js';
|
|
8
9
|
import type { CaseTransition } from './case-machine.js';
|
|
10
|
+
import type { InteractionId, ProfileVersion, ContextDigest } from './interaction-record.js';
|
|
9
11
|
/** The exchange spine id — replaces today's `taskId` / `int_`+`run_` / `conv_`+`msg_` id families. */
|
|
10
12
|
export type ExchangeId = `xch_${string}`;
|
|
11
13
|
/**
|
|
@@ -82,12 +84,16 @@ export type ExchangeEventV1 = (ExchangeEventBase & {
|
|
|
82
84
|
* The ONE canonical exchange record (spec §b). Two-level FSM: `exec` (transport, always present) + `case`
|
|
83
85
|
* (business substate, execution-tier only). Authority is referenced, never satisfied here — approving a case
|
|
84
86
|
* advances `case`, it never unlocks a resource (ADR-0041).
|
|
87
|
+
*
|
|
88
|
+
* `kind: MessageKind` was REMOVED in spec 340 W8. It was a frozen taxonomy on the aggregate, it was a second
|
|
89
|
+
* copy of `envelope.kind`, and it had ZERO readers — the authority tier is server-classified from the skill
|
|
90
|
+
* selector, never from `kind`, and that comment was the only thing the field was doing. `profileVersion` is
|
|
91
|
+
* what carries interaction type now. `MessageEnvelopeV1.kind` is a DIFFERENT field and stays: it is inside
|
|
92
|
+
* the signed wire hash and has live readers (spec 340 §R.1).
|
|
85
93
|
*/
|
|
86
94
|
export interface ExchangeRecordV1 {
|
|
87
95
|
version: 'ap.exchange.v1';
|
|
88
96
|
exchangeId: ExchangeId;
|
|
89
|
-
/** Projection hint only — the authority TIER is server-classified from the skill selector, never `kind`. */
|
|
90
|
-
kind: MessageKind;
|
|
91
97
|
/** Server-classified ONCE at ingress (never client-asserted). */
|
|
92
98
|
tier: AuthorityTier;
|
|
93
99
|
/** The delegator / gateway owner SA — on whose behalf the exchange runs. Also the case RESPONDER by
|
|
@@ -108,8 +114,22 @@ export interface ExchangeRecordV1 {
|
|
|
108
114
|
resourceOwner?: CanonicalAgentId;
|
|
109
115
|
/** Transport envelope state (always present). */
|
|
110
116
|
exec: ExecState;
|
|
111
|
-
/**
|
|
117
|
+
/** Execution substate — execution-tier only; `undefined` for a T0 communication exchange. */
|
|
112
118
|
case?: CaseState;
|
|
119
|
+
/**
|
|
120
|
+
* spec 340 W10b-3 — the DECISION substate, projected onto this record.
|
|
121
|
+
*
|
|
122
|
+
* Until W10b-3 the ordering "you cannot issue before approving" was an FSM edge
|
|
123
|
+
* (`issue-credential` ran only `from: ['approved']`). With the determination out of `CaseState`,
|
|
124
|
+
* this reducer would otherwise have no way to know one was made, and issuance could skip it — a
|
|
125
|
+
* guarantee silently lost to a type change. So the reducer projects the decision state the same way
|
|
126
|
+
* it projects `exec` from `case`.
|
|
127
|
+
*
|
|
128
|
+
* A PROJECTION, not the record of record: the full `DecisionRecordV1` (with its decider and
|
|
129
|
+
* timestamps) lives in the interaction store's decision machine. This carries only what the
|
|
130
|
+
* precondition needs. It is never authority — a `granted` here permits nothing (ADR-0041).
|
|
131
|
+
*/
|
|
132
|
+
decision?: DecisionState;
|
|
113
133
|
/** The signed wire objects (deliveries, responses, decisions). */
|
|
114
134
|
envelopes: ExchangeEnvelopeV1[];
|
|
115
135
|
/** The single append-only event stream (single-writer in the DO). */
|
|
@@ -120,6 +140,17 @@ export interface ExchangeRecordV1 {
|
|
|
120
140
|
artifacts?: ArtifactRef[];
|
|
121
141
|
/** Entities this exchange is ABOUT (spec 312) — carried through from the envelope. */
|
|
122
142
|
contextRefs?: ContextRefV1[];
|
|
143
|
+
/** The governed situation this exchange occurs in. An Exchange without one is a message — a
|
|
144
|
+
* legitimate state, not an error, and the reason this is optional rather than required. */
|
|
145
|
+
interactionId?: InteractionId;
|
|
146
|
+
/** The EXACT profile version this exchange was made under, recorded HERE rather than read off the
|
|
147
|
+
* live interaction. Reading it off the interaction is what makes a downgrade invisible: an
|
|
148
|
+
* adversary edits one field and a Negotiation is reinterpreted as a Conversation, taking its
|
|
149
|
+
* acceptance semantics with it (spec 340 §6). */
|
|
150
|
+
profileVersion?: ProfileVersion;
|
|
151
|
+
/** Digest of the `ContextSnapshotV1` this exchange was evaluated against — by hash, never a pointer
|
|
152
|
+
* at live state. Supersedes `contextRefs` for authority-bearing context (spec 340 §7). */
|
|
153
|
+
contextDigest?: ContextDigest;
|
|
123
154
|
/** Monotonic revision for the inbox-projection cursor. */
|
|
124
155
|
rev: number;
|
|
125
156
|
updatedAt: string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"exchange-record.d.ts","sourceRoot":"","sources":["../src/exchange-record.ts"],"names":[],"mappings":"AAaA,OAAO,KAAK,EAAE,iBAAiB,EAAE,
|
|
1
|
+
{"version":3,"file":"exchange-record.d.ts","sourceRoot":"","sources":["../src/exchange-record.ts"],"names":[],"mappings":"AAaA,OAAO,KAAK,EAAE,iBAAiB,EAAE,gBAAgB,EAAE,SAAS,EAAE,KAAK,EAAE,YAAY,EAAE,MAAM,sBAAsB,CAAC;AAChH,OAAO,EAAE,mBAAmB,EAAE,MAAM,sBAAsB,CAAC;AAC3D,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,yBAAyB,CAAC;AAC5D,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,gCAAgC,CAAC;AACpE,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,0BAA0B,CAAC;AACjE,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,0BAA0B,CAAC;AACzD,OAAO,KAAK,EAAE,SAAS,EAAE,SAAS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aAAa,CAAC,EAAE,YAAY,EAAE,CAAC;IAC/B,0CAA0C;IAC1C,SAAS,CAAC,EAAE,WAAW,EAAE,CAAC;IAC1B,sFAAsF;IACtF,WAAW,CAAC,EAAE,YAAY,EAAE,CAAC;IAI7B;gGAC4F;IAC5F,aAAa,CAAC,EAAE,aAAa,CAAC;IAC9B;;;sDAGkD;IAClD,cAAc,CAAC,EAAE,cAAc,CAAC;IAChC;+FAC2F;IAC3F,aAAa,CAAC,EAAE,aAAa,CAAC;IAE9B,0DAA0D;IAC1D,GAAG,EAAE,MAAM,CAAC;IACZ,SAAS,EAAE,MAAM,CAAC;IAClB,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAED;uGACuG;AACvG,wBAAgB,OAAO,CAAC,MAAM,EAAE,IAAI,CAAC,gBAAgB,EAAE,OAAO,GAAG,WAAW,CAAC,GAAG,gBAAgB,CAE/F"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"exchange-record.js","sourceRoot":"","sources":["../src/exchange-record.ts"],"names":[],"mappings":"AAAA,yGAAyG;AACzG,6GAA6G;AAC7G,0GAA0G;AAC1G,EAAE;AACF,oGAAoG;AACpG,2GAA2G;AAC3G,6GAA6G;AAC7G,8GAA8G;AAC9G,+EAA+E;AAC/E,EAAE;AACF,4GAA4G;AAC5G,oGAAoG;AAGpG,OAAO,EAAE,mBAAmB,EAAE,MAAM,sBAAsB,CAAC;
|
|
1
|
+
{"version":3,"file":"exchange-record.js","sourceRoot":"","sources":["../src/exchange-record.ts"],"names":[],"mappings":"AAAA,yGAAyG;AACzG,6GAA6G;AAC7G,0GAA0G;AAC1G,EAAE;AACF,oGAAoG;AACpG,2GAA2G;AAC3G,6GAA6G;AAC7G,8GAA8G;AAC9G,+EAA+E;AAC/E,EAAE;AACF,4GAA4G;AAC5G,oGAAoG;AAGpG,OAAO,EAAE,mBAAmB,EAAE,MAAM,sBAAsB,CAAC;AAmC3D;;kDAEkD;AAClD,MAAM,CAAC,MAAM,oBAAoB,GAAG,mBAAmB,CAAC;AACxD,uFAAuF;AACvF,MAAM,CAAC,MAAM,kBAAkB,GAAG,mBAAmB,CAAC;AA+GtD;uGACuG;AACvG,MAAM,UAAU,OAAO,CAAC,MAAqD;IAC3E,OAAO,MAAM,CAAC,KAAK,IAAI,MAAM,CAAC,SAAS,CAAC;AAC1C,CAAC"}
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { type CaseFsmFields } from './case-machine.js';
|
|
2
2
|
import type { ExchangeRecordV1, ExchangeEventV1 } from './exchange-record.js';
|
|
3
|
+
import type { Hex32 } from './messaging/index.js';
|
|
3
4
|
export type ExchangeApplyResult = {
|
|
4
5
|
ok: true;
|
|
5
6
|
record: ExchangeRecordV1;
|
|
@@ -16,10 +17,37 @@ export type ExchangeApplyResult = {
|
|
|
16
17
|
* `null` for a case-less (T0) exchange.
|
|
17
18
|
*/
|
|
18
19
|
export declare function caseViewFromRecord(record: ExchangeRecordV1): CaseFsmFields | null;
|
|
20
|
+
export declare function applyExchangeEvent(record: ExchangeRecordV1, event: ExchangeEventV1): ExchangeApplyResult;
|
|
21
|
+
/** Bumped ONLY when a fold changes an output for inputs it already accepted. Adding a rejection reason
|
|
22
|
+
* is not a bump; changing what an accepted event does to the record is. */
|
|
23
|
+
export declare const EXCHANGE_REDUCER_VERSION: "ap.exchange-reducer.v1";
|
|
24
|
+
export interface MaterializationProvenanceV1 {
|
|
25
|
+
reducerVersion: typeof EXCHANGE_REDUCER_VERSION;
|
|
26
|
+
/** sha256 over the canonical event array — order-sensitive, because the fold is. */
|
|
27
|
+
eventSetDigest: Hex32;
|
|
28
|
+
eventCount: number;
|
|
29
|
+
}
|
|
30
|
+
/** Digest of the exact event sequence a materialization consumed. Order-sensitive on purpose: the same
|
|
31
|
+
* events in a different order are a different history, and folding them yields a different record. */
|
|
32
|
+
export declare function eventSetDigest(events: readonly ExchangeEventV1[]): Promise<Hex32>;
|
|
33
|
+
export type ExchangeReplayResult = {
|
|
34
|
+
ok: true;
|
|
35
|
+
record: ExchangeRecordV1;
|
|
36
|
+
provenance: MaterializationProvenanceV1;
|
|
37
|
+
} | {
|
|
38
|
+
ok: false;
|
|
39
|
+
reason: string;
|
|
40
|
+
atSeq: number;
|
|
41
|
+
};
|
|
19
42
|
/**
|
|
20
|
-
*
|
|
21
|
-
*
|
|
22
|
-
*
|
|
43
|
+
* Rebuild an exchange from its event stream, and return the state WITH the evidence of how it was
|
|
44
|
+
* built.
|
|
45
|
+
*
|
|
46
|
+
* `seed` is the record as it existed before any event — the identity fields only. Its `events` are
|
|
47
|
+
* ignored and replaced by the fold, so replaying an already-materialized record cannot double-apply.
|
|
48
|
+
*
|
|
49
|
+
* Failure carries `atSeq` rather than just a reason: on a stream of two hundred events, "illegal
|
|
50
|
+
* transition" without the position is not a diagnosis.
|
|
23
51
|
*/
|
|
24
|
-
export declare function
|
|
52
|
+
export declare function replayExchange(seed: ExchangeRecordV1, events: readonly ExchangeEventV1[]): Promise<ExchangeReplayResult>;
|
|
25
53
|
//# sourceMappingURL=exchange-reducer.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"exchange-reducer.d.ts","sourceRoot":"","sources":["../src/exchange-reducer.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"exchange-reducer.d.ts","sourceRoot":"","sources":["../src/exchange-reducer.ts"],"names":[],"mappings":"AAkBA,OAAO,EAAuB,KAAK,aAAa,EAAuB,MAAM,mBAAmB,CAAC;AAEjG,OAAO,KAAK,EAAE,gBAAgB,EAAE,eAAe,EAAE,MAAM,sBAAsB,CAAC;AAC9E,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,sBAAsB,CAAC;AAGlD,MAAM,MAAM,mBAAmB,GAC3B;IAAE,EAAE,EAAE,IAAI,CAAC;IAAC,MAAM,EAAE,gBAAgB,CAAC;IAAC,OAAO,EAAE,OAAO,CAAA;CAAE,GACxD;IAAE,EAAE,EAAE,KAAK,CAAC;IAAC,MAAM,EAAE,MAAM,CAAA;CAAE,CAAC;AAElC;;;;;;GAMG;AACH,wBAAgB,kBAAkB,CAAC,MAAM,EAAE,gBAAgB,GAAG,aAAa,GAAG,IAAI,CAajF;AAiCD,wBAAgB,kBAAkB,CAAC,MAAM,EAAE,gBAAgB,EAAE,KAAK,EAAE,eAAe,GAAG,mBAAmB,CAwExG;AAaD;4EAC4E;AAC5E,eAAO,MAAM,wBAAwB,EAAG,wBAAiC,CAAC;AAE1E,MAAM,WAAW,2BAA2B;IAC1C,cAAc,EAAE,OAAO,wBAAwB,CAAC;IAChD,oFAAoF;IACpF,cAAc,EAAE,KAAK,CAAC;IACtB,UAAU,EAAE,MAAM,CAAC;CACpB;AAED;uGACuG;AACvG,wBAAsB,cAAc,CAAC,MAAM,EAAE,SAAS,eAAe,EAAE,GAAG,OAAO,CAAC,KAAK,CAAC,CAEvF;AAED,MAAM,MAAM,oBAAoB,GAC5B;IAAE,EAAE,EAAE,IAAI,CAAC;IAAC,MAAM,EAAE,gBAAgB,CAAC;IAAC,UAAU,EAAE,2BAA2B,CAAA;CAAE,GAC/E;IAAE,EAAE,EAAE,KAAK,CAAC;IAAC,MAAM,EAAE,MAAM,CAAC;IAAC,KAAK,EAAE,MAAM,CAAA;CAAE,CAAC;AAEjD;;;;;;;;;GASG;AACH,wBAAsB,cAAc,CAClC,IAAI,EAAE,gBAAgB,EACtB,MAAM,EAAE,SAAS,eAAe,EAAE,GACjC,OAAO,CAAC,oBAAoB,CAAC,CAgB/B"}
|
package/dist/exchange-reducer.js
CHANGED
|
@@ -13,8 +13,10 @@
|
|
|
13
13
|
//
|
|
14
14
|
// Fail-closed: an illegal case transition, an inconsistent transport move, or a seq gap is a typed rejection,
|
|
15
15
|
// never a silent state change. Idempotent: a replayed event (same `idempotencyKey`) is a no-op.
|
|
16
|
+
import { canonicalizeJson } from '@agenticprimitives/types';
|
|
16
17
|
import { canTaskTransition, expectedExecForCase, isExecCaseConsistent } from './exchange-state.js';
|
|
17
18
|
import { applyCaseTransition } from './case-machine.js';
|
|
19
|
+
import { sha256Hex32 } from './messaging/index.js';
|
|
18
20
|
/**
|
|
19
21
|
* Derive the transient case FSM view from a lean `ExchangeRecordV1` (option (a) — the record stays the lean
|
|
20
22
|
* spine; the case view is constructed only when applying a transition). Role convention: `requester` = the
|
|
@@ -42,6 +44,28 @@ export function caseViewFromRecord(record) {
|
|
|
42
44
|
* next slot (`record.events.length`). Returns the next record (`changed: true`), a no-op for an idempotent
|
|
43
45
|
* replay (`changed: false`), or a typed rejection.
|
|
44
46
|
*/
|
|
47
|
+
/**
|
|
48
|
+
* spec 340 W10b-3 — the decision substate this record projects, given the transition just applied.
|
|
49
|
+
*
|
|
50
|
+
* Mirrors `caseTransitionEmissions`' decision half deliberately narrowly: the reducer holds no
|
|
51
|
+
* `DecisionRecordV1` (no decider, no timestamps), only the state the `issue-credential` precondition
|
|
52
|
+
* needs. The authoritative record lives in the interaction store's decision machine.
|
|
53
|
+
*
|
|
54
|
+
* `undefined` in, `undefined` out for every non-deciding transition — this never invents a
|
|
55
|
+
* determination, and a transition that decides nothing leaves the projection exactly as it was.
|
|
56
|
+
*/
|
|
57
|
+
function nextDecisionState(current, transition) {
|
|
58
|
+
switch (transition) {
|
|
59
|
+
case 'approve':
|
|
60
|
+
return 'granted';
|
|
61
|
+
case 'deny':
|
|
62
|
+
return 'refused';
|
|
63
|
+
case 'expire':
|
|
64
|
+
return 'expired';
|
|
65
|
+
default:
|
|
66
|
+
return current;
|
|
67
|
+
}
|
|
68
|
+
}
|
|
45
69
|
export function applyExchangeEvent(record, event) {
|
|
46
70
|
// Idempotent replay — a matching key already in the stream is a no-op (no second row).
|
|
47
71
|
if (event.idempotencyKey && record.events.some((e) => e.idempotencyKey === event.idempotencyKey)) {
|
|
@@ -77,7 +101,10 @@ export function applyExchangeEvent(record, event) {
|
|
|
77
101
|
messageId: event.messageId,
|
|
78
102
|
evidenceRef: event.evidenceRef,
|
|
79
103
|
authorityRef: event.authorityRef,
|
|
80
|
-
}
|
|
104
|
+
},
|
|
105
|
+
// W10b-3: supply the decision this record has projected so far, so `issue-credential` still
|
|
106
|
+
// cannot precede a grant now that the ordering is no longer an FSM edge.
|
|
107
|
+
{ decisionState: record.decision ?? null });
|
|
81
108
|
if (!res.ok)
|
|
82
109
|
return { ok: false, reason: `case:${res.reason}` };
|
|
83
110
|
const nextCase = res.case.state;
|
|
@@ -88,6 +115,7 @@ export function applyExchangeEvent(record, event) {
|
|
|
88
115
|
...appended,
|
|
89
116
|
case: nextCase,
|
|
90
117
|
exec: expectedExecForCase(nextCase), // projection — the case FSM is the authority
|
|
118
|
+
decision: nextDecisionState(record.decision, event.transition),
|
|
91
119
|
authorityRefs: res.case.authorityRefs,
|
|
92
120
|
},
|
|
93
121
|
};
|
|
@@ -105,4 +133,50 @@ export function applyExchangeEvent(record, event) {
|
|
|
105
133
|
}
|
|
106
134
|
}
|
|
107
135
|
}
|
|
136
|
+
// ─── Materialization provenance (spec 340 INV-340-8) ─────────────────────────
|
|
137
|
+
//
|
|
138
|
+
// "Materialized state rebuilds deterministically from signed events" is a claim, and a claim nobody can
|
|
139
|
+
// check is a hope. Two things make it checkable, and both must travel WITH the rebuilt state:
|
|
140
|
+
//
|
|
141
|
+
// eventSetDigest — WHICH events produced this. Without it, a state that silently dropped an event
|
|
142
|
+
// and a state that legitimately never received one are indistinguishable.
|
|
143
|
+
// reducerVersion — WHICH rules produced this. Two nodes on different reducer versions can fold the
|
|
144
|
+
// same events into different states and both be internally consistent; the
|
|
145
|
+
// disagreement then looks like data corruption instead of a version skew.
|
|
146
|
+
/** Bumped ONLY when a fold changes an output for inputs it already accepted. Adding a rejection reason
|
|
147
|
+
* is not a bump; changing what an accepted event does to the record is. */
|
|
148
|
+
export const EXCHANGE_REDUCER_VERSION = 'ap.exchange-reducer.v1';
|
|
149
|
+
/** Digest of the exact event sequence a materialization consumed. Order-sensitive on purpose: the same
|
|
150
|
+
* events in a different order are a different history, and folding them yields a different record. */
|
|
151
|
+
export async function eventSetDigest(events) {
|
|
152
|
+
return sha256Hex32(canonicalizeJson(events));
|
|
153
|
+
}
|
|
154
|
+
/**
|
|
155
|
+
* Rebuild an exchange from its event stream, and return the state WITH the evidence of how it was
|
|
156
|
+
* built.
|
|
157
|
+
*
|
|
158
|
+
* `seed` is the record as it existed before any event — the identity fields only. Its `events` are
|
|
159
|
+
* ignored and replaced by the fold, so replaying an already-materialized record cannot double-apply.
|
|
160
|
+
*
|
|
161
|
+
* Failure carries `atSeq` rather than just a reason: on a stream of two hundred events, "illegal
|
|
162
|
+
* transition" without the position is not a diagnosis.
|
|
163
|
+
*/
|
|
164
|
+
export async function replayExchange(seed, events) {
|
|
165
|
+
let record = { ...seed, events: [] };
|
|
166
|
+
for (const event of events) {
|
|
167
|
+
const res = applyExchangeEvent(record, event);
|
|
168
|
+
if (!res.ok)
|
|
169
|
+
return { ok: false, reason: res.reason, atSeq: event.seq };
|
|
170
|
+
record = res.record;
|
|
171
|
+
}
|
|
172
|
+
return {
|
|
173
|
+
ok: true,
|
|
174
|
+
record,
|
|
175
|
+
provenance: {
|
|
176
|
+
reducerVersion: EXCHANGE_REDUCER_VERSION,
|
|
177
|
+
eventSetDigest: await eventSetDigest(events),
|
|
178
|
+
eventCount: events.length,
|
|
179
|
+
},
|
|
180
|
+
};
|
|
181
|
+
}
|
|
108
182
|
//# sourceMappingURL=exchange-reducer.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"exchange-reducer.js","sourceRoot":"","sources":["../src/exchange-reducer.ts"],"names":[],"mappings":"AAAA,qGAAqG;AACrG,0GAA0G;AAC1G,6FAA6F;AAC7F,EAAE;AACF,2GAA2G;AAC3G,2GAA2G;AAC3G,6GAA6G;AAC7G,oEAAoE;AACpE,2GAA2G;AAC3G,wDAAwD;AACxD,6GAA6G;AAC7G,+GAA+G;AAC/G,EAAE;AACF,8GAA8G;AAC9G,gGAAgG;AAEhG,OAAO,EAAE,iBAAiB,EAAE,mBAAmB,E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EAAE,GAAG,IAAI,EAAE,MAAM,EAAE,EAAE,EAAE,CAAC;IACvD,KAAK,MAAM,KAAK,IAAI,MAAM,EAAE,CAAC;QAC3B,MAAM,GAAG,GAAG,kBAAkB,CAAC,MAAM,EAAE,KAAK,CAAC,CAAC;QAC9C,IAAI,CAAC,GAAG,CAAC,EAAE;YAAE,OAAO,EAAE,EAAE,EAAE,KAAK,EAAE,MAAM,EAAE,GAAG,CAAC,MAAM,EAAE,KAAK,EAAE,KAAK,CAAC,GAAG,EAAE,CAAC;QACxE,MAAM,GAAG,GAAG,CAAC,MAAM,CAAC;IACtB,CAAC;IACD,OAAO;QACL,EAAE,EAAE,IAAI;QACR,MAAM;QACN,UAAU,EAAE;YACV,cAAc,EAAE,wBAAwB;YACxC,cAAc,EAAE,MAAM,cAAc,CAAC,MAAM,CAAC;YAC5C,UAAU,EAAE,MAAM,CAAC,MAAM;SAC1B;KACF,CAAC;AACJ,CAAC"}
|
package/dist/exchange-state.d.ts
CHANGED
|
@@ -4,20 +4,42 @@ export type ExecState = TaskState;
|
|
|
4
4
|
export { canTaskTransition };
|
|
5
5
|
/** All 8 transport `ExecState`s (mirrors `fulfillment` `TaskState`), for coverage assertions. */
|
|
6
6
|
export declare const EXEC_STATES: readonly ExecState[];
|
|
7
|
-
/**
|
|
8
|
-
*
|
|
9
|
-
|
|
7
|
+
/**
|
|
8
|
+
* The EXECUTION substate (spec 340 W10b-3), 8 states. Two earlier removals and one late one:
|
|
9
|
+
*
|
|
10
|
+
* - `delivered`/`seen` went in Blocker 6 — inbox read-receipt facts, not lifecycle transitions.
|
|
11
|
+
* - `approved`/`denied`/`expired`/`revoked` went in W10b-3. They were never execution. `approved`,
|
|
12
|
+
* `denied` and `expired` are DECISIONS and `revoked` is what happens to a COMMITMENT, so they now
|
|
13
|
+
* live in the machines that own them (spec 340 §R.2). One field was answering three questions with
|
|
14
|
+
* three different signers, which is why a case could be `denied` while a commitment stayed
|
|
15
|
+
* outstanding with nowhere to record it.
|
|
16
|
+
*
|
|
17
|
+
* `closed` replaces the terminal those four used to provide: the work was taken up and ended without
|
|
18
|
+
* issuance. It carries no verdict — the verdict is in the decision record. Deliberately not folded
|
|
19
|
+
* into `failed`: a denial is not a fault, and collapsing them would reclassify every refusal as an
|
|
20
|
+
* error (and would silently drop the `rejected` exec value, which nothing else produces).
|
|
21
|
+
*
|
|
22
|
+
* The TRANSITION VERBS did not change. `approve`/`deny`/`expire`/`revoke` are still transitions — they
|
|
23
|
+
* now emit into the decision and commitment machines and land the case on an execution state. That is
|
|
24
|
+
* what lets a stored v1 event log keep replaying with no migration (W10b-1).
|
|
25
|
+
*/
|
|
26
|
+
export type CaseState = 'draft' | 'submitted' | 'triaged' | 'needs-info' | 'issued' | 'completed' | 'closed' | 'failed';
|
|
10
27
|
export declare const CASE_STATES: readonly CaseState[];
|
|
11
28
|
/**
|
|
12
|
-
* EXEC_CASE_COUPLING (spec 316 §2) — the canonical `ExecState` each `CaseState` maps to. Exhaustive over
|
|
13
|
-
*
|
|
29
|
+
* EXEC_CASE_COUPLING (spec 316 §2) — the canonical `ExecState` each `CaseState` maps to. Exhaustive over
|
|
30
|
+
* all 8 `CaseState`. Rationale per row:
|
|
14
31
|
* - `draft`/`submitted` → `submitted` : case created, pre-triage/local — accepted, not yet worked.
|
|
15
|
-
* - `triaged
|
|
32
|
+
* - `triaged` → `working` : responder actively working the request.
|
|
16
33
|
* - `needs-info` → `input-required` : the ONLY case → `input-required` (blocked awaiting requester;
|
|
17
34
|
* A2A `input-required` = blocked on the SENDER, so `triaged` must NOT map here).
|
|
18
35
|
* - `issued`/`completed` → `completed`.
|
|
19
|
-
* - `
|
|
20
|
-
*
|
|
36
|
+
* - `closed` → `rejected` : taken up and ended without issuance — distinct from a failed
|
|
37
|
+
* task, which is the distinction `denied` used to carry. Keeping this row is
|
|
38
|
+
* what keeps `rejected` reachable at all; folding `closed` into `failed`
|
|
39
|
+
* would leave an `ExecState` no case produces.
|
|
40
|
+
* - `failed` → `failed` (canonical; `canceled` is the transport-set alternative).
|
|
41
|
+
*
|
|
42
|
+
* Still 6 case-derived exec values + the 2 transport-set ones = all 8 `ExecState`, unchanged by W10b-3.
|
|
21
43
|
*/
|
|
22
44
|
export declare const EXEC_CASE_COUPLING: Record<CaseState, ExecState>;
|
|
23
45
|
/**
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"exchange-state.d.ts","sourceRoot":"","sources":["../src/exchange-state.ts"],"names":[],"mappings":"AASA,OAAO,EAAE,iBAAiB,EAAE,KAAK,SAAS,EAAE,MAAM,gCAAgC,CAAC;AAEnF,yGAAyG;AACzG,MAAM,MAAM,SAAS,GAAG,SAAS,CAAC;AAClC,OAAO,EAAE,iBAAiB,EAAE,CAAC;AAE7B,iGAAiG;AACjG,eAAO,MAAM,WAAW,EAAE,SAAS,SAAS,EAElC,CAAC;AAEX;
|
|
1
|
+
{"version":3,"file":"exchange-state.d.ts","sourceRoot":"","sources":["../src/exchange-state.ts"],"names":[],"mappings":"AASA,OAAO,EAAE,iBAAiB,EAAE,KAAK,SAAS,EAAE,MAAM,gCAAgC,CAAC;AAEnF,yGAAyG;AACzG,MAAM,MAAM,SAAS,GAAG,SAAS,CAAC;AAClC,OAAO,EAAE,iBAAiB,EAAE,CAAC;AAE7B,iGAAiG;AACjG,eAAO,MAAM,WAAW,EAAE,SAAS,SAAS,EAElC,CAAC;AAEX;;;;;;;;;;;;;;;;;;GAkBG;AACH,MAAM,MAAM,SAAS,GACjB,OAAO,GAAG,WAAW,GAAG,SAAS,GAAG,YAAY,GAChD,QAAQ,GAAG,WAAW,GAAG,QAAQ,GAAG,QAAQ,CAAC;AAEjD,eAAO,MAAM,WAAW,EAAE,SAAS,SAAS,EAElC,CAAC;AAEX;;;;;;;;;;;;;;;GAeG;AACH,eAAO,MAAM,kBAAkB,EAAE,MAAM,CAAC,SAAS,EAAE,SAAS,CAS3D,CAAC;AAEF;;;;;;;;GAQG;AACH,eAAO,MAAM,kBAAkB,EAAE,SAAS,SAAS,EAA2C,CAAC;AAE/F,kHAAkH;AAClH,wBAAgB,mBAAmB,CAAC,SAAS,EAAE,SAAS,GAAG,SAAS,GAAG,SAAS,CAG/E;AAED;;;;;;GAMG;AACH,wBAAgB,oBAAoB,CAAC,IAAI,EAAE,SAAS,EAAE,SAAS,EAAE,SAAS,GAAG,SAAS,GAAG,OAAO,CAG/F;AAED;;;;;GAKG;AACH,wBAAgB,qBAAqB,CACnC,IAAI,EAAE;IAAE,IAAI,EAAE,SAAS,CAAC;IAAC,IAAI,CAAC,EAAE,SAAS,CAAA;CAAE,EAC3C,EAAE,EAAE;IAAE,IAAI,EAAE,SAAS,CAAC;IAAC,IAAI,CAAC,EAAE,SAAS,CAAA;CAAE,GACxC,OAAO,CAGT"}
|
package/dist/exchange-state.js
CHANGED
|
@@ -13,30 +13,32 @@ export const EXEC_STATES = [
|
|
|
13
13
|
'submitted', 'working', 'completed', 'failed', 'canceled', 'input-required', 'rejected', 'auth-required',
|
|
14
14
|
];
|
|
15
15
|
export const CASE_STATES = [
|
|
16
|
-
'draft', 'submitted', 'triaged', 'needs-info', '
|
|
16
|
+
'draft', 'submitted', 'triaged', 'needs-info', 'issued', 'completed', 'closed', 'failed',
|
|
17
17
|
];
|
|
18
18
|
/**
|
|
19
|
-
* EXEC_CASE_COUPLING (spec 316 §2) — the canonical `ExecState` each `CaseState` maps to. Exhaustive over
|
|
20
|
-
*
|
|
19
|
+
* EXEC_CASE_COUPLING (spec 316 §2) — the canonical `ExecState` each `CaseState` maps to. Exhaustive over
|
|
20
|
+
* all 8 `CaseState`. Rationale per row:
|
|
21
21
|
* - `draft`/`submitted` → `submitted` : case created, pre-triage/local — accepted, not yet worked.
|
|
22
|
-
* - `triaged
|
|
22
|
+
* - `triaged` → `working` : responder actively working the request.
|
|
23
23
|
* - `needs-info` → `input-required` : the ONLY case → `input-required` (blocked awaiting requester;
|
|
24
24
|
* A2A `input-required` = blocked on the SENDER, so `triaged` must NOT map here).
|
|
25
25
|
* - `issued`/`completed` → `completed`.
|
|
26
|
-
* - `
|
|
27
|
-
*
|
|
26
|
+
* - `closed` → `rejected` : taken up and ended without issuance — distinct from a failed
|
|
27
|
+
* task, which is the distinction `denied` used to carry. Keeping this row is
|
|
28
|
+
* what keeps `rejected` reachable at all; folding `closed` into `failed`
|
|
29
|
+
* would leave an `ExecState` no case produces.
|
|
30
|
+
* - `failed` → `failed` (canonical; `canceled` is the transport-set alternative).
|
|
31
|
+
*
|
|
32
|
+
* Still 6 case-derived exec values + the 2 transport-set ones = all 8 `ExecState`, unchanged by W10b-3.
|
|
28
33
|
*/
|
|
29
34
|
export const EXEC_CASE_COUPLING = {
|
|
30
35
|
draft: 'submitted',
|
|
31
36
|
submitted: 'submitted',
|
|
32
37
|
triaged: 'working',
|
|
33
38
|
'needs-info': 'input-required',
|
|
34
|
-
approved: 'working',
|
|
35
39
|
issued: 'completed',
|
|
36
40
|
completed: 'completed',
|
|
37
|
-
|
|
38
|
-
expired: 'failed',
|
|
39
|
-
revoked: 'failed',
|
|
41
|
+
closed: 'rejected',
|
|
40
42
|
failed: 'failed',
|
|
41
43
|
};
|
|
42
44
|
/**
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"exchange-state.js","sourceRoot":"","sources":["../src/exchange-state.ts"],"names":[],"mappings":"AAAA,2GAA2G;AAC3G,2GAA2G;AAC3G,4GAA4G;AAC5G,4GAA4G;AAC5G,gHAAgH;AAChH,EAAE;AACF,2GAA2G;AAC3G,4GAA4G;AAE5G,OAAO,EAAE,iBAAiB,EAAkB,MAAM,gCAAgC,CAAC;AAInF,OAAO,EAAE,iBAAiB,EAAE,CAAC;AAE7B,iGAAiG;AACjG,MAAM,CAAC,MAAM,WAAW,GAAyB;IAC/C,WAAW,EAAE,SAAS,EAAE,WAAW,EAAE,QAAQ,EAAE,UAAU,EAAE,gBAAgB,EAAE,UAAU,EAAE,eAAe;CAChG,CAAC;
|
|
1
|
+
{"version":3,"file":"exchange-state.js","sourceRo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OAAO,SAAS,KAAK,SAAS,CAAC;IACtE,OAAO,mBAAmB,CAAC,SAAS,CAAC,KAAK,IAAI,CAAC;AACjD,CAAC;AAED;;;;;GAKG;AACH,MAAM,UAAU,qBAAqB,CACnC,IAA2C,EAC3C,EAAyC;IAEzC,IAAI,CAAC,iBAAiB,CAAC,IAAI,CAAC,IAAI,EAAE,EAAE,CAAC,IAAI,CAAC;QAAE,OAAO,KAAK,CAAC;IACzD,OAAO,oBAAoB,CAAC,EAAE,CAAC,IAAI,EAAE,EAAE,CAAC,IAAI,CAAC,CAAC;AAChD,CAAC"}
|
package/dist/inbox-doc.d.ts
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { type ContextRefV1, type ConversationDescriptorV1, type InboxProjector, type
|
|
1
|
+
import { type ContextRefV1, type ConversationDescriptorV1, type InboxProjector, type AnyMessageEnvelope, type MessageEventV1 } from './messaging/index.js';
|
|
2
2
|
import { type ActionCardV1, type InteractionCaseV1, type InteractionMandateV1, type InteractionStore, type InteractionTransitionEventV1 } from './interactions/index.js';
|
|
3
3
|
export interface InboxDataV1 {
|
|
4
4
|
version: 1;
|
|
5
|
-
envelopes:
|
|
5
|
+
envelopes: AnyMessageEnvelope[];
|
|
6
6
|
events: MessageEventV1[];
|
|
7
7
|
/** Cases as they entered (draft) — current state is replayed from caseEvents. */
|
|
8
8
|
draftCases: InteractionCaseV1[];
|
package/dist/inbox-doc.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"inbox-doc.d.ts","sourceRoot":"","sources":["../src/inbox-doc.ts"],"names":[],"mappings":"AAKA,OAAO,EAEL,KAAK,YAAY,EACjB,KAAK,wBAAwB,EAC7B,KAAK,cAAc,
|
|
1
|
+
{"version":3,"file":"inbox-doc.d.ts","sourceRoot":"","sources":["../src/inbox-doc.ts"],"names":[],"mappings":"AAKA,OAAO,EAEL,KAAK,YAAY,EACjB,KAAK,wBAAwB,EAC7B,KAAK,cAAc,EAEn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,"file":"inbox-doc.js","sourceRoot":"","sources":["../src/inbox-doc.ts"],"names":[],"mappings":"AAAA,oGAAoG;AACpG,oGAAoG;AACpG,iGAAiG;AACjG,sGAAsG;AACtG,0DAA0D;AAC1D,OAAO,EACL,4BAA4B,
|
|
1
|
+
{"version":3,"file":"inbox-doc.js","sourceRoot":"","sources":["../src/inbox-doc.ts"],"names":[],"mappings":"AAAA,oGAAoG;AACpG,oGAAoG;AACpG,iGAAiG;AACjG,sGAAsG;AACtG,0DAA0D;AAC1D,OAAO,EACL,4BAA4B,GAO7B,MAAM,sBAAsB,CAAC;AAC9B,OAAO,EACL,8BAA8B,GAM/B,MAAM,yBAAyB,CAAC;AAkBjC,MAAM,UAAU,cAAc;IAC5B,OAAO,EAAE,OAAO,EAAE,CAAC,EAAE,SAAS,EAAE,EAAE,EAAE,MAAM,EAAE,EAAE,EAAE,UAAU,EAAE,EAAE,EAAE,UAAU,EAAE,EAAE,EAAE,KAAK,EAAE,EAAE,EAAE,CAAC;AAC9F,CAAC;AAED,yGAAyG;AACzG,MAAM,UAAU,cAAc,CAAC,GAAW;IACxC,MAAM,EAAE,MAAM,EAAE,aAAa,EAAE,GAAG,GAAG,EAAE,GAAG,IAAI,CAAC,KAAK,CAAC,GAAG,CAAuC,CAAC;IAChG,OAAO,GAAkB,CAAC;AAC5B,CAAC;AAED,sFAAsF;AACtF,MAAM,UAAU,kBAAkB,CAAC,QAAgB,EAAE,GAAgB;IACnE,MAAM,SAAS,GAAG,4BAA4B,CAAC,EAAE,QAAQ,EAAE,CAAC,CAAC;IAC7D,KAAK,MAAM,QAAQ,IAAI,GAAG,CAAC,SAAS;QAAE,SAAS,CAAC,UAAU,CAAC,QAAQ,CAAC,CAAC;IACrE,KAAK,MAAM,KAAK,IAAI,GAAG,CAAC,MAAM;QAAE,SAAS,CAAC,WAAW,CAAC,KAAK,CAAC,CAAC;IAE7D,MAAM,YAAY,GAAG,8BAA8B,EAAE,CAAC;IACtD,KAAK,MAAM,CAAC,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AAa,IAAI,EAAE,CAAC;IACzC,MAAM,KAAK,GAAG,QAAQ,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,EAAE,KAAK,UAAU,CAAC,EAAE,CAAC,CAAC;IAC3D,IAAI,CAAC,KAAK,EAAE,CAAC;QACX,GAAG,CAAC,aAAa,GAAG,CAAC,GAAG,QAAQ,EAAE,UAAU,CAAC,CAAC;QAC9C,OAAO;IACT,CAAC;IACD,gBAAgB,CAAC,KAAK,EAAE,UAAU,CAAC,WAAW,CAAC,CAAC;AAClD,CAAC"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type {
|
|
1
|
+
import type { AnyMessageEnvelope, InboxItemV1 } from './messaging/index.js';
|
|
2
2
|
import type { ExchangeEventV1 } from './exchange-record.js';
|
|
3
3
|
/** A `kind:'message'` fabric event — the inbox-relevant slice of the stream. */
|
|
4
4
|
export type InboxProjectionEvent = Extract<ExchangeEventV1, {
|
|
@@ -9,7 +9,7 @@ export type InboxProjectionEvent = Extract<ExchangeEventV1, {
|
|
|
9
9
|
* seeds the row from the envelope. Adapts the fabric event to messaging's `MessageEventV1` and delegates to
|
|
10
10
|
* the absorbed `applyMessageEvent` reducer, so folder/unread semantics stay identical across the absorption.
|
|
11
11
|
*/
|
|
12
|
-
export declare function projectInboxItem(prev: InboxItemV1 | undefined, envelope:
|
|
12
|
+
export declare function projectInboxItem(prev: InboxItemV1 | undefined, envelope: AnyMessageEnvelope, event: InboxProjectionEvent): InboxItemV1;
|
|
13
13
|
export { applyMessageEvent, applyInboxRules, createInMemoryInboxProjector } from './messaging/index.js';
|
|
14
14
|
export type { InboxItemV1, InboxRuleV1, InboxProjector, CreateInboxProjectorOpts, FolderKind, } from './messaging/index.js';
|
|
15
15
|
//# sourceMappingURL=inbox-projection.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"inbox-projection.d.ts","sourceRoot":"","sources":["../src/inbox-projection.ts"],"names":[],"mappings":"AAUA,OAAO,KAAK,EAAE,
|
|
1
|
+
{"version":3,"file":"inbox-projection.d.ts","sourceRoot":"","sources":["../src/inbox-projection.ts"],"names":[],"mappings":"AAUA,OAAO,KAAK,EAAE,kBAAkB,EAAE,WAAW,EAAkB,MAAM,sBAAsB,CAAC;AAC5F,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,sBAAsB,CAAC;AAE5D,gFAAgF;AAChF,MAAM,MAAM,oBAAoB,GAAG,OAAO,CAAC,eAAe,EAAE;IAAE,IAAI,EAAE,SAAS,CAAA;CAAE,CAAC,CAAC;AAEjF;;;;GAIG;AACH,wBAAgB,gBAAgB,CAC9B,IAAI,EAAE,WAAW,GAAG,SAAS,EAC7B,QAAQ,EAAE,kBAAkB,EAC5B,KAAK,EAAE,oBAAoB,GAC1B,WAAW,CAUb;AAGD,OAAO,EAAE,iBAAiB,EAAE,eAAe,EAAE,4BAA4B,EAAE,MAAM,sBAAsB,CAAC;AACxG,YAAY,EACV,WAAW,EACX,WAAW,EACX,cAAc,EACd,wBAAwB,EACxB,UAAU,GACX,MAAM,sBAAsB,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"inbox-projection.js","sourceRoot":"","sources":["../src/inbox-projection.ts"],"names":[],"mappings":"AAAA,2GAA2G;AAC3G,uGAAuG;AACvG,8GAA8G;AAC9G,4GAA4G;AAC5G,0GAA0G;AAC1G,EAAE;AACF,4GAA4G;AAC5G,yEAAyE;AAEzE,OAAO,EAAE,iBAAiB,EAAE,MAAM,sBAAsB,CAAC;AAOzD;;;;GAIG;AACH,MAAM,UAAU,gBAAgB,CAC9B,IAA6B,EAC7B,
|
|
1
|
+
{"version":3,"file":"inbox-projection.js","sourceRoot":"","sources":["../src/inbox-projection.ts"],"names":[],"mappings":"AAAA,2GAA2G;AAC3G,uGAAuG;AACvG,8GAA8G;AAC9G,4GAA4G;AAC5G,0GAA0G;AAC1G,EAAE;AACF,4GAA4G;AAC5G,yEAAyE;AAEzE,OAAO,EAAE,iBAAiB,EAAE,MAAM,sBAAsB,CAAC;AAOzD;;;;GAIG;AACH,MAAM,UAAU,gBAAgB,CAC9B,IAA6B,EAC7B,QAA4B,EAC5B,KAA2B;IAE3B,MAAM,YAAY,GAAmB;QACnC,OAAO,EAAE,qBAAqB;QAC9B,SAAS,EAAE,KAAK,CAAC,SAAS;QAC1B,KAAK,EAAE,KAAK,CAAC,KAAK;QAClB,SAAS,EAAE,KAAK,CAAC,SAAS;QAC1B,EAAE,EAAE,KAAK,CAAC,EAAE;QACZ,WAAW,EAAE,KAAK,CAAC,WAAW;KAC/B,CAAC;IACF,OAAO,iBAAiB,CAAC,IAAI,EAAE,QAAQ,EAAE,YAAY,CAAC,CAAC;AACzD,CAAC;AAED,qGAAqG;AACrG,OAAO,EAAE,iBAAiB,EAAE,eAAe,EAAE,4BAA4B,EAAE,MAAM,sBAAsB,CAAC"}
|
package/dist/index.d.ts
CHANGED
|
@@ -1,13 +1,31 @@
|
|
|
1
1
|
export { canTaskTransition, canExchangeTransition, expectedExecForCase, isExecCaseConsistent, EXEC_CASE_COUPLING, TRANSPORT_SET_EXEC, EXEC_STATES, CASE_STATES, } from './exchange-state.js';
|
|
2
2
|
export type { ExecState, CaseState } from './exchange-state.js';
|
|
3
|
+
export { isEnvelopeV2 } from './messaging/types.js';
|
|
4
|
+
export type { AnyMessageEnvelope, MessageEnvelopeV1, MessageEnvelopeV2 } from './messaging/types.js';
|
|
3
5
|
export { hashExchangeEnvelope, hashIntentEnvelope, actorOf } from './exchange-record.js';
|
|
4
6
|
export type { ExchangeId, ExchangeEnvelopeV1, IntentEnvelopeV1, ExchangeRecordV1, ExchangeEventV1, ArtifactRef, } from './exchange-record.js';
|
|
5
|
-
export { performativeForKind } from './communicative-act.js';
|
|
7
|
+
export { performativeForKind, performativeOf, isOriginalMessage } from './communicative-act.js';
|
|
6
8
|
export type { Performative, CommunicativeActV1, SemanticContentRef, EvidenceRef, } from './communicative-act.js';
|
|
7
|
-
export { applyCaseTransition, isTerminalCaseState, TERMINAL_CASE_STATES, } from './case-machine.js';
|
|
8
|
-
export type { FabricCaseV1, CaseFsmFields, CaseTransition, CaseTransitionEventV1, CaseResult, CaseRejection, } from './case-machine.js';
|
|
9
|
+
export { applyCaseTransition, isTerminalCaseState, TERMINAL_CASE_STATES, requiresGrantedDecision, TRANSITIONS_REQUIRING_GRANTED_DECISION, } from './case-machine.js';
|
|
10
|
+
export type { FabricCaseV1, CaseFsmFields, CaseTransition, CaseTransitionEventV1, CaseResult, CaseRejection, CaseTransitionContext, } from './case-machine.js';
|
|
11
|
+
export { caseTransitionEmissions, applyCaseEmissions, seedDecision, seedCommitment, decisionIdForCase, commitmentIdForCase, EMITTING_CASE_TRANSITIONS, } from './case-emissions.js';
|
|
12
|
+
export type { CaseEmissionsV1, CaseEmissionApplyResult, EmissionOutcome, DecisionSeedV1, CommitmentSeedV1, } from './case-emissions.js';
|
|
9
13
|
export { applyExchangeEvent, caseViewFromRecord } from './exchange-reducer.js';
|
|
10
14
|
export type { ExchangeApplyResult } from './exchange-reducer.js';
|
|
15
|
+
export { EXCHANGE_REDUCER_VERSION, eventSetDigest, replayExchange } from './exchange-reducer.js';
|
|
16
|
+
export type { MaterializationProvenanceV1, ExchangeReplayResult } from './exchange-reducer.js';
|
|
17
|
+
export { PROTOCOL, looksCanonical, bindProtocol, bindingKey, buildBindingIndex, resolveInteractionByBinding, topicInteractionId, channelIdFromTopicInteraction, } from './protocol-binding.js';
|
|
18
|
+
export type { ProtocolBindingV1, BindingRejection, BindingIndex, BindingResolution } from './protocol-binding.js';
|
|
19
|
+
export { PROFILE_FOR_MESSAGE_KIND, MACHINE_FOR_CASE_STATE, machinesSpannedByCaseState } from './enum-retirement.js';
|
|
20
|
+
export type { OwningMachine } from './enum-retirement.js';
|
|
21
|
+
export { checkExchangeAgainstProfile, profileFor, PROFILE_LIBRARY, DIRECT_PROFILE, NEGOTIATION_PROFILE, CONSULTATION_PROFILE, ENGAGEMENT_PROFILE, TOPIC_PROFILE, ENGAGEMENT_RESPONSE_KIND_AXES, } from './interaction-profile.js';
|
|
22
|
+
export type { InteractionProfileV1, ProfileViolation, ExchangeUnderProfile, } from './interaction-profile.js';
|
|
23
|
+
export { applyInboxTransition, applyInteractionTransition, applyDecisionTransition, applyCommitmentTransition, mayDischargeOnExecution, TERMINAL_INTERACTION_STATES, TERMINAL_DECISION_STATES, TERMINAL_COMMITMENT_STATES, } from './interaction-machines.js';
|
|
24
|
+
export type { MachineRejection, MachineResult, InboxState, InboxTransition, InboxEntryV1, InteractionState, InteractionTransition, InteractionLifecycleV1, DecisionState, DecisionTransition, DecisionRecordV1, CommitmentState, CommitmentTransition, CommitmentRecordV1, } from './interaction-machines.js';
|
|
25
|
+
export { isProfileVersion, isFloatingVersion, checkReproducible, assertReproducible, hashContextSnapshot, buildContextSnapshot, verifyContextSnapshot, participantsAt, detectProfileDowngrades, } from './interaction-record.js';
|
|
26
|
+
export type { InteractionId, InteractionRecordV1, ProfileVersion, ParticipationV1, ContextDigest, ContextReferenceV1, ContextSnapshotV1, ContextReproducibilityFailure, ProfileDowngrade, } from './interaction-record.js';
|
|
27
|
+
export { conversationInteractionId, conversationIdFromInteraction, participationModeOfConversation, profileVersionOfConversation, participationsOfConversation, conversationPins, interactionViewOfConversation, participationModeOfChannel, interactionViewOfChannel, } from './messaging/conversation-interaction.js';
|
|
28
|
+
export type { ConversationExchangePins, ConversationInteractionView } from './messaging/conversation-interaction.js';
|
|
11
29
|
export { projectInboxItem, applyMessageEvent, applyInboxRules, createInMemoryInboxProjector, } from './inbox-projection.js';
|
|
12
30
|
export type { InboxProjectionEvent, InboxItemV1, InboxRuleV1, InboxProjector, CreateInboxProjectorOpts, FolderKind, } from './inbox-projection.js';
|
|
13
31
|
export { buildGatewaySurfaceCommitment, hashGatewaySurfaceCommitment, verifyGatewaySurfaceCommitment, } from './gateway-surface.js';
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AASA,OAAO,EACL,iBAAiB,EACjB,qBAAqB,EACrB,mBAAmB,EACnB,oBAAoB,EACpB,kBAAkB,EAClB,kBAAkB,EAClB,WAAW,EACX,WAAW,GACZ,MAAM,qBAAqB,CAAC;AAC7B,YAAY,EAAE,SAAS,EAAE,SAAS,EAAE,MAAM,qBAAqB,CAAC;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AASA,OAAO,EACL,iBAAiB,EACjB,qBAAqB,EACrB,mBAAmB,EACnB,oBAAoB,EACpB,kBAAkB,EAClB,kBAAkB,EAClB,WAAW,EACX,WAAW,GACZ,MAAM,qBAAqB,CAAC;AAC7B,YAAY,EAAE,SAAS,EAAE,SAAS,EAAE,MAAM,qBAAqB,CAAC;AAIhE,OAAO,EAAE,YAAY,EAAE,MAAM,sBAAsB,CAAC;AACpD,YAAY,EAAE,kBAAkB,EAAE,iBAAiB,EAAE,iBAAiB,EAAE,MAAM,sBAAsB,CAAC;AAGrG,OAAO,EAAE,oBAAoB,EAAE,kBAAkB,EAAE,OAAO,EAAE,MAAM,sBAAsB,CAAC;AACzF,YAAY,EACV,UAAU,EACV,kBAAkB,EAClB,gBAAgB,EAChB,gBAAgB,EAChB,eAAe,EACf,WAAW,GACZ,MAAM,sBAAsB,CAAC;AAG9B,OAAO,EAAE,mBAAmB,EAAE,cAAc,EAAE,iBAAiB,EAAE,MAAM,wBAAwB,CAAC;AAChG,YAAY,EACV,YAAY,EACZ,kBAAkB,EAClB,kBAAkB,EAClB,WAAW,GACZ,MAAM,wBAAwB,CAAC;AAGhC,OAAO,EACL,mBAAmB,EACnB,mBAAmB,EACnB,oBAAoB,EACpB,uBAAuB,EACvB,sCAAsC,GACvC,MAAM,mBAAmB,CAAC;AAC3B,YAAY,EACV,YAAY,EACZ,aAAa,EACb,cAAc,EACd,qBAAqB,EACrB,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EACL,qBAAqB,EACrB,qBAAqB,EACrB,wBAAwB,GACzB,MAAM,wBAAwB,CAAC;AAChC,YAAY,EAAE,kBAAkB,EAAE,iBAAiB,EAAE,MAAM,wBAAwB,CAAC;AAIpF,OAAO,EACL,cAAc,EACd,cAAc,EACd,kBAAkB,EAClB,gBAAgB,EAChB,kBAAkB,EAClB,KAAK,WAAW,GACjB,MAAM,gBAAgB,CAAC;AAIxB,OAAO,EAAE,cAAc,EAAE,eAAe,EAAE,KAAK,kBAAkB,EAAE,MAAM,qBAAqB,CAAC"}
|
package/dist/index.js
CHANGED
|
@@ -7,14 +7,44 @@
|
|
|
7
7
|
// Wave 1 (this slice): the two-level exec/case state machine spine. Envelope + inbox reducers + case
|
|
8
8
|
// payloads are absorbed from messaging/interactions in the subsequent Wave-1 steps.
|
|
9
9
|
export { canTaskTransition, canExchangeTransition, expectedExecForCase, isExecCaseConsistent, EXEC_CASE_COUPLING, TRANSPORT_SET_EXEC, EXEC_STATES, CASE_STATES, } from './exchange-state.js';
|
|
10
|
+
// spec 340 — the ap.message.v2 wire version and its dual-read seam. V1 is untouched and still
|
|
11
|
+
// verifies; V2 drops `kind` and carries `performative` natively. Readers take `AnyMessageEnvelope`.
|
|
12
|
+
export { isEnvelopeV2 } from './messaging/types.js';
|
|
10
13
|
// The canonical exchange object (spec 316 §b) — absorbs the messaging envelope + composes the two-level FSM.
|
|
11
14
|
export { hashExchangeEnvelope, hashIntentEnvelope, actorOf } from './exchange-record.js';
|
|
12
15
|
// Fabric semantic acts (spec 324 §9) — the speech-act layer over the transport envelope. Never authority.
|
|
13
|
-
export { performativeForKind } from './communicative-act.js';
|
|
16
|
+
export { performativeForKind, performativeOf, isOriginalMessage } from './communicative-act.js';
|
|
14
17
|
// The absorbed case (business-substate) machine — interactions FSM re-anchored on the 11-state CaseState.
|
|
15
|
-
export { applyCaseTransition, isTerminalCaseState, TERMINAL_CASE_STATES, } from './case-machine.js';
|
|
18
|
+
export { applyCaseTransition, isTerminalCaseState, TERMINAL_CASE_STATES, requiresGrantedDecision, TRANSITIONS_REQUIRING_GRANTED_DECISION, } from './case-machine.js';
|
|
19
|
+
// spec 340 W10 — what a case transition emits into the decision and commitment machines. The
|
|
20
|
+
// prerequisite §R.3 names for shrinking `CaseState` to execution: those states must land in their own
|
|
21
|
+
// machines before the enum can lose them.
|
|
22
|
+
export { caseTransitionEmissions, applyCaseEmissions, seedDecision, seedCommitment, decisionIdForCase, commitmentIdForCase, EMITTING_CASE_TRANSITIONS, } from './case-emissions.js';
|
|
16
23
|
// The unified exchange-event reducer (spec 316 §b/§2) — one append-only stream, one reducer over the record.
|
|
17
24
|
export { applyExchangeEvent, caseViewFromRecord } from './exchange-reducer.js';
|
|
25
|
+
// Materialization provenance (spec 340 INV-340-8) — rebuilt state travels WITH which events and which
|
|
26
|
+
// rules produced it, so a dropped event and a never-received one stop looking identical.
|
|
27
|
+
export { EXCHANGE_REDUCER_VERSION, eventSetDigest, replayExchange } from './exchange-reducer.js';
|
|
28
|
+
// Protocol bindings (spec 340 §11 / W5) — foreign keys into other protocols' namespaces, NEVER our
|
|
29
|
+
// canonical ids. Resolution returns a typed ambiguity rather than a first match: cross-wiring two
|
|
30
|
+
// interactions merges two participant sets, two commitment ledgers and two audit trails.
|
|
31
|
+
export { PROTOCOL, looksCanonical, bindProtocol, bindingKey, buildBindingIndex, resolveInteractionByBinding, topicInteractionId, channelIdFromTopicInteraction, } from './protocol-binding.js';
|
|
32
|
+
// TRANSITIONAL (spec 340 W5) — the MessageKind/CaseState retirement path. This module exists to be
|
|
33
|
+
// deleted; both enums are still live, and the total compiler-checked mapping is what makes the later
|
|
34
|
+
// removal mechanical instead of a judgement call per call site.
|
|
35
|
+
export { PROFILE_FOR_MESSAGE_KIND, MACHINE_FOR_CASE_STATE, machinesSpannedByCaseState } from './enum-retirement.js';
|
|
36
|
+
// The profile mechanism (spec 340 W4) — what replaces the frozen MessageKind/CaseState enums. A new
|
|
37
|
+
// interaction type is DATA, not a schema change. A profile permits nothing.
|
|
38
|
+
export { checkExchangeAgainstProfile, profileFor, PROFILE_LIBRARY, DIRECT_PROFILE, NEGOTIATION_PROFILE, CONSULTATION_PROFILE, ENGAGEMENT_PROFILE, TOPIC_PROFILE, ENGAGEMENT_RESPONSE_KIND_AXES, } from './interaction-profile.js';
|
|
39
|
+
// The four state machines spec 340 §5 named and the fabric did not have (W3). Six, never collapsed:
|
|
40
|
+
// delivery · inbox · interaction · decision · commitment · execution. None of them is authority.
|
|
41
|
+
export { applyInboxTransition, applyInteractionTransition, applyDecisionTransition, applyCommitmentTransition, mayDischargeOnExecution, TERMINAL_INTERACTION_STATES, TERMINAL_DECISION_STATES, TERMINAL_COMMITMENT_STATES, } from './interaction-machines.js';
|
|
42
|
+
// The durable governed situation (spec 340 W2; ADR-0058). The aggregate an Exchange occurs IN — an
|
|
43
|
+
// Exchange without one is a message, which is a legitimate state and why the pins are optional.
|
|
44
|
+
export { isProfileVersion, isFloatingVersion, checkReproducible, assertReproducible, hashContextSnapshot, buildContextSnapshot, verifyContextSnapshot, participantsAt, detectProfileDowngrades, } from './interaction-record.js';
|
|
45
|
+
// The vault-backed conversation as an Interaction (spec 340 W12) — the projection `demo-a2a`'s live
|
|
46
|
+
// board path uses. W11 wired the DO-SQL channel store, which no app runs; this reaches the one that does.
|
|
47
|
+
export { conversationInteractionId, conversationIdFromInteraction, participationModeOfConversation, profileVersionOfConversation, participationsOfConversation, conversationPins, interactionViewOfConversation, participationModeOfChannel, interactionViewOfChannel, } from './messaging/conversation-interaction.js';
|
|
18
48
|
// Inbox projection (spec 316 §b) — the vault-resident inbox row projected from the message-event slice.
|
|
19
49
|
export { projectInboxItem, applyMessageEvent, applyInboxRules, createInMemoryInboxProjector, } from './inbox-projection.js';
|
|
20
50
|
// Gateway surface commitment (spec 316 §4.1 / W4 — decentralized discovery; the atl:gatewayRoot preimage).
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,yEAAyE;AACzE,EAAE;AACF,sGAAsG;AACtG,oGAAoG;AACpG,8EAA8E;AAC9E,EAAE;AACF,qGAAqG;AACrG,oFAAoF;AAEpF,OAAO,EACL,iBAAiB,EACjB,qBAAqB,EACrB,mBAAmB,EACnB,oBAAoB,EACpB,kBAAkB,EAClB,kBAAkB,EAClB,WAAW,EACX,WAAW,GACZ,MAAM,qBAAqB,CAAC;AAG7B,6GAA6G;AAC7G,OAAO,EAAE,oBAAoB,EAAE,kBAAkB,EAAE,OAAO,EAAE,MAAM,sBAAsB,CAAC;AAUzF,0GAA0G;AAC1G,OAAO,EAAE,mBAAmB,EAAE,MAAM,wBAAwB,CAAC;
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,yEAAyE;AACzE,EAAE;AACF,sGAAsG;AACtG,oGAAoG;AACpG,8EAA8E;AAC9E,EAAE;AACF,qGAAqG;AACrG,oFAAoF;AAEpF,OAAO,EACL,iBAAiB,EACjB,qBAAqB,EACrB,mBAAmB,EACnB,oBAAoB,EACpB,kBAAkB,EAClB,kBAAkB,EAClB,WAAW,EACX,WAAW,GACZ,MAAM,qBAAqB,CAAC;AAG7B,8FAA8F;AAC9F,oGAAoG;AACpG,OAAO,EAAE,YAAY,EAAE,MAAM,sBAAsB,CAAC;AAGpD,6GAA6G;AAC7G,OAAO,EAAE,oBAAoB,EAAE,kBAAkB,EAAE,OAAO,EAAE,MAAM,sBAAsB,CAAC;AAUzF,0GAA0G;AAC1G,OAAO,EAAE,mBAAmB,EAAE,cAAc,EAAE,iBAAiB,EAAE,MAAM,wBAAwB,CAAC;AAQhG,0GAA0G;AAC1G,OAAO,EACL,mBAAmB,EACnB,mBAAmB,EACnB,oBAAoB,EACpB,uBAAuB,EACvB,sCAAsC,GACvC,MAAM,mBAAmB,CAAC;AAW3B,6FAA6F;AAC7F,sGAAsG;AACtG,0CAA0C;AA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