@acquiredintelligence/attend 0.0.0-stage → 0.2.0
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/LICENSE +21 -0
- package/README.md +174 -2
- package/dist/attend.d.ts +30 -0
- package/dist/attend.d.ts.map +1 -0
- package/dist/attend.js +464 -0
- package/dist/attend.js.map +1 -0
- package/dist/cli.d.ts +3 -0
- package/dist/cli.d.ts.map +1 -0
- package/dist/cli.js +4 -0
- package/dist/cli.js.map +1 -0
- package/dist/core/ids.d.ts +12 -0
- package/dist/core/ids.d.ts.map +1 -0
- package/dist/core/ids.js +97 -0
- package/dist/core/ids.js.map +1 -0
- package/dist/core/reducer.d.ts +26 -0
- package/dist/core/reducer.d.ts.map +1 -0
- package/dist/core/reducer.js +437 -0
- package/dist/core/reducer.js.map +1 -0
- package/dist/core/seen.d.ts +22 -0
- package/dist/core/seen.d.ts.map +1 -0
- package/dist/core/seen.js +61 -0
- package/dist/core/seen.js.map +1 -0
- package/dist/core/state.d.ts +12 -0
- package/dist/core/state.d.ts.map +1 -0
- package/dist/core/state.js +90 -0
- package/dist/core/state.js.map +1 -0
- package/dist/core/step.d.ts +14 -0
- package/dist/core/step.d.ts.map +1 -0
- package/dist/core/step.js +17 -0
- package/dist/core/step.js.map +1 -0
- package/dist/core/threshold.d.ts +40 -0
- package/dist/core/threshold.d.ts.map +1 -0
- package/dist/core/threshold.js +72 -0
- package/dist/core/threshold.js.map +1 -0
- package/dist/core/types.d.ts +704 -0
- package/dist/core/types.d.ts.map +1 -0
- package/dist/core/types.js +24 -0
- package/dist/core/types.js.map +1 -0
- package/dist/core/window.d.ts +38 -0
- package/dist/core/window.d.ts.map +1 -0
- package/dist/core/window.js +322 -0
- package/dist/core/window.js.map +1 -0
- package/dist/decisions.d.ts +53 -0
- package/dist/decisions.d.ts.map +1 -0
- package/dist/decisions.js +115 -0
- package/dist/decisions.js.map +1 -0
- package/dist/errors.d.ts +36 -0
- package/dist/errors.d.ts.map +1 -0
- package/dist/errors.js +53 -0
- package/dist/errors.js.map +1 -0
- package/dist/index.d.ts +10 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +4 -0
- package/dist/index.js.map +1 -0
- package/dist/internal/adapter.d.ts +21 -0
- package/dist/internal/adapter.d.ts.map +1 -0
- package/dist/internal/adapter.js +62 -0
- package/dist/internal/adapter.js.map +1 -0
- package/dist/internal/assert.d.ts +5 -0
- package/dist/internal/assert.d.ts.map +1 -0
- package/dist/internal/assert.js +14 -0
- package/dist/internal/assert.js.map +1 -0
- package/dist/internal/clock.d.ts +8 -0
- package/dist/internal/clock.d.ts.map +1 -0
- package/dist/internal/clock.js +38 -0
- package/dist/internal/clock.js.map +1 -0
- package/dist/internal/http.d.ts +42 -0
- package/dist/internal/http.d.ts.map +1 -0
- package/dist/internal/http.js +122 -0
- package/dist/internal/http.js.map +1 -0
- package/dist/internal/images.d.ts +18 -0
- package/dist/internal/images.d.ts.map +1 -0
- package/dist/internal/images.js +75 -0
- package/dist/internal/images.js.map +1 -0
- package/dist/internal/json.d.ts +3 -0
- package/dist/internal/json.d.ts.map +1 -0
- package/dist/internal/json.js +5 -0
- package/dist/internal/json.js.map +1 -0
- package/dist/internal/prompt.d.ts +31 -0
- package/dist/internal/prompt.d.ts.map +1 -0
- package/dist/internal/prompt.js +149 -0
- package/dist/internal/prompt.js.map +1 -0
- package/dist/internal/shared.d.ts +12 -0
- package/dist/internal/shared.d.ts.map +1 -0
- package/dist/internal/shared.js +138 -0
- package/dist/internal/shared.js.map +1 -0
- package/dist/jev.d.ts +74 -0
- package/dist/jev.d.ts.map +1 -0
- package/dist/jev.js +156 -0
- package/dist/jev.js.map +1 -0
- package/dist/llm.d.ts +164 -0
- package/dist/llm.d.ts.map +1 -0
- package/dist/llm.js +79 -0
- package/dist/llm.js.map +1 -0
- package/dist/mcp.d.ts +130 -0
- package/dist/mcp.d.ts.map +1 -0
- package/dist/mcp.js +550 -0
- package/dist/mcp.js.map +1 -0
- package/dist/memory.d.ts +10 -0
- package/dist/memory.d.ts.map +1 -0
- package/dist/memory.js +50 -0
- package/dist/memory.js.map +1 -0
- package/dist/postgres.d.ts +25 -0
- package/dist/postgres.d.ts.map +1 -0
- package/dist/postgres.js +56 -0
- package/dist/postgres.js.map +1 -0
- package/dist/redis.d.ts +20 -0
- package/dist/redis.d.ts.map +1 -0
- package/dist/redis.js +83 -0
- package/dist/redis.js.map +1 -0
- package/dist/server/compat.d.ts +13 -0
- package/dist/server/compat.d.ts.map +1 -0
- package/dist/server/compat.js +5 -0
- package/dist/server/compat.js.map +1 -0
- package/dist/server/cursor.d.ts +15 -0
- package/dist/server/cursor.d.ts.map +1 -0
- package/dist/server/cursor.js +50 -0
- package/dist/server/cursor.js.map +1 -0
- package/dist/server/events.d.ts +42 -0
- package/dist/server/events.d.ts.map +1 -0
- package/dist/server/events.js +189 -0
- package/dist/server/events.js.map +1 -0
- package/dist/server/fanout.d.ts +28 -0
- package/dist/server/fanout.d.ts.map +1 -0
- package/dist/server/fanout.js +184 -0
- package/dist/server/fanout.js.map +1 -0
- package/dist/server/guard.d.ts +19 -0
- package/dist/server/guard.d.ts.map +1 -0
- package/dist/server/guard.js +27 -0
- package/dist/server/guard.js.map +1 -0
- package/dist/server/http.d.ts +4 -0
- package/dist/server/http.d.ts.map +1 -0
- package/dist/server/http.js +323 -0
- package/dist/server/http.js.map +1 -0
- package/dist/server/ingest.d.ts +4 -0
- package/dist/server/ingest.d.ts.map +1 -0
- package/dist/server/ingest.js +400 -0
- package/dist/server/ingest.js.map +1 -0
- package/dist/server/install.d.ts +5 -0
- package/dist/server/install.d.ts.map +1 -0
- package/dist/server/install.js +91 -0
- package/dist/server/install.js.map +1 -0
- package/dist/server/poll.d.ts +4 -0
- package/dist/server/poll.d.ts.map +1 -0
- package/dist/server/poll.js +45 -0
- package/dist/server/poll.js.map +1 -0
- package/dist/server/serve.d.ts +19 -0
- package/dist/server/serve.d.ts.map +1 -0
- package/dist/server/serve.js +238 -0
- package/dist/server/serve.js.map +1 -0
- package/dist/server/sessions.d.ts +14 -0
- package/dist/server/sessions.d.ts.map +1 -0
- package/dist/server/sessions.js +54 -0
- package/dist/server/sessions.js.map +1 -0
- package/dist/server/stream.d.ts +11 -0
- package/dist/server/stream.d.ts.map +1 -0
- package/dist/server/stream.js +216 -0
- package/dist/server/stream.js.map +1 -0
- package/dist/server/tools.d.ts +22 -0
- package/dist/server/tools.d.ts.map +1 -0
- package/dist/server/tools.js +55 -0
- package/dist/server/tools.js.map +1 -0
- package/dist/server/types.d.ts +351 -0
- package/dist/server/types.d.ts.map +1 -0
- package/dist/server/types.js +5 -0
- package/dist/server/types.js.map +1 -0
- package/dist/server.d.ts +11 -0
- package/dist/server.d.ts.map +1 -0
- package/dist/server.js +10 -0
- package/dist/server.js.map +1 -0
- package/dist/shell/budget.d.ts +4 -0
- package/dist/shell/budget.d.ts.map +1 -0
- package/dist/shell/budget.js +5 -0
- package/dist/shell/budget.js.map +1 -0
- package/dist/shell/copy.d.ts +20 -0
- package/dist/shell/copy.d.ts.map +1 -0
- package/dist/shell/copy.js +73 -0
- package/dist/shell/copy.js.map +1 -0
- package/dist/shell/decisions.d.ts +6 -0
- package/dist/shell/decisions.d.ts.map +1 -0
- package/dist/shell/decisions.js +42 -0
- package/dist/shell/decisions.js.map +1 -0
- package/dist/shell/read.d.ts +7 -0
- package/dist/shell/read.d.ts.map +1 -0
- package/dist/shell/read.js +21 -0
- package/dist/shell/read.js.map +1 -0
- package/dist/shell/scheduler.d.ts +4 -0
- package/dist/shell/scheduler.d.ts.map +1 -0
- package/dist/shell/scheduler.js +90 -0
- package/dist/shell/scheduler.js.map +1 -0
- package/dist/shell/scope.d.ts +27 -0
- package/dist/shell/scope.d.ts.map +1 -0
- package/dist/shell/scope.js +343 -0
- package/dist/shell/scope.js.map +1 -0
- package/dist/shell/types.d.ts +168 -0
- package/dist/shell/types.d.ts.map +1 -0
- package/dist/shell/types.js +2 -0
- package/dist/shell/types.js.map +1 -0
- package/dist/sqlite.d.ts +14 -0
- package/dist/sqlite.d.ts.map +1 -0
- package/dist/sqlite.js +39 -0
- package/dist/sqlite.js.map +1 -0
- package/dist/step.d.ts +18 -0
- package/dist/step.d.ts.map +1 -0
- package/dist/step.js +14 -0
- package/dist/step.js.map +1 -0
- package/dist/store/memory.d.ts +12 -0
- package/dist/store/memory.d.ts.map +1 -0
- package/dist/store/memory.js +264 -0
- package/dist/store/memory.js.map +1 -0
- package/dist/store/postgres.d.ts +24 -0
- package/dist/store/postgres.d.ts.map +1 -0
- package/dist/store/postgres.js +364 -0
- package/dist/store/postgres.js.map +1 -0
- package/dist/store/redis.d.ts +12 -0
- package/dist/store/redis.d.ts.map +1 -0
- package/dist/store/redis.js +540 -0
- package/dist/store/redis.js.map +1 -0
- package/dist/store/sqlite-worker.d.ts +91 -0
- package/dist/store/sqlite-worker.d.ts.map +1 -0
- package/dist/store/sqlite-worker.js +322 -0
- package/dist/store/sqlite-worker.js.map +1 -0
- package/dist/store/sqlite.d.ts +34 -0
- package/dist/store/sqlite.d.ts.map +1 -0
- package/dist/store/sqlite.js +238 -0
- package/dist/store/sqlite.js.map +1 -0
- package/dist/store/types.d.ts +137 -0
- package/dist/store/types.d.ts.map +1 -0
- package/dist/store/types.js +2 -0
- package/dist/store/types.js.map +1 -0
- package/dist/testing/conformance.d.ts +13 -0
- package/dist/testing/conformance.d.ts.map +1 -0
- package/dist/testing/conformance.js +542 -0
- package/dist/testing/conformance.js.map +1 -0
- package/dist/testing/wire.d.ts +16 -0
- package/dist/testing/wire.d.ts.map +1 -0
- package/dist/testing/wire.js +304 -0
- package/dist/testing/wire.js.map +1 -0
- package/dist/testing.d.ts +113 -0
- package/dist/testing.d.ts.map +1 -0
- package/dist/testing.js +655 -0
- package/dist/testing.js.map +1 -0
- package/dist/types.d.ts +5 -0
- package/dist/types.d.ts.map +1 -0
- package/dist/types.js +5 -0
- package/dist/types.js.map +1 -0
- package/package.json +130 -4
- package/skills/attend/SKILL.md +231 -0
- package/skills/attend/references/judges.md +283 -0
- package/skills/attend/references/kinds.md +62 -0
- package/skills/attend/references/mcp.md +132 -0
- package/skills/attend/references/sinks.md +73 -0
- package/skills/attend/references/stores.md +90 -0
- package/skills/attend/references/testing.md +120 -0
|
@@ -0,0 +1,137 @@
|
|
|
1
|
+
import type { DecisionAppend, DeliveredRoute, LoggedInput, ScopeRecord, SettlePolicy } from '../core/types.js';
|
|
2
|
+
/** A snapshot is a ScopeRecord plus what replay needs: the policy and the reducer version it was taken under. */
|
|
3
|
+
export interface Snapshot {
|
|
4
|
+
version: number;
|
|
5
|
+
record: ScopeRecord;
|
|
6
|
+
policy: SettlePolicy;
|
|
7
|
+
reducer: number;
|
|
8
|
+
}
|
|
9
|
+
/** A scope as stored: the latest snapshot and every input committed after it, oldest first. */
|
|
10
|
+
export interface StoredScope {
|
|
11
|
+
version: number;
|
|
12
|
+
snapshot: Snapshot | null;
|
|
13
|
+
tail: readonly LoggedInput[];
|
|
14
|
+
}
|
|
15
|
+
/**
|
|
16
|
+
* One scope's part of a group commit. It applies iff the stored version equals
|
|
17
|
+
* `expectedVersion`; 0 means no stored scope. On success the stored version becomes
|
|
18
|
+
* `expectedVersion + inputs.length`. A snapshot is always taken at the write's final version: it
|
|
19
|
+
* replaces the stored one and trims every input at or below its version, so an adapter writes no
|
|
20
|
+
* input rows for a write that carries one. Everything in one write lands together or not at all.
|
|
21
|
+
*/
|
|
22
|
+
export interface ScopeWrite {
|
|
23
|
+
scope: string;
|
|
24
|
+
expectedVersion: number;
|
|
25
|
+
inputs: readonly LoggedInput[];
|
|
26
|
+
snapshot: Snapshot | null;
|
|
27
|
+
/** The coarse due value, already rounded up to the second by the shell, and stored as given. Undefined: unchanged. Null: clear it. */
|
|
28
|
+
due?: number | null;
|
|
29
|
+
appends: readonly DecisionAppend[];
|
|
30
|
+
serialized?: SerializedWrite;
|
|
31
|
+
}
|
|
32
|
+
/**
|
|
33
|
+
* The JSON of a write's pieces, made when each piece was produced, so a group commit only binds
|
|
34
|
+
* strings. `inputs[i]` is `JSON.stringify(write.inputs[i])`; `snapshot` is
|
|
35
|
+
* `JSON.stringify(write.snapshot.record)`, or null without a snapshot; `appends[i]` is
|
|
36
|
+
* `JSON.stringify(write.appends[i].body)`. The shell sets it on every write to a durable store,
|
|
37
|
+
* and the memory store ignores it.
|
|
38
|
+
*/
|
|
39
|
+
export interface SerializedWrite {
|
|
40
|
+
inputs: string[];
|
|
41
|
+
snapshot: string | null;
|
|
42
|
+
appends: string[];
|
|
43
|
+
}
|
|
44
|
+
export type CommitOutcome = 'ok' | 'conflict';
|
|
45
|
+
/** A keyset position in the due index: ascending by `due`, then `scope`. */
|
|
46
|
+
export interface DueKey {
|
|
47
|
+
due: number;
|
|
48
|
+
scope: string;
|
|
49
|
+
}
|
|
50
|
+
/**
|
|
51
|
+
* The store port. `commit` resolves once the group is durable, with one outcome per write, in
|
|
52
|
+
* order. Writes for different scopes are independent: a conflict changes nothing for its scope,
|
|
53
|
+
* and the others commit. A group that names one scope twice rejects. A rejected `commit` applied
|
|
54
|
+
* nothing. Every value a store returns is plain, cloneable data that it never changes afterwards,
|
|
55
|
+
* and a store never changes the writes or queries it is given. Proven by `scopeStoreConformance`
|
|
56
|
+
* and `decisionLogConformance`.
|
|
57
|
+
*/
|
|
58
|
+
export interface ScopeStore {
|
|
59
|
+
/** False for the memory store: snapshots and inputs survive the instance, not the process. */
|
|
60
|
+
readonly durable: boolean;
|
|
61
|
+
load(scope: string): Promise<StoredScope | null>;
|
|
62
|
+
commit(writes: readonly ScopeWrite[]): Promise<readonly CommitOutcome[]>;
|
|
63
|
+
/** Scopes whose due value is <= now, ascending by (due, scope), strictly after `after`, at most `limit`. A read, not a claim. */
|
|
64
|
+
due(now: number, limit: number, after?: DueKey): Promise<DueKey[]>;
|
|
65
|
+
/** Forgets the scope: a later load is null, it is no longer due, and a commit at version 0 succeeds. */
|
|
66
|
+
remove(scope: string): Promise<void>;
|
|
67
|
+
readonly log: DecisionLog;
|
|
68
|
+
/** Releases what the store itself opened, such as a worker. Never closes a client the app passed in. */
|
|
69
|
+
close?(): Promise<void>;
|
|
70
|
+
}
|
|
71
|
+
/** Opaque, and ordered by `DecisionLog.compare`: a memory sequence number, a SQLite rowid, a Postgres `txid.n`, a Redis stream id. */
|
|
72
|
+
export type Position = string;
|
|
73
|
+
export type DecisionKind = DecisionAppend['kind'];
|
|
74
|
+
export type DecisionRow = DecisionAppend & {
|
|
75
|
+
position: Position;
|
|
76
|
+
};
|
|
77
|
+
export interface DecisionQuery {
|
|
78
|
+
/** Strictly after this position; null starts from the oldest retained row. */
|
|
79
|
+
after: Position | null;
|
|
80
|
+
/** Only this scope. Rows of other scopes are never examined. */
|
|
81
|
+
scope?: string;
|
|
82
|
+
/** Scopes that start with this. Like `kinds` and `routes`, every row examined counts toward `scanLimit`. */
|
|
83
|
+
scopePrefix?: string;
|
|
84
|
+
kinds?: readonly DecisionKind[];
|
|
85
|
+
/** Rows whose route is one of these. A row with a null route never matches. */
|
|
86
|
+
routes?: readonly DeliveredRoute[];
|
|
87
|
+
/** Skip rows decided before this instant. */
|
|
88
|
+
sinceAt?: number;
|
|
89
|
+
limit: number;
|
|
90
|
+
/** Rows examined before stopping with `more: true`. Default 4 × `limit`. */
|
|
91
|
+
scanLimit?: number;
|
|
92
|
+
}
|
|
93
|
+
export interface DecisionPage {
|
|
94
|
+
/** Matching rows, oldest first. */
|
|
95
|
+
rows: DecisionRow[];
|
|
96
|
+
/**
|
|
97
|
+
* The position checked up to, whether or not anything matched: the cursor to hand out. When
|
|
98
|
+
* `more` is false it is the head the read saw (never behind `after`, and null on an empty log).
|
|
99
|
+
* When `more` is true it is the last row examined, so reading on from it skips nothing.
|
|
100
|
+
*/
|
|
101
|
+
checked: Position | null;
|
|
102
|
+
/** True when the read stopped at `limit` or `scanLimit` with rows left past `checked`; false when it reached the head. */
|
|
103
|
+
more: boolean;
|
|
104
|
+
}
|
|
105
|
+
export interface LogBounds {
|
|
106
|
+
/** The retention floor: the oldest readable position. */
|
|
107
|
+
first: Position | null;
|
|
108
|
+
/** The head: the newest readable position. */
|
|
109
|
+
last: Position | null;
|
|
110
|
+
}
|
|
111
|
+
export interface Retention {
|
|
112
|
+
olderThanMs?: number;
|
|
113
|
+
maxRows?: number;
|
|
114
|
+
}
|
|
115
|
+
/**
|
|
116
|
+
* Decisions and dead letters in one total order per store, written only by `ScopeStore.commit`
|
|
117
|
+
* in the same commit as the input that produced them. An append whose (kind, id) is already
|
|
118
|
+
* logged is skipped, and its write still commits. A reader never sees a row appear below a
|
|
119
|
+
* position it has already read.
|
|
120
|
+
*/
|
|
121
|
+
export interface DecisionLog {
|
|
122
|
+
/** Names the log's incarnation: random per instance for memory, persistent for durable stores. */
|
|
123
|
+
epoch(): Promise<string>;
|
|
124
|
+
bounds(): Promise<LogBounds>;
|
|
125
|
+
read(query: DecisionQuery): Promise<DecisionPage>;
|
|
126
|
+
find(kind: DecisionKind, id: string): Promise<DecisionRow | null>;
|
|
127
|
+
/** Resolves when the head passes `after`, after `blockMs`, or on abort. Never rejects. */
|
|
128
|
+
wait(after: Position | null, blockMs: number, signal: AbortSignal): Promise<void>;
|
|
129
|
+
/**
|
|
130
|
+
* Drops rows from the oldest end: keeps at most `maxRows` newest rows, and drops leading rows
|
|
131
|
+
* whose `at` is older than `Date.now() - olderThanMs`. Never drops the head.
|
|
132
|
+
*/
|
|
133
|
+
trim(retention: Retention): Promise<void>;
|
|
134
|
+
/** Negative, zero or positive, as `a` comes before, equals or follows `b`. */
|
|
135
|
+
compare(a: Position, b: Position): number;
|
|
136
|
+
}
|
|
137
|
+
//# sourceMappingURL=types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/store/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,cAAc,EAAE,WAAW,EAAE,WAAW,EAAE,YAAY,EAAE,MAAM,kBAAkB,CAAC;AAE/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IACxB,yDAAyD;IACzD,KAAK,EAAE,QAAQ,GAAG,IAAI,CAAC;IACvB,8CAA8C;IAC9C,IAAI,EAAE,QAAQ,GAAG,IAAI,CAAC;CACvB;AAED,MAAM,WAAW,SAAS;IACxB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,OAAO,CAAC,EAAE,MAAM,CAAC;CAClB;AAED;;;;;GAKG;AACH,MAAM,WAAW,WAAW;IAC1B,kGAAkG;IAClG,KAAK,IAAI,OAAO,CAAC,MAAM,CAAC,CAAC;IACzB,MAAM,IAAI,OAAO,CAAC,SAAS,CAAC,CAAC;IAC7B,IAAI,CAAC,KAAK,EAAE,aAAa,GAAG,OAAO,CAAC,YAAY,CAAC,CAAC;IAClD,IAAI,CAAC,IAAI,EAAE,YAAY,EAAE,EAAE,EAAE,MAAM,GAAG,OAAO,CAAC,WAAW,GAAG,IAAI,CAAC,CAAC;IAClE,0FAA0F;IAC1F,IAAI,CAAC,KAAK,EAAE,QAAQ,GAAG,IAAI,EAAE,OAAO,EAAE,MAAM,EAAE,MAAM,EAAE,WAAW,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IAClF;;;OAGG;IACH,IAAI,CAAC,SAAS,EAAE,SAAS,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IAC1C,8EAA8E;IAC9E,OAAO,CAAC,CAAC,EAAE,QAAQ,EAAE,CAAC,EAAE,QAAQ,GAAG,MAAM,CAAC;CAC3C"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../src/store/types.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import type { ConformanceCase } from '../testing.js';
|
|
2
|
+
import type { ScopeStore } from '../store/types.js';
|
|
3
|
+
/** Every guarantee in ScopeStore's doc comments, as cases. `make` returns a fresh, empty store per case. */
|
|
4
|
+
export declare function scopeStoreConformance(make: () => Promise<ScopeStore> | ScopeStore): ConformanceCase[];
|
|
5
|
+
/**
|
|
6
|
+
* Every guarantee in DecisionLog's doc comments. With `concurrent`, which returns two stores over
|
|
7
|
+
* one database, it also checks that a reader never skips a row while two writers commit at once,
|
|
8
|
+
* and that durable stores share an epoch.
|
|
9
|
+
*/
|
|
10
|
+
export declare function decisionLogConformance(make: () => Promise<ScopeStore> | ScopeStore, options?: {
|
|
11
|
+
concurrent?: () => Promise<[ScopeStore, ScopeStore]>;
|
|
12
|
+
}): ConformanceCase[];
|
|
13
|
+
//# sourceMappingURL=conformance.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"conformance.d.ts","sourceRoot":"","sources":["../../src/testing/conformance.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,eAAe,CAAC;AAGrD,OAAO,KAAK,EAAwC,UAAU,EAAwB,MAAM,mBAAmB,CAAC;AA4HhH,4GAA4G;AAC5G,wBAAgB,qBAAqB,CAAC,IAAI,EAAE,MAAM,OAAO,CAAC,UAAU,CAAC,GAAG,UAAU,GAAG,eAAe,EAAE,CAkLrG;AA4BD;;;;GAIG;AACH,wBAAgB,sBAAsB,CAAC,IAAI,EAAE,MAAM,OAAO,CAAC,UAAU,CAAC,GAAG,UAAU,EAAE,OAAO,CAAC,EAAE;IAAE,UAAU,CAAC,EAAE,MAAM,OAAO,CAAC,CAAC,UAAU,EAAE,UAAU,CAAC,CAAC,CAAA;CAAE,GAAG,eAAe,EAAE,CA2M1K"}
|