@agentshouse/mdruntime 0.1.0-cbbae1fff01c6 → 0.1.0-cc00e9289ddf4
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/README.md +17 -15
- package/dist/acceptance.d.ts.map +1 -1
- package/dist/acceptance.js +14 -23
- package/dist/act-lanes.d.ts +30 -0
- package/dist/act-lanes.d.ts.map +1 -0
- package/dist/act-lanes.js +225 -0
- package/dist/actions.d.ts +8 -2
- package/dist/actions.d.ts.map +1 -1
- package/dist/actions.js +114 -63
- package/dist/adapter.d.ts +30 -12
- package/dist/adapter.d.ts.map +1 -1
- package/dist/attached-model.d.ts +0 -1
- package/dist/attached-model.d.ts.map +1 -1
- package/dist/attached-model.js +0 -5
- package/dist/chat-types.d.ts +0 -2
- package/dist/chat-types.d.ts.map +1 -1
- package/dist/chat-types.js +0 -2
- package/dist/client.d.ts +8 -18
- package/dist/client.d.ts.map +1 -1
- package/dist/client.js +27 -15
- package/dist/compile.d.ts +2 -0
- package/dist/compile.d.ts.map +1 -1
- package/dist/compile.js +17 -4
- package/dist/connection.d.ts.map +1 -1
- package/dist/connection.js +15 -13
- package/dist/conversation-live.d.ts +23 -8
- package/dist/conversation-live.d.ts.map +1 -1
- package/dist/conversation-live.js +21 -9
- package/dist/conversation-row.d.ts +2 -0
- package/dist/conversation-row.d.ts.map +1 -1
- package/dist/conversation-row.js +2 -0
- package/dist/conversation.d.ts +27 -5
- package/dist/conversation.d.ts.map +1 -1
- package/dist/conversation.js +279 -168
- package/dist/discovery.d.ts.map +1 -1
- package/dist/discovery.js +8 -6
- package/dist/durability.d.ts +4 -0
- package/dist/durability.d.ts.map +1 -1
- package/dist/durability.js +4 -0
- package/dist/entry.js +1 -1
- package/dist/expectation.d.ts +25 -14
- package/dist/expectation.d.ts.map +1 -1
- package/dist/expectation.js +51 -20
- package/dist/failure.d.ts +2 -0
- package/dist/failure.d.ts.map +1 -1
- package/dist/failure.js +3 -0
- package/dist/figures.d.ts.map +1 -1
- package/dist/figures.js +4 -2
- package/dist/file.d.ts.map +1 -1
- package/dist/file.js +2 -1
- package/dist/host.d.ts +1 -0
- package/dist/host.d.ts.map +1 -1
- package/dist/host.js +39 -11
- package/dist/index.d.ts +11 -8
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +9 -6
- package/dist/install.d.ts +10 -4
- package/dist/install.d.ts.map +1 -1
- package/dist/install.js +45 -46
- package/dist/lifecycle.d.ts.map +1 -1
- package/dist/lifecycle.js +22 -16
- package/dist/listing.d.ts +7 -3
- package/dist/listing.d.ts.map +1 -1
- package/dist/listing.js +26 -13
- package/dist/live.d.ts +5 -3
- package/dist/live.d.ts.map +1 -1
- package/dist/live.js +71 -30
- package/dist/locks.d.ts.map +1 -1
- package/dist/locks.js +2 -3
- package/dist/lost.d.ts.map +1 -1
- package/dist/lost.js +2 -3
- package/dist/media.d.ts.map +1 -1
- package/dist/media.js +7 -10
- package/dist/memory.d.ts +3 -1
- package/dist/memory.d.ts.map +1 -1
- package/dist/memory.js +50 -22
- package/dist/messages.d.ts +12 -3
- package/dist/messages.d.ts.map +1 -1
- package/dist/messages.js +24 -10
- package/dist/models.d.ts.map +1 -1
- package/dist/models.js +5 -8
- package/dist/observation.d.ts +27 -12
- package/dist/observation.d.ts.map +1 -1
- package/dist/observation.js +173 -69
- package/dist/opening.d.ts.map +1 -1
- package/dist/opening.js +3 -9
- package/dist/outcome.d.ts +7 -0
- package/dist/outcome.d.ts.map +1 -1
- package/dist/outcome.js +23 -2
- package/dist/overlay.d.ts +3 -0
- package/dist/overlay.d.ts.map +1 -1
- package/dist/overlay.js +8 -4
- package/dist/page-metadata.d.ts +8 -0
- package/dist/page-metadata.d.ts.map +1 -0
- package/dist/page-metadata.js +19 -0
- package/dist/parts.d.ts +2 -9
- package/dist/parts.d.ts.map +1 -1
- package/dist/parts.js +6 -14
- package/dist/preparation.d.ts +27 -6
- package/dist/preparation.d.ts.map +1 -1
- package/dist/preparation.js +137 -56
- package/dist/presence.d.ts +7 -1
- package/dist/presence.d.ts.map +1 -1
- package/dist/presence.js +22 -9
- package/dist/queries.d.ts +2 -2
- package/dist/queries.d.ts.map +1 -1
- package/dist/queries.js +62 -24
- package/dist/questions.d.ts +0 -5
- package/dist/questions.d.ts.map +1 -1
- package/dist/questions.js +0 -7
- package/dist/queue.d.ts +2 -2
- package/dist/queue.d.ts.map +1 -1
- package/dist/queue.js +25 -30
- package/dist/reach.d.ts +2 -3
- package/dist/reach.d.ts.map +1 -1
- package/dist/reach.js +75 -21
- package/dist/react.d.ts +7 -5
- package/dist/react.d.ts.map +1 -1
- package/dist/react.js +28 -5
- package/dist/readiness.d.ts +9 -3
- package/dist/readiness.d.ts.map +1 -1
- package/dist/readiness.js +3 -5
- package/dist/reads.d.ts +3 -1
- package/dist/reads.d.ts.map +1 -1
- package/dist/reads.js +5 -1
- package/dist/recovery.d.ts +3 -1
- package/dist/recovery.d.ts.map +1 -1
- package/dist/recovery.js +29 -7
- package/dist/refusal.d.ts.map +1 -1
- package/dist/refusal.js +1 -3
- package/dist/retried.d.ts +30 -0
- package/dist/retried.d.ts.map +1 -0
- package/dist/retried.js +72 -0
- package/dist/room-draft.d.ts +2 -2
- package/dist/room-draft.d.ts.map +1 -1
- package/dist/room-draft.js +26 -21
- package/dist/rows.d.ts +2 -0
- package/dist/rows.d.ts.map +1 -1
- package/dist/rows.js +3 -0
- package/dist/runtime.d.ts +2 -2
- package/dist/runtime.d.ts.map +1 -1
- package/dist/save.d.ts +1 -0
- package/dist/save.d.ts.map +1 -1
- package/dist/save.js +105 -55
- package/dist/saves.d.ts.map +1 -1
- package/dist/saves.js +3 -6
- package/dist/seed.d.ts.map +1 -1
- package/dist/seed.js +2 -2
- package/dist/shown.d.ts +3 -2
- package/dist/shown.d.ts.map +1 -1
- package/dist/shown.js +58 -39
- package/dist/socket/lanes.d.ts +12 -4
- package/dist/socket/lanes.d.ts.map +1 -1
- package/dist/socket/lanes.js +34 -8
- package/dist/socket.d.ts +3 -3
- package/dist/socket.d.ts.map +1 -1
- package/dist/socket.js +3 -9
- package/dist/source.d.ts +0 -7
- package/dist/source.d.ts.map +1 -1
- package/dist/store/installs.d.ts +2 -2
- package/dist/store/installs.d.ts.map +1 -1
- package/dist/store/installs.js +10 -4
- package/dist/store/readiness.d.ts +5 -4
- package/dist/store/readiness.d.ts.map +1 -1
- package/dist/store/readiness.js +28 -12
- package/dist/store/records.d.ts +11 -4
- package/dist/store/records.d.ts.map +1 -1
- package/dist/store/records.js +56 -20
- package/dist/store/rooms-shown.d.ts +8 -0
- package/dist/store/rooms-shown.d.ts.map +1 -0
- package/dist/store/rooms-shown.js +13 -0
- package/dist/store.d.ts +9 -6
- package/dist/store.d.ts.map +1 -1
- package/dist/store.js +11 -2
- package/dist/stored.d.ts +24 -13
- package/dist/stored.d.ts.map +1 -1
- package/dist/stored.js +73 -17
- package/dist/surface.d.ts +4 -3
- package/dist/surface.d.ts.map +1 -1
- package/dist/surface.js +12 -13
- package/dist/sync.d.ts.map +1 -1
- package/dist/sync.js +31 -17
- package/dist/tables.d.ts +14 -7
- package/dist/tables.d.ts.map +1 -1
- package/dist/tables.js +36 -15
- package/dist/tallies.d.ts.map +1 -1
- package/dist/tallies.js +1 -2
- package/dist/wire.d.ts +40 -3
- package/dist/wire.d.ts.map +1 -1
- package/dist/wire.js +11 -1
- package/package.json +3 -3
- package/dist/attempt.d.ts +0 -16
- package/dist/attempt.d.ts.map +0 -1
- package/dist/attempt.js +0 -70
- package/dist/job.d.ts +0 -5
- package/dist/job.d.ts.map +0 -1
- package/dist/job.js +0 -7
- package/dist/log.d.ts +0 -6
- package/dist/log.d.ts.map +0 -1
- package/dist/log.js +0 -14
package/dist/discovery.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"discovery.d.ts","sourceRoot":"","sources":["../src/discovery.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAEV,SAAS,EACT,cAAc,EACd,MAAM,EAEP,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,KAAK,EAAE,YAAY,EAAE,QAAQ,EAAE,MAAM,GAAG,IAAI,iBAI1F;AAED,wBAAsB,aAAa,CACjC,OAAO,EAAE,OAAO,EAChB,KAAK,EAAE,YAAY,EACnB,QAAQ,EAAE,aAAa,EACvB,IAAI,EAAE,IAAI,EACV,KAAK,EAAE,SAAS,GAAG,IAAI,GACtB,OAAO,CAAC,SAAS,cAAc,EAAE,GAAG,IAAI,CAAC,CA+D3C"}
|
package/dist/discovery.js
CHANGED
|
@@ -73,10 +73,11 @@ async function asked({ socket }, authorized) {
|
|
|
73
73
|
try {
|
|
74
74
|
return (await socket.discover(authorized)) ?? { kind: 'transport-uncertainty' };
|
|
75
75
|
}
|
|
76
|
-
catch {
|
|
77
|
-
return { kind: 'transport-uncertainty' };
|
|
76
|
+
catch (failure) {
|
|
77
|
+
return { kind: 'transport-uncertainty', failure };
|
|
78
78
|
}
|
|
79
79
|
}
|
|
80
|
+
const DISCOVERY = 'discovery';
|
|
80
81
|
export async function signIn(runtime, local, signedIn) {
|
|
81
82
|
if (JSON.stringify(signedIn) === JSON.stringify((await local.facts()).member))
|
|
82
83
|
return;
|
|
@@ -84,7 +85,7 @@ export async function signIn(runtime, local, signedIn) {
|
|
|
84
85
|
emitMember(runtime, signedIn);
|
|
85
86
|
}
|
|
86
87
|
export async function discoverRooms(runtime, local, progress, live, found) {
|
|
87
|
-
const { socket
|
|
88
|
+
const { socket } = runtime;
|
|
88
89
|
const { session } = socket;
|
|
89
90
|
const { closed, authorization } = session.now();
|
|
90
91
|
if (closed || authorization === undefined) {
|
|
@@ -102,7 +103,10 @@ export async function discoverRooms(runtime, local, progress, live, found) {
|
|
|
102
103
|
socket.notifyReady();
|
|
103
104
|
return null;
|
|
104
105
|
}
|
|
105
|
-
|
|
106
|
+
if (result.kind === 'transport-uncertainty')
|
|
107
|
+
runtime.retries.uncertain('connection', DISCOVERY, result);
|
|
108
|
+
if (result.kind === 'discovery')
|
|
109
|
+
runtime.retries.succeeded('connection', DISCOVERY);
|
|
106
110
|
if (result.kind === 'transport-uncertainty') {
|
|
107
111
|
await cachedModels(runtime, local);
|
|
108
112
|
progress.reachable = false;
|
|
@@ -111,7 +115,6 @@ export async function discoverRooms(runtime, local, progress, live, found) {
|
|
|
111
115
|
return null;
|
|
112
116
|
}
|
|
113
117
|
if (result.kind === 'contract-unavailable') {
|
|
114
|
-
journal.record(`connection contract unavailable ${result.code}`);
|
|
115
118
|
await refuse(runtime, 'missing-required-guarantee', {
|
|
116
119
|
code: result.code,
|
|
117
120
|
fields: result.fields,
|
|
@@ -127,7 +130,6 @@ export async function discoverRooms(runtime, local, progress, live, found) {
|
|
|
127
130
|
}
|
|
128
131
|
const invalid = malformed(result.rooms);
|
|
129
132
|
if (invalid !== null) {
|
|
130
|
-
journal.record(invalid);
|
|
131
133
|
await refuse(runtime, 'missing-required-guarantee');
|
|
132
134
|
socket.notifyReady();
|
|
133
135
|
return null;
|
package/dist/durability.d.ts
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import type { Persistence } from './readiness.js';
|
|
2
|
+
import type { RetriedFailure, Step } from './retried.js';
|
|
2
3
|
export type UnsentKind = 'pending-change' | 'call' | 'room-draft' | 'chat-draft';
|
|
3
4
|
export type UnsentWork = {
|
|
4
5
|
readonly kind: UnsentKind;
|
|
@@ -20,8 +21,11 @@ export type RuntimeShell = {
|
|
|
20
21
|
cleanUp?(): Promise<number>;
|
|
21
22
|
measure?(measured: (app: string, code: AppCode | null) => void): Promise<HeldCode>;
|
|
22
23
|
reset(): Promise<void>;
|
|
24
|
+
retried?(failure: RetriedFailure): void;
|
|
25
|
+
succeeded?(step: Step): void;
|
|
23
26
|
};
|
|
24
27
|
export declare function refusedForSpace(error: unknown): boolean;
|
|
25
28
|
export declare function detectStorageLoss(stored: string | null, reported: string | null): string | null;
|
|
29
|
+
export declare function lossStated(persistence: Persistence, loss: string | null): string | null;
|
|
26
30
|
export declare function nextGeneration(stored: string | null, reported: string | null): string;
|
|
27
31
|
//# sourceMappingURL=durability.d.ts.map
|
package/dist/durability.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"durability.d.ts","sourceRoot":"","sources":["../src/durability.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;
|
|
1
|
+
{"version":3,"file":"durability.d.ts","sourceRoot":"","sources":["../src/durability.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAClD,OAAO,KAAK,EAAE,cAAc,EAAE,IAAI,EAAE,MAAM,cAAc,CAAC;AAMzD,MAAM,MAAM,UAAU,GAAG,gBAAgB,GAAG,MAAM,GAAG,YAAY,GAAG,YAAY,CAAC;AAEjF,MAAM,MAAM,UAAU,GAAG;IAAE,QAAQ,CAAC,IAAI,EAAE,UAAU,CAAC;IAAC,QAAQ,CAAC,KAAK,EAAE,MAAM,CAAA;CAAE,CAAC;AAE/E,MAAM,MAAM,OAAO,GAAG;IAAE,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;IAAC,QAAQ,CAAC,KAAK,EAAE,MAAM,CAAA;CAAE,CAAC;AAE3E,MAAM,MAAM,QAAQ,GAAG;IAAE,QAAQ,CAAC,KAAK,EAAE,MAAM,GAAG,IAAI,CAAC;IAAC,QAAQ,CAAC,IAAI,EAAE,SAAS,MAAM,EAAE,CAAA;CAAE,CAAC;AAE3F,MAAM,MAAM,YAAY,GAAG;IACzB,WAAW,EAAE,WAAW,CAAC;IACzB,UAAU,EAAE,MAAM,GAAG,IAAI,CAAC;IAC1B,cAAc,CAAC,KAAK,EAAE,MAAM,GAAG,IAAI,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IACpD,cAAc,IAAI,IAAI,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IACvC,OAAO,CAAC,IAAI,OAAO,CAAC,MAAM,CAAC,CAAC;IAC5B,OAAO,CAAC,CAAC,QAAQ,EAAE,CAAC,GAAG,EAAE,MAAM,EAAE,IAAI,EAAE,OAAO,GAAG,IAAI,KAAK,IAAI,GAAG,OAAO,CAAC,QAAQ,CAAC,CAAC;IACnF,KAAK,IAAI,OAAO,CAAC,IAAI,CAAC,CAAC;IACvB,OAAO,CAAC,CAAC,OAAO,EAAE,cAAc,GAAG,IAAI,CAAC;IACxC,SAAS,CAAC,CAAC,IAAI,EAAE,IAAI,GAAG,IAAI,CAAC;CAC9B,CAAC;AAEF,wBAAgB,eAAe,CAAC,KAAK,EAAE,OAAO,GAAG,OAAO,CAMvD;AAED,wBAAgB,iBAAiB,CAAC,MAAM,EAAE,MAAM,GAAG,IAAI,EAAE,QAAQ,EAAE,MAAM,GAAG,IAAI,GAAG,MAAM,GAAG,IAAI,CAG/F;AAED,wBAAgB,UAAU,CAAC,WAAW,EAAE,WAAW,EAAE,IAAI,EAAE,MAAM,GAAG,IAAI,GAAG,MAAM,GAAG,IAAI,CAEvF;AAED,wBAAgB,cAAc,CAAC,MAAM,EAAE,MAAM,GAAG,IAAI,EAAE,QAAQ,EAAE,MAAM,GAAG,IAAI,GAAG,MAAM,CAGrF"}
|
package/dist/durability.js
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
const STORAGE_LOSS_CODE = 'storage-loss';
|
|
2
|
+
const VISIT_LOSS_CODE = 'visit';
|
|
2
3
|
export function refusedForSpace(error) {
|
|
3
4
|
return (typeof error === 'object' &&
|
|
4
5
|
error !== null &&
|
|
@@ -9,6 +10,9 @@ export function detectStorageLoss(stored, reported) {
|
|
|
9
10
|
return null;
|
|
10
11
|
return STORAGE_LOSS_CODE;
|
|
11
12
|
}
|
|
13
|
+
export function lossStated(persistence, loss) {
|
|
14
|
+
return persistence === 'memory' ? VISIT_LOSS_CODE : loss;
|
|
15
|
+
}
|
|
12
16
|
export function nextGeneration(stored, reported) {
|
|
13
17
|
if (stored !== null && (reported === null || reported === stored))
|
|
14
18
|
return stored;
|
package/dist/entry.js
CHANGED
|
@@ -145,7 +145,7 @@ export function entryScope(rooms, roomTypes, connection) {
|
|
|
145
145
|
change: null,
|
|
146
146
|
written: null,
|
|
147
147
|
})));
|
|
148
|
-
return { locator: room.locator, key };
|
|
148
|
+
return { locator: room.locator, key, composition };
|
|
149
149
|
});
|
|
150
150
|
const planned = { listed: true, rooms: held };
|
|
151
151
|
return {
|
package/dist/expectation.d.ts
CHANGED
|
@@ -1,23 +1,34 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
1
|
+
declare const heldType: unique symbol;
|
|
2
|
+
export type Descriptor<A, T> = {
|
|
3
|
+
place(asked: A): string;
|
|
4
|
+
readonly [heldType]?: T;
|
|
5
|
+
};
|
|
6
|
+
export type Expectation = {
|
|
5
7
|
readonly key: string;
|
|
6
|
-
|
|
8
|
+
readonly descriptor: object;
|
|
9
|
+
readonly places: ReadonlySet<string>;
|
|
10
|
+
draw(held: unknown): unknown;
|
|
11
|
+
shown(held: unknown): boolean;
|
|
12
|
+
};
|
|
13
|
+
export type Expected = Expectation | readonly Expectation[] | null;
|
|
14
|
+
export type Expecting = {
|
|
7
15
|
subscribe(listener: () => void): () => void;
|
|
8
16
|
version(): number;
|
|
9
17
|
begin(): number;
|
|
10
|
-
expect(act: number, expected:
|
|
18
|
+
expect(act: number, expected: Expected): void;
|
|
11
19
|
drop(act: number): void;
|
|
12
|
-
reads(reader: string,
|
|
13
|
-
heard(reader: string,
|
|
20
|
+
reads<A, T>(reader: string, descriptor: Descriptor<A, T>, places: readonly A[]): void;
|
|
21
|
+
heard<A, T>(reader: string, descriptor: Descriptor<A, T>, held: ReadonlyMap<A, T>): void;
|
|
14
22
|
left(reader: string): void;
|
|
15
|
-
|
|
23
|
+
draw<A, T>(descriptor: Descriptor<A, T>, place: A, held: T): T;
|
|
16
24
|
};
|
|
17
|
-
export declare function
|
|
18
|
-
readonly key: string;
|
|
19
|
-
}>(expected: ExpectedOf<E>): readonly E[];
|
|
20
|
-
export declare function expecting<E extends {
|
|
25
|
+
export declare function expectation<A, T>(descriptor: Descriptor<A, T>, made: {
|
|
21
26
|
readonly key: string;
|
|
22
|
-
|
|
27
|
+
readonly at: readonly A[];
|
|
28
|
+
draw(held: T): T;
|
|
29
|
+
shown(held: T): boolean;
|
|
30
|
+
}): Expectation;
|
|
31
|
+
export declare function expectedList(expected: Expected): readonly Expectation[];
|
|
32
|
+
export declare function expecting(): Expecting;
|
|
33
|
+
export {};
|
|
23
34
|
//# sourceMappingURL=expectation.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"expectation.d.ts","sourceRoot":"","sources":["../src/expectation.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,UAAU,CAAC,CAAC,
|
|
1
|
+
{"version":3,"file":"expectation.d.ts","sourceRoot":"","sources":["../src/expectation.ts"],"names":[],"mappings":"AAAA,OAAO,CAAC,MAAM,QAAQ,EAAE,OAAO,MAAM,CAAC;AAEtC,MAAM,MAAM,UAAU,CAAC,CAAC,EAAE,CAAC,IAAI;IAC7B,KAAK,CAAC,KAAK,EAAE,CAAC,GAAG,MAAM,CAAC;IACxB,QAAQ,CAAC,CAAC,QAAQ,CAAC,CAAC,EAAE,CAAC,CAAC;CACzB,CAAC;AAEF,MAAM,MAAM,WAAW,GAAG;IACxB,QAAQ,CAAC,GAAG,EAAE,MAAM,CAAC;IACrB,QAAQ,CAAC,UAAU,EAAE,MAAM,CAAC;IAC5B,QAAQ,CAAC,MAAM,EAAE,WAAW,CAAC,MAAM,CAAC,CAAC;IACrC,IAAI,CAAC,IAAI,EAAE,OAAO,GAAG,OAAO,CAAC;IAC7B,KAAK,CAAC,IAAI,EAAE,OAAO,GAAG,OAAO,CAAC;CAC/B,CAAC;AAEF,MAAM,MAAM,QAAQ,GAAG,WAAW,GAAG,SAAS,WAAW,EAAE,GAAG,IAAI,CAAC;AAEnE,MAAM,MAAM,SAAS,GAAG;IACtB,SAAS,CAAC,QAAQ,EAAE,MAAM,IA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A+BD,wBAAgB,SAAS,IAAI,SAAS,CAqFrC"}
|
package/dist/expectation.js
CHANGED
|
@@ -1,23 +1,40 @@
|
|
|
1
|
-
const
|
|
1
|
+
const NOWHERE = new Set();
|
|
2
|
+
const NOTHING = new Map();
|
|
3
|
+
export function expectation(descriptor, made) {
|
|
4
|
+
return {
|
|
5
|
+
key: made.key,
|
|
6
|
+
descriptor,
|
|
7
|
+
places: new Set(made.at.map((one) => descriptor.place(one))),
|
|
8
|
+
draw: (value) => made.draw(value),
|
|
9
|
+
shown: (value) => made.shown(value),
|
|
10
|
+
};
|
|
11
|
+
}
|
|
2
12
|
export function expectedList(expected) {
|
|
3
13
|
if (expected === null)
|
|
4
14
|
return [];
|
|
5
15
|
return 'key' in expected ? [expected] : expected;
|
|
6
16
|
}
|
|
17
|
+
function asks(reader, one) {
|
|
18
|
+
return (reader.descriptor === one.descriptor && [...one.places].some((at) => reader.places.has(at)));
|
|
19
|
+
}
|
|
20
|
+
function shows(reader, one) {
|
|
21
|
+
return (reader.descriptor === one.descriptor &&
|
|
22
|
+
[...reader.held].some(([at, value]) => one.places.has(at) && one.shown(value)));
|
|
23
|
+
}
|
|
7
24
|
function superseded(entries, at) {
|
|
8
|
-
const key = entries[at]?.
|
|
9
|
-
return entries.slice(at + 1).some((later) => later.
|
|
25
|
+
const key = entries[at]?.one.key;
|
|
26
|
+
return entries.slice(at + 1).some((later) => later.one.key === key);
|
|
10
27
|
}
|
|
11
28
|
function unended(entries, ends) {
|
|
12
29
|
const ended = new Set();
|
|
13
30
|
const kept = [];
|
|
14
|
-
for (const
|
|
15
|
-
if (ended.has(one.
|
|
31
|
+
for (const entry of [...entries].reverse()) {
|
|
32
|
+
if (ended.has(entry.one.key))
|
|
16
33
|
continue;
|
|
17
|
-
if (ends(
|
|
18
|
-
ended.add(one.
|
|
34
|
+
if (ends(entry))
|
|
35
|
+
ended.add(entry.one.key);
|
|
19
36
|
else
|
|
20
|
-
kept.unshift(
|
|
37
|
+
kept.unshift(entry);
|
|
21
38
|
}
|
|
22
39
|
return kept;
|
|
23
40
|
}
|
|
@@ -38,14 +55,13 @@ export function expecting() {
|
|
|
38
55
|
const settle = (next) => {
|
|
39
56
|
for (const entry of next)
|
|
40
57
|
for (const [id, reader] of readers)
|
|
41
|
-
if (
|
|
58
|
+
if (asks(reader, entry.one) && shows(reader, entry.one))
|
|
42
59
|
entry.seen.add(id);
|
|
43
60
|
set(unended(next, (entry) => {
|
|
44
|
-
const asking = [...readers].filter(([, reader]) =>
|
|
61
|
+
const asking = [...readers].filter(([, reader]) => asks(reader, entry.one));
|
|
45
62
|
const seen = asking.filter(([id]) => entry.seen.has(id));
|
|
46
63
|
return (seen.length > 0 &&
|
|
47
|
-
(seen.length === asking.length ||
|
|
48
|
-
seen.some(([, reader]) => !reader.shown(entry.expectation))));
|
|
64
|
+
(seen.length === asking.length || seen.some(([, reader]) => !shows(reader, entry.one))));
|
|
49
65
|
}));
|
|
50
66
|
};
|
|
51
67
|
return {
|
|
@@ -66,19 +82,27 @@ export function expecting() {
|
|
|
66
82
|
return;
|
|
67
83
|
const keys = new Set(fresh.map((one) => one.key));
|
|
68
84
|
settle([
|
|
69
|
-
...entries.filter((
|
|
70
|
-
...fresh.map((
|
|
85
|
+
...entries.filter((entry) => entry.act !== act || !keys.has(entry.one.key)),
|
|
86
|
+
...fresh.map((one) => ({ act, one, seen: new Set() })),
|
|
71
87
|
]);
|
|
72
88
|
},
|
|
73
89
|
drop(act) {
|
|
74
|
-
set(entries.filter((
|
|
90
|
+
set(entries.filter((entry) => entry.act !== act));
|
|
75
91
|
},
|
|
76
|
-
reads(reader,
|
|
77
|
-
readers.set(reader, {
|
|
92
|
+
reads(reader, descriptor, places) {
|
|
93
|
+
readers.set(reader, {
|
|
94
|
+
descriptor,
|
|
95
|
+
places: new Set(places.map((one) => descriptor.place(one))),
|
|
96
|
+
held: readers.get(reader)?.held ?? NOTHING,
|
|
97
|
+
});
|
|
78
98
|
settle(entries);
|
|
79
99
|
},
|
|
80
|
-
heard(reader,
|
|
81
|
-
readers.set(reader, {
|
|
100
|
+
heard(reader, descriptor, held) {
|
|
101
|
+
readers.set(reader, {
|
|
102
|
+
descriptor,
|
|
103
|
+
places: readers.get(reader)?.places ?? NOWHERE,
|
|
104
|
+
held: new Map([...held].map(([place, value]) => [descriptor.place(place), value])),
|
|
105
|
+
});
|
|
82
106
|
settle(entries);
|
|
83
107
|
},
|
|
84
108
|
left(reader) {
|
|
@@ -87,6 +111,13 @@ export function expecting() {
|
|
|
87
111
|
entry.seen.delete(reader);
|
|
88
112
|
settle(entries);
|
|
89
113
|
},
|
|
90
|
-
|
|
114
|
+
draw(descriptor, place, held) {
|
|
115
|
+
const at = descriptor.place(place);
|
|
116
|
+
return entries.reduce((now, entry, index) => entry.one.descriptor === descriptor &&
|
|
117
|
+
entry.one.places.has(at) &&
|
|
118
|
+
!superseded(entries, index)
|
|
119
|
+
? entry.one.draw(now)
|
|
120
|
+
: now, held);
|
|
121
|
+
},
|
|
91
122
|
};
|
|
92
123
|
}
|
package/dist/failure.d.ts
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import type { ProviderRefusal } from './adapter.js';
|
|
1
2
|
export type RuntimeError = Error & {
|
|
2
3
|
readonly code: string;
|
|
3
4
|
readonly retryable: boolean;
|
|
@@ -8,6 +9,7 @@ export type Described = {
|
|
|
8
9
|
retryable: boolean;
|
|
9
10
|
};
|
|
10
11
|
export declare function runtimeError(code: string, message?: string, retryable?: boolean): RuntimeError;
|
|
12
|
+
export declare function refusalError(refusal: ProviderRefusal): RuntimeError;
|
|
11
13
|
export declare function failed(error: unknown): RuntimeError;
|
|
12
14
|
export declare function uncaught(error: unknown): void;
|
|
13
15
|
export declare function described(error: unknown): Described;
|
package/dist/failure.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"failure.d.ts","sourceRoot":"","sources":["../src/failure.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,YAAY,GAAG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AG,IAAI,CAE7C;AAED,wBAAgB,SAAS,CAAC,KAAK,EAAE,OAAO,GAAG,SAAS,CAGnD"}
|
package/dist/failure.js
CHANGED
|
@@ -8,6 +8,9 @@ function coded(error) {
|
|
|
8
8
|
'retryable' in error &&
|
|
9
9
|
typeof error.retryable === 'boolean');
|
|
10
10
|
}
|
|
11
|
+
export function refusalError(refusal) {
|
|
12
|
+
return runtimeError(refusal.code, refusal.code, refusal.retryable);
|
|
13
|
+
}
|
|
11
14
|
export function failed(error) {
|
|
12
15
|
if (coded(error))
|
|
13
16
|
return error;
|
package/dist/figures.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"figures.d.ts","sourceRoot":"","sources":["../src/figures.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AACjD,OAAO,KAAK,EAAE,UAAU,EAAE,aAAa,EAAE,MAAM,YAAY,CAAC;AAC5D,OAAO,KAAK,EAAE,OAAO,EAAE,IAAI,EAAE,MAAM,YAAY,CAAC;AAChD,OAAO,KAAK,EAAE,iBAAiB,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AACjE,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AAE7C,eAAO,MAAM,eAAe,UAAU,CAAC;AAEvC,eAAO,MAAM,WAAW;;;;iBAGZ,IAAI;;CACe,CAAC;AAGhC,eAAO,MAAM,cAAc,WAAa,CAAC;AAQzC,MAAM,MAAM,UAAU,GAAG;IACvB,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;IACzB,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;IACzB,QAAQ,CAAC,KAAK,EAAE,MAAM,CAAC;IACvB,QAAQ,CAAC,QAAQ,EAAE,MAAM,CAAC;CAC3B,CAAC;AAEF,MAAM,MAAM,WAAW,GAAG;IACxB,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IACtB,QAAQ,CAAC,G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,IAAI,OAAO,CAAC,YAAY,CAAC,CAAC;IAC/B,KAAK,CAAC,KAAK,EAAE,SAAS,SAAS,EAAE,EAAE,KAAK,EAAE,MAAM,GAAG,OAAO,CAAC,SAAS,SAAS,EAAE,CAAC,CAAC;IACjF,aAAa,CACX,aAAa,EAAE,SAAS,MAAM,EAAE,GAAG,IAAI,EACvC,KAAK,EAAE,MAAM,GACZ,OAAO,CAAC,SAAS,iBAAiB,EAAE,CAAC,CAAC;CAC1C,CAAC;AAEF,MAAM,MAAM,WAAW,GAAG;IACxB,KAAK,CAAC,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,IAAI,GAAG,MAAM,IAAI,CAAC;IAChD,OAAO,CAAC,GAAG,EAAE,SAAS,GAAG,IAAI,CAAC;IAC9B,OAAO,IAAI,IAAI,CAAC;IAChB,KAAK,IAAI,IAAI,CAAC;CACf,CAAC;AAgDF,wBAAgB,aAAa,CAAC,OAAO,EAAE,cAAc,GAAG,WAAW,CAwIlE"}
|
package/dist/figures.js
CHANGED
|
@@ -72,8 +72,9 @@ export function createFigures(sources) {
|
|
|
72
72
|
}
|
|
73
73
|
}
|
|
74
74
|
async function tallied(rooms, since) {
|
|
75
|
+
const covered = new Set(rooms.map(({ locator }) => locator));
|
|
75
76
|
for (const locator of held.rooms.keys()) {
|
|
76
|
-
if (!
|
|
77
|
+
if (!covered.has(locator))
|
|
77
78
|
held.rooms.delete(locator);
|
|
78
79
|
}
|
|
79
80
|
const asked = rooms.filter(({ locator, key }) => held.staleRooms.has(locator) || held.rooms.get(locator)?.key !== key);
|
|
@@ -90,8 +91,9 @@ export function createFigures(sources) {
|
|
|
90
91
|
]);
|
|
91
92
|
if (kept !== held)
|
|
92
93
|
return false;
|
|
94
|
+
const byKey = new Map(asked.map((room) => [room.key, room]));
|
|
93
95
|
for (const tally of roomTallies) {
|
|
94
|
-
const room =
|
|
96
|
+
const room = byKey.get(tally.key);
|
|
95
97
|
if (room !== undefined)
|
|
96
98
|
held.rooms.set(room.locator, tally);
|
|
97
99
|
}
|
package/dist/file.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"file.d.ts","sourceRoot":"","sources":["../src/file.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,cAAc,CAAC;
|
|
1
|
+
{"version":3,"file":"file.d.ts","sourceRoot":"","sources":["../src/file.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,cAAc,CAAC;AAIlD,wBAAsB,YAAY,CAAC,OAAO,EAAE,MAAM,EAAE,IAAI,EAAE,IAAI,GAAG,OAAO,CAAC,aAAa,CAAC,CAStF"}
|
package/dist/file.js
CHANGED
|
@@ -1,9 +1,10 @@
|
|
|
1
1
|
import { sha256 } from './digest.js';
|
|
2
|
+
import { declaredType } from './outcome.js';
|
|
2
3
|
export async function attachedFile(locator, file) {
|
|
3
4
|
return {
|
|
4
5
|
locator,
|
|
5
6
|
name: file.name,
|
|
6
|
-
mediaType: file
|
|
7
|
+
mediaType: declaredType(file),
|
|
7
8
|
byteLength: file.size,
|
|
8
9
|
sha256: await sha256(file),
|
|
9
10
|
blob: file,
|
package/dist/host.d.ts
CHANGED
|
@@ -39,6 +39,7 @@ export { entrySeedOf, type EntrySeed } from './seed.js';
|
|
|
39
39
|
export type { PortReach, ReachedDocument } from './reach.js';
|
|
40
40
|
export type { CodeAvailability, Persistence, Space } from './readiness.js';
|
|
41
41
|
export { createRecovery, retryDelay, type Attempt, type Attempted, type AttemptOptions, type Recovery, type RecoveryOptions, } from './recovery.js';
|
|
42
|
+
export { replaces } from './observation.js';
|
|
42
43
|
export { undeclared } from './outcome.js';
|
|
43
44
|
export { wireAnswer, wireRequest, type RuntimePort, type WireAnswer, type WireRequest, } from './wire.js';
|
|
44
45
|
//# sourceMappingURL=host.d.ts.map
|
package/dist/host.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"host.d.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M,kBAAkB,CAAC;AAC5C,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAC1C,OAAO,EACL,UAAU,EACV,WAAW,EACX,KAAK,WAAW,EAChB,KAAK,UAAU,EACf,KAAK,WAAW,GACjB,MAAM,WAAW,CAAC"}
|
package/dist/host.js
CHANGED
|
@@ -2,6 +2,7 @@ import { queryKey } from '@agentshouse/mdmodel';
|
|
|
2
2
|
import { composeRuntime } from './connection.js';
|
|
3
3
|
import { untilAnswered } from './recovery.js';
|
|
4
4
|
import { described } from './failure.js';
|
|
5
|
+
import { observed } from './observation.js';
|
|
5
6
|
import { answeredResult } from './outcome.js';
|
|
6
7
|
import { AUTHORIZATION_ENDED, WIRE, wireRequest, } from './wire.js';
|
|
7
8
|
const NARROWED = new Set(['within', 'whole']);
|
|
@@ -35,10 +36,10 @@ function answered(md, app, writtenBy, member, input) {
|
|
|
35
36
|
return md.binaryFile.part(input[0], input[1]);
|
|
36
37
|
case 'call':
|
|
37
38
|
return md.call(input[0], input[1]);
|
|
39
|
+
case 'answered':
|
|
40
|
+
return md.answered(input[0]);
|
|
38
41
|
case 'reached':
|
|
39
42
|
return md.reached(input[0], input[1], input[2]);
|
|
40
|
-
case 'log':
|
|
41
|
-
return md.log();
|
|
42
43
|
case 'cleanUp':
|
|
43
44
|
return md.cleanUp();
|
|
44
45
|
case 'unsent':
|
|
@@ -76,17 +77,35 @@ function answered(md, app, writtenBy, member, input) {
|
|
|
76
77
|
case 'conversation.send':
|
|
77
78
|
return md.conversation.send(input[0], input[1], input[2]);
|
|
78
79
|
case 'conversation.answer':
|
|
79
|
-
return md.conversation.answer(input[0], input[1]);
|
|
80
|
+
return md.conversation.answer(input[0], input[1], input[2]);
|
|
80
81
|
case 'conversation.interrupt':
|
|
81
|
-
return md.conversation.interrupt(input[0]);
|
|
82
|
+
return md.conversation.interrupt(input[0], input[1]);
|
|
82
83
|
case 'conversation.kill':
|
|
83
|
-
return md.conversation.kill(input[0]);
|
|
84
|
+
return md.conversation.kill(input[0], input[1]);
|
|
84
85
|
case 'conversation.delete':
|
|
85
|
-
return md.conversation.delete(input[0]);
|
|
86
|
+
return md.conversation.delete(input[0], input[1]);
|
|
87
|
+
case 'conversation.takeOut':
|
|
88
|
+
return md.conversation.takeOut(input[0], input[1], input[2]);
|
|
89
|
+
case 'conversation.decide':
|
|
90
|
+
return md.conversation.decide(input[0], input[1], input[2]);
|
|
91
|
+
case 'conversation.rename':
|
|
92
|
+
return md.conversation.rename(input[0], input[1], input[2]);
|
|
93
|
+
case 'conversation.option':
|
|
94
|
+
return md.conversation.option(input[0], input[1], input[2], input[3]);
|
|
95
|
+
case 'conversation.retry':
|
|
96
|
+
return md.conversation.retry(input[0], input[1], input[2]);
|
|
97
|
+
case 'conversation.pin':
|
|
98
|
+
return md.conversation.pin(input[0]);
|
|
99
|
+
case 'conversation.openTurn':
|
|
100
|
+
return md.conversation.openTurn(input[0], input[1]);
|
|
101
|
+
case 'conversation.dismissSuggestion':
|
|
102
|
+
return md.conversation.dismissSuggestion(input[0], input[1]);
|
|
86
103
|
case 'chatDraft.write':
|
|
87
104
|
return md.chatDraft.write(input[0], input[1], input[2]);
|
|
88
105
|
case 'chatDraft.prepend':
|
|
89
106
|
return md.chatDraft.prepend(input[0], input[1]);
|
|
107
|
+
case 'chatDraft.append':
|
|
108
|
+
return md.chatDraft.append(input[0], input[1]);
|
|
90
109
|
case 'chatDraft.discard':
|
|
91
110
|
return md.chatDraft.discard(input[0]);
|
|
92
111
|
}
|
|
@@ -102,7 +121,7 @@ function attempted(work) {
|
|
|
102
121
|
function answeredMessage(value) {
|
|
103
122
|
if (typeof value !== 'object' || value === null)
|
|
104
123
|
return false;
|
|
105
|
-
return
|
|
124
|
+
return 'result' in value ? answeredResult(value.result) : !('pending' in value);
|
|
106
125
|
}
|
|
107
126
|
export function serveMdRuntime(options) {
|
|
108
127
|
const deploymentFacts = structuredClone(options.deploymentFacts);
|
|
@@ -118,7 +137,7 @@ export function serveMdRuntime(options) {
|
|
|
118
137
|
const attachments = new Map();
|
|
119
138
|
let authorized = true;
|
|
120
139
|
let opening = null;
|
|
121
|
-
const opened = () => (opening ??= untilAnswered(() => md.loaded(), closing.signal));
|
|
140
|
+
const opened = () => (opening ??= untilAnswered(() => md.loaded(), closing.signal, () => true, options.recovery));
|
|
122
141
|
const watchFacts = (deliver) => {
|
|
123
142
|
deliver(structuredClone(deploymentFacts));
|
|
124
143
|
return () => { };
|
|
@@ -255,9 +274,17 @@ export function serveMdRuntime(options) {
|
|
|
255
274
|
readiness(deliver) {
|
|
256
275
|
if (!serving)
|
|
257
276
|
return () => { };
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
277
|
+
let shown = null;
|
|
278
|
+
const stop = view.watch('readiness', [], (message) => {
|
|
279
|
+
if (!serving)
|
|
280
|
+
return;
|
|
281
|
+
if (shown !== null) {
|
|
282
|
+
shown.receive(message);
|
|
283
|
+
return;
|
|
284
|
+
}
|
|
285
|
+
shown = observed(message, () => { }, 'readiness');
|
|
286
|
+
shown.observation.subscribe((value) => deliver(value));
|
|
287
|
+
deliver(shown.observation.current());
|
|
261
288
|
}, () => { });
|
|
262
289
|
const end = () => {
|
|
263
290
|
followed.delete(end);
|
|
@@ -297,5 +324,6 @@ export function serveMdRuntime(options) {
|
|
|
297
324
|
}
|
|
298
325
|
export { entrySeedOf } from './seed.js';
|
|
299
326
|
export { createRecovery, retryDelay, } from './recovery.js';
|
|
327
|
+
export { replaces } from './observation.js';
|
|
300
328
|
export { undeclared } from './outcome.js';
|
|
301
329
|
export { wireAnswer, wireRequest, } from './wire.js';
|
package/dist/index.d.ts
CHANGED
|
@@ -1,9 +1,10 @@
|
|
|
1
|
-
export type { AcceptedMessage, AcceptedRoom, ActionDeclaration, ActionRequest, ActionResult, Adapter, AdapterFailure, AttachRequest, AttachResult, AuthorityChange, Authorization, BinaryFile, BinaryLinkResult, BinaryRequest, BinaryResult, BootstrapPage, BootstrapRequest, BootstrapResult, Capability, ChangeAuthor, ContractUnavailable, ConversationAction, ConversationEvent, ConversationHistories, ConversationHistoryPage, ConversationHistoryRequest, ConversationMessage, ConversationStream, DiscoverResult, DiscoveredRoom, Discovery, SavedFacts, HistoryAuthor, HistoryRequest, HistoryResult, HistoryRetention, HistoryRevision, BootstrapPart, NotReady, HeldRoom, ListedAgent, ListedConversation, MdModelIdentity, Member, MutationRequest, MutationResult, PageToken, ProviderLimit, ProviderRefusal, RefreshPage, RefreshRequest, RefreshResult, Retention, RetryableRefusal, RevokedAuthorization, RoomChange, RoomModels, RoomNotReadable, RoomStream, RoomStreamEvent, RoomVersionAt, SearchAnswer, SearchAsk, ServiceMode, ServiceModeSignal, TransportUncertainty, TurnOperation, TypedPath, TypedSelection, } from './adapter.js';
|
|
1
|
+
export type { AcceptedMessage, AcceptedRoom, ActionDeclaration, ActionRequest, ActionResult, Adapter, AdapterFailure, AttachRequest, AttachResult, AuthorityChange, Authorization, BinaryFile, BinaryLinkResult, BinaryRequest, BinaryResult, BootstrapPage, BootstrapRequest, BootstrapResult, Capability, ChangeAuthor, ContractUnavailable, ConversationAction, ConversationEvent, ConversationHistories, ConversationHistoryPage, ConversationHistoryRequest, ConversationMessage, ConversationStream, DiscoverResult, DiscoveredRoom, Discovery, SavedFacts, HistoryAuthor, HistoryRequest, HistoryResult, HistoryRetention, HistoryRevision, BootstrapPart, NotReady, HeldRoom, AgentEnvironment, ListedAgent, ListedConversation, MdModelIdentity, Member, MutationRequest, MutationResult, PageToken, ProviderLimit, ProviderRefusal, RefreshPage, RefreshRequest, RefreshResult, Retention, RetryableRefusal, RevokedAuthorization, RoomChange, RoomModels, RoomNotReadable, RoomStream, RoomStreamEvent, RoomVersionAt, SearchAnswer, SearchAsk, ServiceMode, ServiceModeSignal, TransportUncertainty, TurnOperation, TypedPath, TypedSelection, } from './adapter.js';
|
|
2
2
|
export type { Change, ChangeBatch, Precondition, RoomMove, WrittenBy } from './change.js';
|
|
3
3
|
export { heldFacts } from './conversation-row.js';
|
|
4
4
|
export type { ConversationAsk, ConversationHeld, ConversationLast, ConversationStart, } from './conversation-row.js';
|
|
5
|
-
export type { ChatDraft, ChatDraftSurface, ConversationAgent, ConversationAnswer, ConversationEntry, ConversationOptions, ConversationRead, ConversationState, ConversationSurface, ConversationView, RunningTurn, } from './conversation.js';
|
|
5
|
+
export type { ChatDraft, ChatDraftSurface, ConversationAgent, ConversationAnswer, ConversationEntry, ConversationOptions, ConversationRead, ConversationState, ConversationSurface, ConversationView, RequestDecision, RunningTurn, } from './conversation.js';
|
|
6
6
|
export type { MdRuntimeOptions } from './connection.js';
|
|
7
|
+
export { PAGE_METADATA_WORDS } from './page-metadata.js';
|
|
7
8
|
export { writeRule, type WriteRefusal } from './declaration.js';
|
|
8
9
|
export type { HistoryQuery } from './actions.js';
|
|
9
10
|
export type { AppRoom, AppTypedSelection } from './listing.js';
|
|
@@ -15,27 +16,29 @@ export type { DayFigures, Figures, FiguresResult, RoomFigures } from './figures.
|
|
|
15
16
|
export type { HeldApp, Holdings, RoomDocuments } from './holdings.js';
|
|
16
17
|
export type { PresentationSurface, RoomDraftSurface } from './room-drafts.js';
|
|
17
18
|
export type { AttachAnswer, BinaryAnswer, BinaryLinkAnswer, CallResult, DownloadAnswer, Failure, HistoryAnswer, Offline, QueueEntry, Resolution, Submission, } from './outcome.js';
|
|
19
|
+
export { blobOf, declaredType } from './outcome.js';
|
|
18
20
|
export type { BinaryFileRecord } from './binary.js';
|
|
19
21
|
export type { RuntimeError } from './failure.js';
|
|
22
|
+
export { refusalError } from './failure.js';
|
|
20
23
|
export type { ChangedPart, FieldValue, ReturnReason, RoomDraft, RoomDraftCreation, RoomDraftParts, RoomDraftWrite, TextParts, } from './room-draft.js';
|
|
21
24
|
export type { SaveRefusal } from './save.js';
|
|
22
25
|
export type { SearchFound, SearchHit, SearchRequest, SearchResult } from './search.js';
|
|
23
|
-
export {
|
|
26
|
+
export { keptFile, keptLines } from './chat-types.js';
|
|
24
27
|
export { FIGURES_DAY_MS } from './figures.js';
|
|
25
28
|
export { departure } from './change.js';
|
|
26
29
|
export { definitionsIn, selected } from './collection.js';
|
|
27
30
|
export { lineEnded, partsAfter, partsChanges } from './room-draft.js';
|
|
28
31
|
export { cutName, nameFrom, transliterated } from './name.js';
|
|
29
|
-
export { HISTORY_CONVERSATIONS
|
|
32
|
+
export { HISTORY_CONVERSATIONS } from './conversation.js';
|
|
30
33
|
export { contextFigure } from './context.js';
|
|
31
|
-
export { sessionEnded, type RunningJob } from './job.js';
|
|
32
34
|
export { changeBatchIdentity } from './identity.js';
|
|
33
35
|
export { paced, ROW_WEIGHT, stepped } from './turn.js';
|
|
34
36
|
export { authoredAt, covered } from './paths.js';
|
|
35
37
|
export { untilAnswered } from './recovery.js';
|
|
36
|
-
export {
|
|
37
|
-
export {
|
|
38
|
-
export {
|
|
38
|
+
export { createRetries, STEPS, retrying, Unanswered, uncertainError, type RetriedFailure, type Retries, type Step, } from './retried.js';
|
|
39
|
+
export { patching } from './shared.js';
|
|
40
|
+
export { acting, type Acting, type ActingRules, type Ended, type Lane, type LaneShown, type Send, } from './act-lanes.js';
|
|
41
|
+
export { expectation, expecting, type Descriptor, type Expectation, type Expected, type Expecting, } from './expectation.js';
|
|
39
42
|
export type { AppCode, HeldCode, RuntimeShell, UnsentKind, UnsentWork } from './durability.js';
|
|
40
43
|
export type { CodeAvailability, ConnectionAvailability, ConversationCoverage, Durability, HouseOutcome, Installation, InstallationAmount, InstallationStep, Persistence, Readiness, ReadinessStatus, RoomCoverage, RoomPreparation, Space, TargetCoverage, } from './readiness.js';
|
|
41
44
|
export type { ObservedRead } from './reads.js';
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,YAAY,EACV,eAAe,EACf,YAAY,EACZ,iBAAiB,EACjB,aAAa,EACb,YAAY,EACZ,OAAO,EACP,cAAc,EACd,aAAa,EACb,YAAY,EACZ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ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,YAAY,EACV,eAAe,EACf,YAAY,EACZ,iBAAiB,EACjB,aAAa,EACb,YAAY,EACZ,OAAO,EACP,cAAc,EACd,aAAa,EACb,YAAY,EACZ,eAAe,EACf,aAAa,EACb,UAAU,EACV,gBAAgB,EAChB,aAAa,EACb,YAAY,EACZ,aAAa,EACb,gBAAgB,EAChB,eAAe,EACf,UAAU,EACV,YAAY,EACZ,mBAAmB,EACnB,kBAAkB,EAClB,iBAAiB,EACjB,qBAAqB,EACrB,uBAAuB,EACvB,0BAA0B,EAC1B,mBAAmB,EACnB,kBAAkB,EAClB,cAAc,EACd,cAAc,EACd,SAAS,EACT,UAAU,EACV,aAAa,EACb,cAAc,EACd,aAAa,EACb,gBAAgB,EAChB,eAAe,EACf,aAAa,EACb,QAAQ,EACR,QAAQ,EACR,gBAAgB,EAChB,WAAW,EACX,kBAAkB,EAClB,eAAe,EACf,MAAM,EACN,eAAe,EACf,cAAc,EACd,SAAS,EACT,aAAa,EACb,eAAe,EACf,WAAW,EACX,cAAc,EACd,aAAa,EACb,SAAS,EACT,gBAAgB,EAChB,oBAAoB,EACpB,UAAU,EACV,UAAU,EACV,eAAe,EACf,UAAU,EACV,eAAe,EACf,aAAa,EACb,YAAY,EACZ,SAAS,EACT,WAAW,EACX,iBAAiB,EACjB,oBAAoB,EACpB,aAAa,EACb,SAAS,EACT,cAAc,GACf,MAAM,cAAc,CAAC;AACtB,YAAY,EAAE,MAAM,EAAE,WAAW,EAAE,YAAY,EAAE,QAAQ,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AAC1F,OAAO,EAAE,SAAS,EAAE,MAAM,uBAAuB,CAAC;AAClD,YAAY,EACV,eAAe,EACf,gBAAgB,EAChB,gBAAgB,EAChB,iBAAiB,GAClB,MAAM,uBAAuB,CAAC;AAC/B,YAAY,EACV,SAAS,EACT,gBAAgB,EAChB,iBAAiB,EACjB,kBAAkB,EAClB,iBAAiB,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AAE,MAAM,cAAc,CAAC"}
|
package/dist/index.js
CHANGED
|
@@ -1,18 +1,21 @@
|
|
|
1
1
|
export { heldFacts } from './conversation-row.js';
|
|
2
|
+
export { PAGE_METADATA_WORDS } from './page-metadata.js';
|
|
2
3
|
export { writeRule } from './declaration.js';
|
|
3
|
-
export {
|
|
4
|
+
export { blobOf, declaredType } from './outcome.js';
|
|
5
|
+
export { refusalError } from './failure.js';
|
|
6
|
+
export { keptFile, keptLines } from './chat-types.js';
|
|
4
7
|
export { FIGURES_DAY_MS } from './figures.js';
|
|
5
8
|
export { departure } from './change.js';
|
|
6
9
|
export { definitionsIn, selected } from './collection.js';
|
|
7
10
|
export { lineEnded, partsAfter, partsChanges } from './room-draft.js';
|
|
8
11
|
export { cutName, nameFrom, transliterated } from './name.js';
|
|
9
|
-
export { HISTORY_CONVERSATIONS
|
|
12
|
+
export { HISTORY_CONVERSATIONS } from './conversation.js';
|
|
10
13
|
export { contextFigure } from './context.js';
|
|
11
|
-
export { sessionEnded } from './job.js';
|
|
12
14
|
export { changeBatchIdentity } from './identity.js';
|
|
13
15
|
export { paced, ROW_WEIGHT, stepped } from './turn.js';
|
|
14
16
|
export { authoredAt, covered } from './paths.js';
|
|
15
17
|
export { untilAnswered } from './recovery.js';
|
|
16
|
-
export {
|
|
17
|
-
export {
|
|
18
|
-
export {
|
|
18
|
+
export { createRetries, STEPS, retrying, Unanswered, uncertainError, } from './retried.js';
|
|
19
|
+
export { patching } from './shared.js';
|
|
20
|
+
export { acting, } from './act-lanes.js';
|
|
21
|
+
export { expectation, expecting, } from './expectation.js';
|