@agentshouse/mdruntime 0.1.0-c3903a68dcbbf → 0.1.0-c56daf494ecb4
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/AGENTS.md +184 -92
- package/README.md +22 -12
- package/dist/adapter.d.ts +125 -63
- package/dist/adapter.d.ts.map +1 -1
- package/dist/adapter.js +1 -9
- package/dist/attached-model.d.ts +11 -0
- package/dist/attached-model.d.ts.map +1 -0
- package/dist/attached-model.js +47 -0
- package/dist/attempt.d.ts +16 -0
- package/dist/attempt.d.ts.map +1 -0
- package/dist/attempt.js +70 -0
- package/dist/binary.d.ts +23 -0
- package/dist/binary.d.ts.map +1 -0
- package/dist/binary.js +8 -0
- package/dist/bootstrap.d.ts +20 -6
- package/dist/bootstrap.d.ts.map +1 -1
- package/dist/bootstrap.js +93 -39
- package/dist/change-set.d.ts.map +1 -1
- package/dist/change-set.js +20 -17
- package/dist/change.d.ts +15 -0
- package/dist/change.d.ts.map +1 -1
- package/dist/change.js +26 -1
- package/dist/chat/acts.d.ts +34 -0
- package/dist/chat/acts.d.ts.map +1 -0
- package/dist/chat/acts.js +36 -0
- package/dist/chat/context.d.ts +3 -0
- package/dist/chat/context.d.ts.map +1 -0
- package/dist/chat/context.js +10 -0
- package/dist/chat/input.d.ts +9 -0
- package/dist/chat/input.d.ts.map +1 -0
- package/dist/chat/input.js +99 -0
- package/dist/chat/kit.d.ts +60 -0
- package/dist/chat/kit.d.ts.map +1 -0
- package/dist/chat/kit.js +123 -0
- package/dist/chat/lasting.d.ts +6 -0
- package/dist/chat/lasting.d.ts.map +1 -0
- package/dist/chat/lasting.js +19 -0
- package/dist/chat/list.d.ts +26 -0
- package/dist/chat/list.d.ts.map +1 -0
- package/dist/chat/list.js +62 -0
- package/dist/chat/markdown.d.ts +20 -0
- package/dist/chat/markdown.d.ts.map +1 -0
- package/dist/chat/markdown.js +188 -0
- package/dist/chat/message.d.ts +6 -0
- package/dist/chat/message.d.ts.map +1 -0
- package/dist/chat/message.js +192 -0
- package/dist/chat/messages.d.ts +21 -0
- package/dist/chat/messages.d.ts.map +1 -0
- package/dist/chat/messages.js +151 -0
- package/dist/chat/name.d.ts +6 -0
- package/dist/chat/name.d.ts.map +1 -0
- package/dist/chat/name.js +37 -0
- package/dist/chat/opened.d.ts +11 -0
- package/dist/chat/opened.d.ts.map +1 -0
- package/dist/chat/opened.js +17 -0
- package/dist/chat/overlay.d.ts +31 -0
- package/dist/chat/overlay.d.ts.map +1 -0
- package/dist/chat/overlay.js +97 -0
- package/dist/chat/parts.d.ts +57 -0
- package/dist/chat/parts.d.ts.map +1 -0
- package/dist/chat/parts.js +119 -0
- package/dist/chat/process.d.ts +20 -0
- package/dist/chat/process.d.ts.map +1 -0
- package/dist/chat/process.js +32 -0
- package/dist/chat/provider.d.ts +63 -0
- package/dist/chat/provider.d.ts.map +1 -0
- package/dist/chat/provider.js +645 -0
- package/dist/chat/question.d.ts +9 -0
- package/dist/chat/question.d.ts.map +1 -0
- package/dist/chat/question.js +80 -0
- package/dist/chat/questions.d.ts +31 -0
- package/dist/chat/questions.d.ts.map +1 -0
- package/dist/chat/questions.js +111 -0
- package/dist/chat/read.d.ts +5 -0
- package/dist/chat/read.d.ts.map +1 -0
- package/dist/chat/read.js +13 -0
- package/dist/chat/ready.d.ts +33 -0
- package/dist/chat/ready.d.ts.map +1 -0
- package/dist/chat/ready.js +91 -0
- package/dist/chat/style.d.ts +4 -0
- package/dist/chat/style.d.ts.map +1 -0
- package/dist/chat/style.js +302 -0
- package/dist/chat.d.ts +14 -0
- package/dist/chat.d.ts.map +1 -0
- package/dist/chat.js +8 -0
- package/dist/client.d.ts +17 -13
- package/dist/client.d.ts.map +1 -1
- package/dist/client.js +68 -31
- package/dist/collection.d.ts +6 -13
- package/dist/collection.d.ts.map +1 -1
- package/dist/collection.js +56 -29
- package/dist/connection.d.ts +28 -33
- package/dist/connection.d.ts.map +1 -1
- package/dist/connection.js +951 -745
- package/dist/conversation.d.ts +32 -13
- package/dist/conversation.d.ts.map +1 -1
- package/dist/conversation.js +293 -108
- package/dist/entry.d.ts +17 -0
- package/dist/entry.d.ts.map +1 -0
- package/dist/entry.js +156 -0
- package/dist/expectation.d.ts +21 -0
- package/dist/expectation.d.ts.map +1 -0
- package/dist/expectation.js +70 -0
- package/dist/failure.d.ts +13 -0
- package/dist/failure.d.ts.map +1 -0
- package/dist/failure.js +19 -0
- package/dist/host.d.ts +9 -3
- package/dist/host.d.ts.map +1 -1
- package/dist/host.js +49 -68
- package/dist/identity.d.ts +3 -0
- package/dist/identity.d.ts.map +1 -1
- package/dist/identity.js +13 -1
- package/dist/index.d.ts +9 -5
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +3 -1
- package/dist/memory.d.ts +14 -7
- package/dist/memory.d.ts.map +1 -1
- package/dist/memory.js +137 -46
- package/dist/model.d.ts +13 -12
- package/dist/model.d.ts.map +1 -1
- package/dist/model.js +6 -3
- package/dist/observation.d.ts +2 -0
- package/dist/observation.d.ts.map +1 -1
- package/dist/observation.js +24 -14
- package/dist/open.d.ts +2 -0
- package/dist/open.d.ts.map +1 -0
- package/dist/open.js +1 -0
- package/dist/outcome.d.ts +32 -23
- package/dist/outcome.d.ts.map +1 -1
- package/dist/outcome.js +41 -1
- package/dist/overlay.d.ts +14 -3
- package/dist/overlay.d.ts.map +1 -1
- package/dist/overlay.js +75 -37
- package/dist/paths.d.ts +0 -1
- package/dist/paths.d.ts.map +1 -1
- package/dist/paths.js +0 -16
- package/dist/query.d.ts +12 -3
- package/dist/query.d.ts.map +1 -1
- package/dist/query.js +78 -36
- package/dist/reach.d.ts +42 -0
- package/dist/reach.d.ts.map +1 -0
- package/dist/reach.js +294 -0
- package/dist/react.d.ts +41 -0
- package/dist/react.d.ts.map +1 -0
- package/dist/react.js +64 -0
- package/dist/read-side.d.ts +4 -0
- package/dist/read-side.d.ts.map +1 -1
- package/dist/read-side.js +125 -56
- package/dist/refresh.d.ts +12 -1
- package/dist/refresh.d.ts.map +1 -1
- package/dist/refresh.js +44 -36
- package/dist/replica.d.ts +9 -6
- package/dist/replica.d.ts.map +1 -1
- package/dist/replica.js +83 -68
- package/dist/room-draft.d.ts +29 -9
- package/dist/room-draft.d.ts.map +1 -1
- package/dist/room-draft.js +137 -26
- package/dist/rows.d.ts +7 -2
- package/dist/rows.d.ts.map +1 -1
- package/dist/rows.js +85 -40
- package/dist/save.d.ts +27 -3
- package/dist/save.d.ts.map +1 -1
- package/dist/save.js +435 -86
- package/dist/search.d.ts +3 -2
- package/dist/search.d.ts.map +1 -1
- package/dist/status.d.ts +2 -2
- package/dist/status.d.ts.map +1 -1
- package/dist/status.js +0 -8
- package/dist/store.d.ts +41 -25
- package/dist/store.d.ts.map +1 -1
- package/dist/store.js +315 -191
- package/dist/wire.d.ts +58 -19
- package/dist/wire.d.ts.map +1 -1
- package/dist/wire.js +65 -67
- package/package.json +31 -7
- package/dist/attachment.d.ts +0 -3
- package/dist/attachment.d.ts.map +0 -1
- package/dist/attachment.js +0 -8
package/dist/entry.js
ADDED
|
@@ -0,0 +1,156 @@
|
|
|
1
|
+
import { attachedModel } from './attached-model.js';
|
|
2
|
+
import { collectionOf, passingDocument } from './collection.js';
|
|
3
|
+
import { NO_MODEL } from './model.js';
|
|
4
|
+
import { invalid, planOf, plain, QueryError, } from './query.js';
|
|
5
|
+
import { createReadSide } from './read-side.js';
|
|
6
|
+
import { rowsOf } from './rows.js';
|
|
7
|
+
export { QueryError } from './query.js';
|
|
8
|
+
const PARAMETER = '$param';
|
|
9
|
+
const KIND = 'as';
|
|
10
|
+
const INTEGER = /^-?(?:0|[1-9][0-9]*)$/u;
|
|
11
|
+
const NUMBER = /^-?(?:0|[1-9][0-9]*)(?:\.[0-9]+)?$/u;
|
|
12
|
+
function parameterOf(value) {
|
|
13
|
+
if (!plain(value) || !Object.hasOwn(value, PARAMETER))
|
|
14
|
+
return null;
|
|
15
|
+
const { [PARAMETER]: name, [KIND]: kind = 'string', ...rest } = value;
|
|
16
|
+
if (typeof name !== 'string' || Object.keys(rest).length > 0)
|
|
17
|
+
return null;
|
|
18
|
+
if (kind !== 'string' && kind !== 'integer' && kind !== 'number' && kind !== 'boolean') {
|
|
19
|
+
return null;
|
|
20
|
+
}
|
|
21
|
+
return { name, kind };
|
|
22
|
+
}
|
|
23
|
+
function converted(text, kind, at) {
|
|
24
|
+
if (kind === 'string')
|
|
25
|
+
return text;
|
|
26
|
+
if (kind === 'boolean') {
|
|
27
|
+
if (text === 'true' || text === 'false')
|
|
28
|
+
return text === 'true';
|
|
29
|
+
return invalid(at, 'expects true or false');
|
|
30
|
+
}
|
|
31
|
+
if (!(kind === 'integer' ? INTEGER : NUMBER).test(text))
|
|
32
|
+
invalid(at, `expects ${kind === 'integer' ? 'an integer' : 'a number'}`);
|
|
33
|
+
const number = Number(text);
|
|
34
|
+
if (!Number.isFinite(number) || (kind === 'integer' && !Number.isSafeInteger(number))) {
|
|
35
|
+
invalid(at, 'is out of range');
|
|
36
|
+
}
|
|
37
|
+
return number;
|
|
38
|
+
}
|
|
39
|
+
function bound(template, args, at) {
|
|
40
|
+
const parameter = parameterOf(template);
|
|
41
|
+
if (parameter !== null) {
|
|
42
|
+
const text = args[parameter.name];
|
|
43
|
+
if (text === undefined || !Object.hasOwn(args, parameter.name)) {
|
|
44
|
+
invalid(at, `names the parameter ${parameter.name}, which the route lacks`);
|
|
45
|
+
}
|
|
46
|
+
return converted(text, parameter.kind, at);
|
|
47
|
+
}
|
|
48
|
+
if (Array.isArray(template)) {
|
|
49
|
+
return template.map((item, index) => bound(item, args, `${at}[${index}]`));
|
|
50
|
+
}
|
|
51
|
+
if (plain(template)) {
|
|
52
|
+
return Object.fromEntries(Object.entries(template).map(([name, value]) => [
|
|
53
|
+
name,
|
|
54
|
+
bound(value, args, at === '' ? name : `${at}.${name}`),
|
|
55
|
+
]));
|
|
56
|
+
}
|
|
57
|
+
return template;
|
|
58
|
+
}
|
|
59
|
+
export function boundQuery(template, args) {
|
|
60
|
+
return bound(template, args, '');
|
|
61
|
+
}
|
|
62
|
+
export function entryParameters(template) {
|
|
63
|
+
const parameter = parameterOf(template);
|
|
64
|
+
if (parameter !== null)
|
|
65
|
+
return [parameter.name];
|
|
66
|
+
if (Array.isArray(template))
|
|
67
|
+
return [...new Set(template.flatMap(entryParameters))];
|
|
68
|
+
if (plain(template))
|
|
69
|
+
return [...new Set(Object.values(template).flatMap(entryParameters))];
|
|
70
|
+
return [];
|
|
71
|
+
}
|
|
72
|
+
const SAMPLED = {
|
|
73
|
+
direction: 'asc',
|
|
74
|
+
nulls: 'last',
|
|
75
|
+
stringSort: 'lexical',
|
|
76
|
+
locale: 'en',
|
|
77
|
+
limit: 0,
|
|
78
|
+
pathPrefix: 'entry',
|
|
79
|
+
field: '/entry',
|
|
80
|
+
fields: '/entry',
|
|
81
|
+
types: 'any',
|
|
82
|
+
$in: 'entry',
|
|
83
|
+
$nin: 'entry',
|
|
84
|
+
$all: 'entry',
|
|
85
|
+
$size: 0,
|
|
86
|
+
$exists: true,
|
|
87
|
+
$gt: 0,
|
|
88
|
+
$gte: 0,
|
|
89
|
+
$lt: 0,
|
|
90
|
+
$lte: 0,
|
|
91
|
+
};
|
|
92
|
+
function sampled(template, key) {
|
|
93
|
+
if (parameterOf(template) !== null)
|
|
94
|
+
return Object.hasOwn(SAMPLED, key) ? SAMPLED[key] : null;
|
|
95
|
+
if (Array.isArray(template))
|
|
96
|
+
return template.map((item) => sampled(item, key));
|
|
97
|
+
if (plain(template)) {
|
|
98
|
+
return Object.fromEntries(Object.entries(template).map(([name, value]) => [name, sampled(value, name)]));
|
|
99
|
+
}
|
|
100
|
+
return template;
|
|
101
|
+
}
|
|
102
|
+
export function entryRefusal(template) {
|
|
103
|
+
try {
|
|
104
|
+
planOf(sampled(template, ''), { listed: false, rooms: [] });
|
|
105
|
+
return null;
|
|
106
|
+
}
|
|
107
|
+
catch (error) {
|
|
108
|
+
if (error instanceof QueryError)
|
|
109
|
+
return error.message;
|
|
110
|
+
throw error;
|
|
111
|
+
}
|
|
112
|
+
}
|
|
113
|
+
export function entryScope(rooms) {
|
|
114
|
+
const readSide = createReadSide();
|
|
115
|
+
const held = [];
|
|
116
|
+
const documents = rooms.flatMap((room) => {
|
|
117
|
+
const model = attachedModel({
|
|
118
|
+
kind: 'model',
|
|
119
|
+
snapshot: { identity: room.locator, version: '', schema: room.schema, revision: null },
|
|
120
|
+
}, NO_MODEL).state;
|
|
121
|
+
held.push({
|
|
122
|
+
locator: room.locator,
|
|
123
|
+
available: model.status !== 'unavailable',
|
|
124
|
+
types: model.status === 'unavailable' ? [] : Object.values(model.types),
|
|
125
|
+
});
|
|
126
|
+
const composition = { model, selection: null };
|
|
127
|
+
const collection = collectionOf(room.documents, composition);
|
|
128
|
+
return Object.keys(room.documents)
|
|
129
|
+
.sort()
|
|
130
|
+
.map((path) => ({
|
|
131
|
+
locator: room.locator,
|
|
132
|
+
path,
|
|
133
|
+
before: [],
|
|
134
|
+
after: rowsOf(room.locator, path, passingDocument(collection, path) ?? null, composition, null, null),
|
|
135
|
+
}));
|
|
136
|
+
});
|
|
137
|
+
readSide.apply({
|
|
138
|
+
documents,
|
|
139
|
+
drafts: [],
|
|
140
|
+
rooms: [],
|
|
141
|
+
queues: [],
|
|
142
|
+
presentations: [],
|
|
143
|
+
messages: [],
|
|
144
|
+
conversations: [],
|
|
145
|
+
});
|
|
146
|
+
const planned = { listed: true, rooms: held };
|
|
147
|
+
return {
|
|
148
|
+
async results(queries) {
|
|
149
|
+
const results = {};
|
|
150
|
+
for (const [name, query] of Object.entries(queries)) {
|
|
151
|
+
results[name] = await readSide.query(planOf(query, planned));
|
|
152
|
+
}
|
|
153
|
+
return results;
|
|
154
|
+
},
|
|
155
|
+
};
|
|
156
|
+
}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
export type ExpectedOf<E extends {
|
|
2
|
+
readonly key: string;
|
|
3
|
+
}> = E | readonly E[] | null;
|
|
4
|
+
export type Expecting<E extends {
|
|
5
|
+
readonly key: string;
|
|
6
|
+
}> = {
|
|
7
|
+
subscribe(listener: () => void): () => void;
|
|
8
|
+
version(): number;
|
|
9
|
+
begin(): number;
|
|
10
|
+
expect(act: number, expected: ExpectedOf<E>, settled?: (one: E) => boolean): void;
|
|
11
|
+
drop(act: number): void;
|
|
12
|
+
heard(shown: (one: E) => boolean): void;
|
|
13
|
+
drawn(): readonly E[];
|
|
14
|
+
};
|
|
15
|
+
export declare function expectedList<E extends {
|
|
16
|
+
readonly key: string;
|
|
17
|
+
}>(expected: ExpectedOf<E>): readonly E[];
|
|
18
|
+
export declare function expecting<E extends {
|
|
19
|
+
readonly key: string;
|
|
20
|
+
}>(): Expecting<E>;
|
|
21
|
+
//# sourceMappingURL=expectation.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"expectation.d.ts","sourceRoot":"","sources":["../src/expectation.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,UAAU,CAAC,CAAC,SAAS;IAAE,QAAQ,CAAC,GAAG,EAAE,MAAM,CAAA;CAAE,IAAI,CAAC,GAAG,SAAS,CAAC,EAAE,GAAG,IAAI,CAAC;AAErF,MAAM,MAAM,SAAS,CAAC,CAAC,SAAS;IAAE,QAAQ,CAAC,GAAG,EAAE,MAAM,CAAA;CAAE,IAAI;IAC1D,SAAS,CAAC,QAAQ,EAAE,MAAM,IAAI,GAAG,MAAM,IAAI,CAAC;IAC5C,OAAO,IAAI,MAAM,CAAC;IAClB,KAAK,IAAI,MAAM,CAAC;IAChB,MAAM,CAAC,GAAG,EAAE,MAAM,EAAE,QAAQ,EAAE,UAAU,CAAC,CAAC,CAAC,EAAE,OAAO,CAAC,EAAE,CAAC,GAAG,EAAE,CAAC,KAAK,OAAO,GAAG,IAAI,CAAC;IAClF,IAAI,CAAC,GAAG,EAAE,MAAM,GAAG,IAAI,CAAC;IACxB,KAAK,CAAC,KAAK,EAAE,CAAC,GAAG,EAAE,CAAC,KAAK,OAAO,GAAG,IAAI,CAAC;IACxC,KAAK,IAAI,SAAS,CAAC,EAAE,CAAC;CACvB,CAAC;AAIF,wBAAgB,YAAY,CAAC,CAAC,SAAS;IAAE,QAAQ,CAAC,GAAG,EAAE,MAAM,CAAA;CAAE,EAC7D,QAAQ,EAAE,UAAU,CAAC,CAAC,CAAC,GACtB,SAAS,CAAC,EAAE,CAGd;AAwBD,wBAAgB,SAAS,CAAC,CAAC,SAAS;IAAE,QAAQ,CAAC,GAAG,EAAE,MAAM,CAAA;CAAE,KAAK,SAAS,CAAC,CAAC,CAAC,CA4C5E"}
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
export function expectedList(expected) {
|
|
2
|
+
if (expected === null)
|
|
3
|
+
return [];
|
|
4
|
+
return 'key' in expected ? [expected] : expected;
|
|
5
|
+
}
|
|
6
|
+
function superseded(entries, at) {
|
|
7
|
+
const key = entries[at]?.expectation.key;
|
|
8
|
+
return entries.slice(at + 1).some((later) => later.expectation.key === key);
|
|
9
|
+
}
|
|
10
|
+
function unended(entries, ends) {
|
|
11
|
+
const ended = new Set();
|
|
12
|
+
const kept = [];
|
|
13
|
+
for (const one of [...entries].reverse()) {
|
|
14
|
+
if (ended.has(one.expectation.key))
|
|
15
|
+
continue;
|
|
16
|
+
if (ends(one.expectation))
|
|
17
|
+
ended.add(one.expectation.key);
|
|
18
|
+
else
|
|
19
|
+
kept.unshift(one);
|
|
20
|
+
}
|
|
21
|
+
return kept;
|
|
22
|
+
}
|
|
23
|
+
export function expecting() {
|
|
24
|
+
let entries = [];
|
|
25
|
+
let version = 0;
|
|
26
|
+
let acts = 0;
|
|
27
|
+
const listeners = new Set();
|
|
28
|
+
const set = (next) => {
|
|
29
|
+
if (next.length === entries.length && next.every((one, at) => one === entries[at]))
|
|
30
|
+
return;
|
|
31
|
+
entries = next;
|
|
32
|
+
version += 1;
|
|
33
|
+
for (const listener of listeners)
|
|
34
|
+
listener();
|
|
35
|
+
};
|
|
36
|
+
return {
|
|
37
|
+
subscribe(listener) {
|
|
38
|
+
listeners.add(listener);
|
|
39
|
+
return () => {
|
|
40
|
+
listeners.delete(listener);
|
|
41
|
+
};
|
|
42
|
+
},
|
|
43
|
+
version: () => version,
|
|
44
|
+
begin() {
|
|
45
|
+
acts += 1;
|
|
46
|
+
return acts;
|
|
47
|
+
},
|
|
48
|
+
expect(act, expected, settled = () => false) {
|
|
49
|
+
const fresh = expectedList(expected);
|
|
50
|
+
if (fresh.length === 0)
|
|
51
|
+
return;
|
|
52
|
+
const keys = new Set(fresh.map((one) => one.key));
|
|
53
|
+
const kept = entries.filter((one) => one.act !== act || !keys.has(one.expectation.key));
|
|
54
|
+
const over = new Set(kept.map((one) => one.expectation.key));
|
|
55
|
+
set([
|
|
56
|
+
...kept,
|
|
57
|
+
...fresh
|
|
58
|
+
.filter((one) => over.has(one.key) || !settled(one))
|
|
59
|
+
.map((expectation) => ({ act, expectation })),
|
|
60
|
+
]);
|
|
61
|
+
},
|
|
62
|
+
drop(act) {
|
|
63
|
+
set(entries.filter((one) => one.act !== act));
|
|
64
|
+
},
|
|
65
|
+
heard(shown) {
|
|
66
|
+
set(unended(entries, shown));
|
|
67
|
+
},
|
|
68
|
+
drawn: () => entries.flatMap((one, at) => (superseded(entries, at) ? [] : [one.expectation])),
|
|
69
|
+
};
|
|
70
|
+
}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
export type RuntimeError = Error & {
|
|
2
|
+
readonly code: string;
|
|
3
|
+
readonly retryable: boolean;
|
|
4
|
+
};
|
|
5
|
+
export type Described = {
|
|
6
|
+
message: string;
|
|
7
|
+
code: string;
|
|
8
|
+
retryable: boolean;
|
|
9
|
+
};
|
|
10
|
+
export declare function runtimeError(code: string, message?: string, retryable?: boolean): RuntimeError;
|
|
11
|
+
export declare function failed(error: unknown): RuntimeError;
|
|
12
|
+
export declare function described(error: unknown): Described;
|
|
13
|
+
//# sourceMappingURL=failure.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"failure.d.ts","sourceRoot":"","sources":["../src/failure.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,YAAY,GAAG,KAAK,GAAG;IAAE,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IAAC,QAAQ,CAAC,SAAS,EAAE,OAAO,CAAA;CAAE,CAAC;AAE1F,MAAM,MAAM,SAAS,GAAG;IAAE,OAAO,EAAE,MAAM,CAAC;IAAC,IAAI,EAAE,MAAM,CAAC;IAAC,SAAS,EAAE,OAAO,CAAA;CAAE,CAAC;AAE9E,wBAAgB,YAAY,CAC1B,IAAI,EAAE,MAAM,EACZ,OAAO,GAAE,MAAa,EACtB,SAAS,UAAQ,GAChB,YAAY,CAEd;AAYD,wBAAgB,MAAM,CAAC,KAAK,EAAE,OAAO,GAAG,YAAY,CAGnD;AAED,wBAAgB,SAAS,CAAC,KAAK,EAAE,OAAO,GAAG,SAAS,CAGnD"}
|
package/dist/failure.js
ADDED
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
export function runtimeError(code, message = code, retryable = false) {
|
|
2
|
+
return Object.assign(new Error(message), { code, retryable });
|
|
3
|
+
}
|
|
4
|
+
function coded(error) {
|
|
5
|
+
return (error instanceof Error &&
|
|
6
|
+
'code' in error &&
|
|
7
|
+
typeof error.code === 'string' &&
|
|
8
|
+
'retryable' in error &&
|
|
9
|
+
typeof error.retryable === 'boolean');
|
|
10
|
+
}
|
|
11
|
+
export function failed(error) {
|
|
12
|
+
if (coded(error))
|
|
13
|
+
return error;
|
|
14
|
+
return runtimeError('runtime-failure', error instanceof Error ? error.message : String(error));
|
|
15
|
+
}
|
|
16
|
+
export function described(error) {
|
|
17
|
+
const { message, code, retryable } = failed(error);
|
|
18
|
+
return { message, code, retryable };
|
|
19
|
+
}
|
package/dist/host.d.ts
CHANGED
|
@@ -1,14 +1,20 @@
|
|
|
1
1
|
import { type MdRuntimeOptions } from './connection.js';
|
|
2
|
+
import type { PortReach } from './reach.js';
|
|
2
3
|
import { type RuntimePort } from './wire.js';
|
|
3
4
|
export type MdRuntimeHostOptions = MdRuntimeOptions & {
|
|
4
5
|
deploymentFacts?: unknown;
|
|
5
6
|
};
|
|
7
|
+
export type AttachedPort = {
|
|
8
|
+
detach(): void;
|
|
9
|
+
narrow(reach: PortReach): void;
|
|
10
|
+
};
|
|
6
11
|
export type MdRuntimeHost = {
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
endAuthorization(): Promise<void>;
|
|
12
|
+
attach(port: RuntimePort, app: string, release?: string, reach?: PortReach): AttachedPort;
|
|
13
|
+
endAuthorization(holder?: string): Promise<void>;
|
|
10
14
|
stop(): Promise<void>;
|
|
11
15
|
};
|
|
12
16
|
export declare function serveMdRuntime(options: MdRuntimeHostOptions): MdRuntimeHost;
|
|
17
|
+
export type { PortReach, ReachedDocument } from './reach.js';
|
|
18
|
+
export { AUTHORED_SCHEMA, authoredBy, authoredHolder, STORE_SCHEMA } from './store.js';
|
|
13
19
|
export type { RuntimePort } from './wire.js';
|
|
14
20
|
//# sourceMappingURL=host.d.ts.map
|
package/dist/host.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"host.d.ts","sourceRoot":"","sources":["../src/host.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"host.d.ts","sourceRoot":"","sources":["../src/host.ts"],"names":[],"mappings":"AAEA,OAAO,EAIL,KAAK,gBAAgB,EAEtB,MAAM,iBAAiB,CAAC;AAGzB,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,YAAY,CAAC;AAI5C,OAAO,EAGL,KAAK,WAAW,EAOjB,MAAM,WAAW,CAAC;AAInB,MAAM,MAAM,oBAAoB,GAAG,gBAAgB,GAAG;IAAE,eAAe,CAAC,EAAE,OAAO,CAAA;CAAE,CAAC;AAEpF,MAAM,MAAM,YAAY,GAAG;IACzB,MAAM,IAAI,IAAI,CAAC;IACf,MAAM,CAAC,KAAK,EAAE,SAAS,GAAG,IAAI,CAAC;CAChC,CAAC;AAEF,MAAM,MAAM,aAAa,GAAG;IAC1B,MAAM,CAAC,IAAI,EAAE,WAAW,EAAE,GAAG,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,MAAM,EAAE,KAAK,CAAC,EAAE,SAAS,GAAG,YAAY,CAAC;IAC1F,gBAAgB,CAAC,MAAM,CAAC,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IACjD,IAAI,IAAI,OAAO,CAAC,IAAI,CAAC,CAAC;CACvB,CAAC;AAsFF,wBAAgB,cAAc,CAAC,OAAO,EAAE,oBAAoB,GAAG,aAAa,CAiH3E;AAED,YAAY,EAAE,SAAS,EAAE,eAAe,EAAE,MAAM,YAAY,CAAC;AAC7D,OAAO,EAAE,eAAe,EAAE,UAAU,EAAE,cAAc,EAAE,YAAY,EAAE,MAAM,YAAY,CAAC;AACvF,YAAY,EAAE,WAAW,EAAE,MAAM,WAAW,CAAC"}
|
package/dist/host.js
CHANGED
|
@@ -1,38 +1,32 @@
|
|
|
1
1
|
import { composeRuntime, } from './connection.js';
|
|
2
|
+
import { described } from './failure.js';
|
|
2
3
|
import { removeRuntimeStore } from './store.js';
|
|
3
|
-
import { AUTHORIZATION_ENDED,
|
|
4
|
-
|
|
4
|
+
import { AUTHORIZATION_ENDED, request, WIRE_REACH, } from './wire.js';
|
|
5
|
+
const NARROWED = new Set(['within', 'whole']);
|
|
6
|
+
function answered(md, app, writtenBy, member, input) {
|
|
5
7
|
switch (member) {
|
|
6
8
|
case 'rooms':
|
|
7
9
|
return md.rooms();
|
|
8
|
-
case 'slots':
|
|
9
|
-
return md.slots();
|
|
10
10
|
case 'query':
|
|
11
11
|
return md.query(input[0]);
|
|
12
12
|
case 'search':
|
|
13
13
|
return md.search(input[0]);
|
|
14
14
|
case 'types':
|
|
15
15
|
return md.types(input[0]);
|
|
16
|
-
case 'syncStatus':
|
|
17
|
-
return md.syncStatus();
|
|
18
|
-
case 'serviceMode':
|
|
19
|
-
return md.serviceMode();
|
|
20
16
|
case 'save':
|
|
21
17
|
return md.save(input[0], input[1], writtenBy);
|
|
22
|
-
case 'outcome':
|
|
23
|
-
return md.outcome(input[0]);
|
|
24
18
|
case 'history':
|
|
25
19
|
return md.history(input[0], input[1], input[2]);
|
|
20
|
+
case 'binaryFile.read':
|
|
21
|
+
return md.binaryFile.read(input[0], input[1], input[2]);
|
|
22
|
+
case 'binaryFile.readReference':
|
|
23
|
+
return md.binaryFile.readReference(input[0]);
|
|
26
24
|
case 'call':
|
|
27
25
|
return md.call(input[0], input[1]);
|
|
28
26
|
case 'reached':
|
|
29
27
|
return md.reached(input[0], input[1], input[2]);
|
|
30
28
|
case 'log':
|
|
31
29
|
return md.log();
|
|
32
|
-
case 'storageLoss':
|
|
33
|
-
return md.storageLoss();
|
|
34
|
-
case 'deploymentFacts':
|
|
35
|
-
return structuredClone(deploymentFacts);
|
|
36
30
|
case 'persistence':
|
|
37
31
|
return md.persistence();
|
|
38
32
|
case 'reauthorize':
|
|
@@ -68,13 +62,13 @@ function answered(md, app, writtenBy, member, input, deploymentFacts) {
|
|
|
68
62
|
case 'conversation.delete':
|
|
69
63
|
return md.conversation.delete(input[0]);
|
|
70
64
|
case 'chatDraft.write':
|
|
71
|
-
return md.chatDraft.write(input[0], input[1]);
|
|
65
|
+
return md.chatDraft.write(input[0], input[1], input[2]);
|
|
72
66
|
case 'chatDraft.discard':
|
|
73
67
|
return md.chatDraft.discard(input[0]);
|
|
74
68
|
}
|
|
75
69
|
}
|
|
76
70
|
export function serveMdRuntime(options) {
|
|
77
|
-
|
|
71
|
+
const deploymentFacts = structuredClone(options.deploymentFacts);
|
|
78
72
|
const closing = new AbortController();
|
|
79
73
|
const close = () => {
|
|
80
74
|
closing.abort();
|
|
@@ -83,86 +77,73 @@ export function serveMdRuntime(options) {
|
|
|
83
77
|
if (options.signal?.aborted === true)
|
|
84
78
|
close();
|
|
85
79
|
const runtime = composeRuntime({ ...options, signal: closing.signal });
|
|
86
|
-
const { md
|
|
80
|
+
const { md } = runtime;
|
|
87
81
|
const attachments = new Map();
|
|
88
82
|
let authorized = true;
|
|
89
|
-
const factsObservers = new Set();
|
|
90
83
|
const watchFacts = (deliver) => {
|
|
91
|
-
factsObservers.add(deliver);
|
|
92
84
|
deliver(structuredClone(deploymentFacts));
|
|
93
|
-
return () => {
|
|
94
|
-
factsObservers.delete(deliver);
|
|
95
|
-
};
|
|
85
|
+
return () => { };
|
|
96
86
|
};
|
|
97
|
-
function attach(port, app, release) {
|
|
87
|
+
function attach(port, app, release, reach) {
|
|
98
88
|
if (!authorized)
|
|
99
89
|
throw new Error(AUTHORIZATION_ENDED);
|
|
100
90
|
const writtenBy = release === undefined ? undefined : { app, release };
|
|
101
|
-
const
|
|
91
|
+
const view = runtime.within(reach ?? null);
|
|
92
|
+
const observations = new Map();
|
|
102
93
|
let serving = true;
|
|
103
94
|
const send = (message) => {
|
|
104
|
-
port.postMessage(
|
|
95
|
+
port.postMessage(message);
|
|
105
96
|
};
|
|
106
97
|
const detach = () => {
|
|
107
98
|
if (!serving)
|
|
108
99
|
return;
|
|
109
100
|
serving = false;
|
|
110
|
-
for (const end of
|
|
101
|
+
for (const end of observations.values())
|
|
111
102
|
end();
|
|
112
|
-
|
|
103
|
+
observations.clear();
|
|
113
104
|
attachments.delete(detach);
|
|
114
105
|
};
|
|
106
|
+
const observe = (id, topic, input) => {
|
|
107
|
+
let resolved = false;
|
|
108
|
+
const deliver = (value) => {
|
|
109
|
+
if (!serving)
|
|
110
|
+
return;
|
|
111
|
+
send(resolved ? { kind: 'event', id, value } : { kind: 'result', id, value });
|
|
112
|
+
resolved = true;
|
|
113
|
+
};
|
|
114
|
+
observations.set(id, topic === 'deployment-facts'
|
|
115
|
+
? watchFacts(deliver)
|
|
116
|
+
: (NARROWED.has(WIRE_REACH.topics[topic]) ? view : runtime).watch(topic, topic === 'presentation' ? [app] : input, deliver));
|
|
117
|
+
};
|
|
115
118
|
const serve = async (message) => {
|
|
116
119
|
if (message.kind === 'hello')
|
|
117
120
|
return;
|
|
118
121
|
if (message.kind === 'stop') {
|
|
119
|
-
|
|
120
|
-
|
|
122
|
+
observations.get(message.id)?.();
|
|
123
|
+
observations.delete(message.id);
|
|
121
124
|
return;
|
|
122
125
|
}
|
|
123
126
|
try {
|
|
124
127
|
if (message.kind !== 'observe' || message.topic !== 'room-drafts')
|
|
125
128
|
await md.loaded();
|
|
126
129
|
if (message.kind === 'observe') {
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
const deliver = (value) => {
|
|
130
|
-
if (!serving)
|
|
131
|
-
return;
|
|
132
|
-
send(resolved ? { kind: 'event', id, value } : { kind: 'result', id, value });
|
|
133
|
-
resolved = true;
|
|
134
|
-
};
|
|
135
|
-
subscriptions.set(id, topic === 'deployment-facts'
|
|
136
|
-
? watchFacts(deliver)
|
|
137
|
-
: watch(topic, topic === 'presentation' ? [app] : message.input, deliver));
|
|
130
|
+
if (serving)
|
|
131
|
+
observe(message.id, message.topic, message.input);
|
|
138
132
|
return;
|
|
139
133
|
}
|
|
140
|
-
const value = await answered(md, app, writtenBy, message.member, message.input
|
|
134
|
+
const value = await answered(NARROWED.has(WIRE_REACH.members[message.member]) ? view.md : md, app, writtenBy, message.member, message.input);
|
|
141
135
|
if (serving)
|
|
142
136
|
send({ kind: 'result', id: message.id, value });
|
|
143
137
|
}
|
|
144
138
|
catch (error) {
|
|
145
|
-
if (serving)
|
|
146
|
-
send({
|
|
147
|
-
kind: 'failure',
|
|
148
|
-
id: message.id,
|
|
149
|
-
message: error instanceof Error ? error.message : String(error),
|
|
150
|
-
});
|
|
151
|
-
}
|
|
139
|
+
if (serving)
|
|
140
|
+
send({ kind: 'failure', id: message.id, ...described(error) });
|
|
152
141
|
}
|
|
153
142
|
};
|
|
154
143
|
port.addEventListener('message', (event) => {
|
|
155
144
|
if (!serving)
|
|
156
145
|
return;
|
|
157
|
-
const
|
|
158
|
-
if (wire === null)
|
|
159
|
-
return;
|
|
160
|
-
if (!wire.matching) {
|
|
161
|
-
send({ kind: 'refusal', refusal: PROTOCOL_MISMATCH });
|
|
162
|
-
detach();
|
|
163
|
-
return;
|
|
164
|
-
}
|
|
165
|
-
const message = request(wire.message);
|
|
146
|
+
const message = request(event.data);
|
|
166
147
|
if (message === null)
|
|
167
148
|
return;
|
|
168
149
|
void serve(message);
|
|
@@ -170,29 +151,29 @@ export function serveMdRuntime(options) {
|
|
|
170
151
|
port.addEventListener('close', detach);
|
|
171
152
|
port.start();
|
|
172
153
|
attachments.set(detach, send);
|
|
173
|
-
return
|
|
154
|
+
return {
|
|
155
|
+
detach,
|
|
156
|
+
narrow(next) {
|
|
157
|
+
if (serving)
|
|
158
|
+
view.narrow(next);
|
|
159
|
+
},
|
|
160
|
+
};
|
|
174
161
|
}
|
|
175
162
|
return {
|
|
176
163
|
attach,
|
|
177
|
-
|
|
178
|
-
if (!authorized)
|
|
179
|
-
throw new Error(AUTHORIZATION_ENDED);
|
|
180
|
-
deploymentFacts = structuredClone(value);
|
|
181
|
-
for (const deliver of factsObservers)
|
|
182
|
-
deliver(structuredClone(deploymentFacts));
|
|
183
|
-
},
|
|
184
|
-
async endAuthorization() {
|
|
164
|
+
async endAuthorization(holder) {
|
|
185
165
|
authorized = false;
|
|
186
166
|
for (const [detach, send] of [...attachments]) {
|
|
187
167
|
send({ kind: 'ended' });
|
|
188
168
|
detach();
|
|
189
169
|
}
|
|
190
170
|
close();
|
|
191
|
-
await removeRuntimeStore()
|
|
192
|
-
|
|
171
|
+
if (!(await removeRuntimeStore(holder)))
|
|
172
|
+
await options.shell.dropGeneration();
|
|
193
173
|
},
|
|
194
174
|
stop() {
|
|
195
175
|
return runtime.stop();
|
|
196
176
|
},
|
|
197
177
|
};
|
|
198
178
|
}
|
|
179
|
+
export { AUTHORED_SCHEMA, authoredBy, authoredHolder, STORE_SCHEMA } from './store.js';
|
package/dist/identity.d.ts
CHANGED
|
@@ -1,3 +1,6 @@
|
|
|
1
1
|
export declare function changeBatchIdentity(at?: number): string;
|
|
2
2
|
export declare function roomDraftRevision(): string;
|
|
3
|
+
export declare function chatDraftRevision(): string;
|
|
4
|
+
export declare function transferIdentity(): string;
|
|
5
|
+
export declare function binaryLocalId(): string;
|
|
3
6
|
//# sourceMappingURL=identity.d.ts.map
|
package/dist/identity.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"identity.d.ts","sourceRoot":"","sources":["../src/identity.ts"],"names":[],"mappings":"AAAA,wBAAgB,mBAAmB,CAAC,EAAE,GAAE,MAAmB,GAAG,MAAM,CAWnE;AAED,wBAAgB,iBAAiB,IAAI,MAAM,
|
|
1
|
+
{"version":3,"file":"identity.d.ts","sourceRoot":"","sources":["../src/identity.ts"],"names":[],"mappings":"AAAA,wBAAgB,mBAAmB,CAAC,EAAE,GAAE,MAAmB,GAAG,MAAM,CAWnE;AAQD,wBAAgB,iBAAiB,IAAI,MAAM,CAE1C;AAED,wBAAgB,iBAAiB,IAAI,MAAM,CAE1C;AAED,wBAAgB,gBAAgB,IAAI,MAAM,CAEzC;AAED,wBAAgB,aAAa,IAAI,MAAM,CAEtC"}
|
package/dist/identity.js
CHANGED
|
@@ -10,8 +10,20 @@ export function changeBatchIdentity(at = Date.now()) {
|
|
|
10
10
|
const hex = [...bytes].map((byte) => byte.toString(16).padStart(2, '0')).join('');
|
|
11
11
|
return `${hex.slice(0, 8)}-${hex.slice(8, 12)}-${hex.slice(12, 16)}-${hex.slice(16, 20)}-${hex.slice(20)}`;
|
|
12
12
|
}
|
|
13
|
-
|
|
13
|
+
function randomIdentity() {
|
|
14
14
|
const bytes = new Uint8Array(16);
|
|
15
15
|
crypto.getRandomValues(bytes);
|
|
16
16
|
return [...bytes].map((byte) => byte.toString(16).padStart(2, '0')).join('');
|
|
17
17
|
}
|
|
18
|
+
export function roomDraftRevision() {
|
|
19
|
+
return randomIdentity();
|
|
20
|
+
}
|
|
21
|
+
export function chatDraftRevision() {
|
|
22
|
+
return randomIdentity();
|
|
23
|
+
}
|
|
24
|
+
export function transferIdentity() {
|
|
25
|
+
return randomIdentity();
|
|
26
|
+
}
|
|
27
|
+
export function binaryLocalId() {
|
|
28
|
+
return randomIdentity();
|
|
29
|
+
}
|
package/dist/index.d.ts
CHANGED
|
@@ -1,15 +1,19 @@
|
|
|
1
|
-
export type { AcceptedMessage, ActionDeclaration, ActionRequest, ActionResult, Adapter, AdapterFailure, Authorization, BootstrapPage, BootstrapRequest, BootstrapResult, Capability, ChangeAuthor, ContractUnavailable, ConversationAction,
|
|
1
|
+
export type { AcceptedMessage, ActionDeclaration, ActionRequest, ActionResult, Adapter, AdapterFailure, Authorization, BinaryFile, BinaryRequest, BinaryResult, ReferrerScope, BootstrapPage, BootstrapRequest, BootstrapResult, Capability, ChangeAuthor, ContractUnavailable, ConversationAction, ConversationAgents, ConversationEvent, ConversationHistories, ConversationHistoryPage, ConversationHistoryRequest, ConversationMessage, ConversationStream, DiscoverResult, DiscoveredRoom, Discovery, HistoryAuthor, HistoryRequest, HistoryResult, HistoryRetention, HistoryRevision, HeldRoom, ListedConversation, MdModelIdentity, Member, MutationRequest, MutationResult, PageToken, ProviderLimit, ProviderRefusal, RefreshPage, RefreshRequest, RefreshResult, Retention, RetryableRefusal, RevokedAuthorization, RoomModels, RoomNotReadable, RoomStream, RoomStreamEvent, RoomVersionAt, ServiceMode, ServiceModeSignal, TransportUncertainty, TurnContext, TurnOperation, TypedSelection, } from './adapter.js';
|
|
2
2
|
export type { Change, ChangeBatch, Precondition, WrittenBy } from './change.js';
|
|
3
|
-
export type { ChatDraft, ChatDraftSurface, ConversationEntry, ConversationOptions, ConversationSurface, ConversationView,
|
|
3
|
+
export type { ChatDraft, ChatDraftSurface, ConversationAgent, ConversationEntry, ConversationOptions, ConversationState, ConversationSurface, ConversationView, RunningTurn, } from './conversation.js';
|
|
4
4
|
export type { ChatDraftFile, FileDeclaration } from './file.js';
|
|
5
|
-
export type { AppRoom,
|
|
5
|
+
export type { AppRoom, AppTypedSelection, BinaryFileSurface, ConnectionRefusal, ConnectionRefusalCode, HistoryQuery, MdRuntime, MdRuntimeOptions, PresentationSurface, RoomDraftSurface, RoomSchemas, SavedRoomDraft, SaveResult, } from './connection.js';
|
|
6
6
|
export type { Observation } from './observation.js';
|
|
7
|
-
export type {
|
|
7
|
+
export type { BinaryAnswer, CallResult, Failure, HistoryAnswer, QueueEntry, Submission, } from './outcome.js';
|
|
8
|
+
export type { BinaryFileRecord, BinaryReference } from './binary.js';
|
|
9
|
+
export type { RuntimeError } from './failure.js';
|
|
8
10
|
export type { ChangedPart, FieldValue, ReturnReason, RoomDraft, RoomDraftCreation, RoomDraftParts, RoomDraftWrite, } from './room-draft.js';
|
|
9
11
|
export type { SaveRefusal } from './save.js';
|
|
10
12
|
export type { DocumentHit, DocumentPart, MessageHit, SearchRequest, SearchResult, } from './search.js';
|
|
13
|
+
export { departure } from './change.js';
|
|
11
14
|
export { changeBatchIdentity } from './identity.js';
|
|
12
|
-
export {
|
|
15
|
+
export { attempts, identities, intentOf, type Answered, type Attempt, type Attempts, type Identities, } from './attempt.js';
|
|
16
|
+
export { expectedList, expecting, type ExpectedOf, type Expecting } from './expectation.js';
|
|
13
17
|
export type { RuntimeShell } from './durability.js';
|
|
14
18
|
export type { AttentionEntry, SyncStatus } from './status.js';
|
|
15
19
|
export type { Backlink, Direction, DocumentQuery, DocumentResult, Filter, GroupQuery, GroupResult, Key, LocalQuery, OrderOptions, Predicate, QueryDocument, QueryGroup, QueryResult, Related, Select, Value, Where, } from './query.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,iBAAiB,EACjB,aAAa,EACb,YAAY,EACZ,OAAO,EACP,cAAc,EACd,aAAa,EACb,aAAa,EACb,gBAAgB,EAChB,eAAe,EACf,UAAU,EACV,YAAY,EACZ,mBAAmB,EACnB,kBAAkB,EAClB,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"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"}
|
package/dist/index.js
CHANGED
|
@@ -1,2 +1,4 @@
|
|
|
1
|
+
export { departure } from './change.js';
|
|
1
2
|
export { changeBatchIdentity } from './identity.js';
|
|
2
|
-
export {
|
|
3
|
+
export { attempts, identities, intentOf, } from './attempt.js';
|
|
4
|
+
export { expectedList, expecting } from './expectation.js';
|