@elaraai/e3-types 1.0.77 → 1.0.79

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.
Files changed (41) hide show
  1. package/dist/src/dataflow.d.ts +10 -6
  2. package/dist/src/dataflow.d.ts.map +1 -1
  3. package/dist/src/dataflow.js.map +1 -1
  4. package/dist/src/execution.d.ts +17 -0
  5. package/dist/src/execution.d.ts.map +1 -1
  6. package/dist/src/index.d.ts +4 -3
  7. package/dist/src/index.d.ts.map +1 -1
  8. package/dist/src/index.js +4 -2
  9. package/dist/src/index.js.map +1 -1
  10. package/dist/src/runner.d.ts +35 -9
  11. package/dist/src/runner.d.ts.map +1 -1
  12. package/dist/src/runner.js +46 -13
  13. package/dist/src/runner.js.map +1 -1
  14. package/dist/src/runner.spec.js +50 -1
  15. package/dist/src/runner.spec.js.map +1 -1
  16. package/dist/src/stream.d.ts +97 -0
  17. package/dist/src/stream.d.ts.map +1 -0
  18. package/dist/src/stream.js +134 -0
  19. package/dist/src/stream.js.map +1 -0
  20. package/dist/src/stream.spec.d.ts +6 -0
  21. package/dist/src/stream.spec.d.ts.map +1 -0
  22. package/dist/src/stream.spec.js +60 -0
  23. package/dist/src/stream.spec.js.map +1 -0
  24. package/dist/src/task.d.ts +183 -17
  25. package/dist/src/task.d.ts.map +1 -1
  26. package/dist/src/task.js +302 -20
  27. package/dist/src/task.js.map +1 -1
  28. package/dist/src/task.spec.d.ts +6 -0
  29. package/dist/src/task.spec.d.ts.map +1 -0
  30. package/dist/src/task.spec.js +169 -0
  31. package/dist/src/task.spec.js.map +1 -0
  32. package/package.json +2 -2
  33. package/src/dataflow.ts +10 -6
  34. package/src/execution.ts +18 -0
  35. package/src/index.ts +21 -0
  36. package/src/runner.spec.ts +56 -1
  37. package/src/runner.ts +45 -13
  38. package/src/stream.spec.ts +88 -0
  39. package/src/stream.ts +170 -0
  40. package/src/task.spec.ts +208 -0
  41. package/src/task.ts +336 -21
@@ -0,0 +1,134 @@
1
+ /**
2
+ * Copyright (c) 2025 Elara AI Pty Ltd
3
+ * Dual-licensed under AGPL-3.0 and commercial license. See LICENSE for details.
4
+ */
5
+ /**
6
+ * The stream and merge commands (issue #770) — the builders of every argv a
7
+ * stream execution spawns (an authored `streamTask`'s) and of the merge
8
+ * command a partitioned task's keyed fan-in runs per key range, both built
9
+ * at export time and carried in the package like any other command IR.
10
+ */
11
+ import { ArrayType, East, StringType } from '@elaraai/east';
12
+ import { runnerToArgv } from './runner.js';
13
+ /**
14
+ * Builds the command IR of a stream execution: `(input_paths, output_path)
15
+ * -> argv`.
16
+ *
17
+ * The argv is `[...runner, '--emit', <emit>, '--merge' <merge IR path> |
18
+ * '--union', '--stream' '0' when the first -i input streams, '-i' <path> for
19
+ * each -i input, '-o', <output>, <body IR path>]` — the body IR is wire
20
+ * input 0, the merge IR wire input 1 in function mode, and the `-i` inputs
21
+ * follow. Built with `East.function` exactly as a task command is.
22
+ *
23
+ * @param runner - the stock runner the execution spawns
24
+ * @param spec - the emit kind, the merge mode and the streamed input
25
+ * @returns the command IR
26
+ *
27
+ * @example
28
+ * ```ts
29
+ * import { variant } from '@elaraai/east';
30
+ *
31
+ * const command = streamCommandIr(variant('east_c', { platforms: [] }), { emit: 'dict', merge: 'function', stream: 'first' });
32
+ * command.compile([])(['body.beast2', 'merge.beast2', 'a.beast2'], 'out.beast2');
33
+ * // ['east-c', 'run', '--emit', 'dict', '--merge', 'merge.beast2', '--stream', '0',
34
+ * // '-i', 'a.beast2', '-o', 'out.beast2', 'body.beast2']
35
+ * ```
36
+ */
37
+ export function streamCommandIr(runner, spec) {
38
+ const prefix = [
39
+ ...runnerToArgv(runner),
40
+ '--emit', spec.emit,
41
+ ...(spec.merge === 'union' ? ['--union'] : []),
42
+ ];
43
+ // The merge mode and the streamed input are known here, so the flags they
44
+ // add are emitted by branching at build time — only the merge IR's PATH is
45
+ // a run-time value, and only the -i inputs need a loop.
46
+ const mergeInput = spec.merge === 'function' ? 1n : null;
47
+ const firstInput = mergeInput === null ? 1n : 2n;
48
+ const command = East.function([ArrayType(StringType), StringType], ArrayType(StringType), ($, input_paths, output_path) => {
49
+ const argv = $.let(prefix, ArrayType(StringType));
50
+ if (mergeInput !== null) {
51
+ $(argv.pushLast('--merge'));
52
+ $(argv.pushLast(input_paths.get(mergeInput)));
53
+ }
54
+ if (spec.stream === 'first') {
55
+ $(argv.pushLast('--stream'));
56
+ $(argv.pushLast('0'));
57
+ }
58
+ const i = $.let(firstInput);
59
+ $.while(East.less(i, input_paths.size()), $ => {
60
+ $(argv.pushLast('-i'));
61
+ $(argv.pushLast(input_paths.get(i)));
62
+ $.assign(i, i.add(1n));
63
+ });
64
+ $(argv.pushLast('-o'));
65
+ $(argv.pushLast(output_path));
66
+ $(argv.pushLast(input_paths.get(0n)));
67
+ $.return(argv);
68
+ });
69
+ return command.toIR();
70
+ }
71
+ /**
72
+ * Builds the command IR of a merge execution — the runner's `merge` command
73
+ * over sorted partials of one Set or Dict type, within a key range:
74
+ * `(input_paths, output_path) -> argv`.
75
+ *
76
+ * The argv is `[...runner merge, '--merge' <merge IR path> | '--union',
77
+ * '--range' <range path>, '-i' <path> for each partial, '-o', <output>]`. In
78
+ * `function` mode wire input 0 is the merge IR `(K, V, V) -> V`, wire input
79
+ * 1 the key range and the partials follow; in `union` mode wire input 0 is
80
+ * the key range and every other wire input is a partial. The key range is a
81
+ * blob of `Struct{from: Option<K>, to: Option<K>}` over the output's key
82
+ * type: only the keys in `[from, to)` merge, each partial sought to the
83
+ * segment owning `from`, and an absent bound is open — a component that
84
+ * merges whole takes the open range. Equal keys across partials fold in
85
+ * input order, and the output is byte-identical to what the runner's emit
86
+ * sink writes for the same entries emitted ascending. A partitioned task's
87
+ * SDK writes this IR into its metadata at export, and the orchestrator runs
88
+ * it as an ordinary execution per key range of a group of partials.
89
+ *
90
+ * @param runner - the stock runner whose `merge` command runs
91
+ * @param mode - `function` (a Dict output, folded with the merge IR) or
92
+ * `union` (a Set output, the first of equal elements standing)
93
+ * @returns the command IR
94
+ * @throws {Error} When the runner is `custom` — it has no merge command.
95
+ *
96
+ * @example
97
+ * ```ts
98
+ * import { variant } from '@elaraai/east';
99
+ *
100
+ * const command = mergeCommandIr(variant('east_c', { platforms: [] }), 'function');
101
+ * command.compile([])(['merge.beast2', 'range.beast2', 'p0.beast2', 'p1.beast2'], 'out.beast2');
102
+ * // ['east-c', 'merge', '--merge', 'merge.beast2', '--range', 'range.beast2',
103
+ * // '-i', 'p0.beast2', '-i', 'p1.beast2', '-o', 'out.beast2']
104
+ * ```
105
+ */
106
+ export function mergeCommandIr(runner, mode) {
107
+ const prefix = [
108
+ ...runnerToArgv(runner, 'merge'),
109
+ ...(mode === 'union' ? ['--union'] : []),
110
+ ];
111
+ const mergeInput = mode === 'function' ? 0n : null;
112
+ const rangeInput = mergeInput === null ? 0n : 1n;
113
+ const firstInput = rangeInput + 1n;
114
+ const command = East.function([ArrayType(StringType), StringType], ArrayType(StringType), ($, input_paths, output_path) => {
115
+ const argv = $.let(prefix, ArrayType(StringType));
116
+ if (mergeInput !== null) {
117
+ $(argv.pushLast('--merge'));
118
+ $(argv.pushLast(input_paths.get(mergeInput)));
119
+ }
120
+ $(argv.pushLast('--range'));
121
+ $(argv.pushLast(input_paths.get(rangeInput)));
122
+ const i = $.let(firstInput);
123
+ $.while(East.less(i, input_paths.size()), $ => {
124
+ $(argv.pushLast('-i'));
125
+ $(argv.pushLast(input_paths.get(i)));
126
+ $.assign(i, i.add(1n));
127
+ });
128
+ $(argv.pushLast('-o'));
129
+ $(argv.pushLast(output_path));
130
+ $.return(argv);
131
+ });
132
+ return command.toIR();
133
+ }
134
+ //# sourceMappingURL=stream.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"stream.js","sourceRoot":"","sources":["../../src/stream.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH;;;;;GAKG;AAEH,OAAO,EAAE,SAAS,EAAE,IAAI,EAAU,UAAU,EAAE,MAAM,eAAe,CAAC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AAC,CAAC,MAAM,CAAC,CAAC,EAAE,CAAC,CAAC,GAAG,CAAC,EAAE,CAAC,CAAC,CAAC;QACzB,CAAC,CAAC,CAAC;QACH,CAAC,CAAC,IAAI,CAAC,QAAQ,CAAC,IAAI,CAAC,CAAC,CAAC;QACvB,CAAC,CAAC,IAAI,CAAC,QAAQ,CAAC,WAAW,CAAC,CAAC,CAAC;QAC9B,CAAC,CAAC,MAAM,CAAC,IAAI,CAAC,CAAC;IACjB,CAAC,CACF,CAAC;IACF,OAAO,OAAO,CAAC,IAAI,EAAE,CAAC;AACxB,CAAC"}
@@ -0,0 +1,6 @@
1
+ /**
2
+ * Copyright (c) 2025 Elara AI Pty Ltd
3
+ * Dual-licensed under AGPL-3.0 and commercial license. See LICENSE for details.
4
+ */
5
+ export {};
6
+ //# sourceMappingURL=stream.spec.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"stream.spec.d.ts","sourceRoot":"","sources":["../../src/stream.spec.ts"],"names":[],"mappings":"AAAA;;;GAGG"}
@@ -0,0 +1,60 @@
1
+ /**
2
+ * Copyright (c) 2025 Elara AI Pty Ltd
3
+ * Dual-licensed under AGPL-3.0 and commercial license. See LICENSE for details.
4
+ */
5
+ /**
6
+ * The stream and merge command builders (issue #770): the argv a stream
7
+ * execution spawns for each merge mode and streamed-input choice, and the
8
+ * argv a merge execution spawns over sorted partials within a key range.
9
+ */
10
+ import { describe, it } from 'node:test';
11
+ import assert from 'node:assert/strict';
12
+ import { variant } from '@elaraai/east';
13
+ import { mergeCommandIr, streamCommandIr } from './stream.js';
14
+ const EAST_C = variant('east_c', { platforms: ['east-c-std'] });
15
+ /** The argv a stream command evaluates to for the staged `inputs`. */
16
+ function argvOf(runner, spec, inputs) {
17
+ return streamCommandIr(runner, spec).compile([])(inputs, 'out.beast2');
18
+ }
19
+ /** The argv a merge command evaluates to for the staged `inputs`. */
20
+ function mergeArgvOf(runner, mode, inputs) {
21
+ return mergeCommandIr(runner, mode).compile([])(inputs, 'out.beast2');
22
+ }
23
+ describe('streamCommandIr', () => {
24
+ it('builds a folding dict argv: the merge IR as --merge, the first input streamed', () => {
25
+ assert.deepEqual(argvOf(EAST_C, { emit: 'dict', merge: 'function', stream: 'first' }, ['body.beast2', 'merge.beast2', 'rows.beast2', 'other.beast2']), ['east-c', 'run', '-p', 'east-c-std', '--emit', 'dict', '--merge', 'merge.beast2', '--stream', '0',
26
+ '-i', 'rows.beast2', '-i', 'other.beast2', '-o', 'out.beast2', 'body.beast2']);
27
+ });
28
+ it('builds a union set argv streaming the first input', () => {
29
+ assert.deepEqual(argvOf(EAST_C, { emit: 'set', merge: 'union', stream: 'first' }, ['body.beast2', 'stream.beast2', 'other.beast2']), ['east-c', 'run', '-p', 'east-c-std', '--emit', 'set', '--union', '--stream', '0',
30
+ '-i', 'stream.beast2', '-i', 'other.beast2', '-o', 'out.beast2', 'body.beast2']);
31
+ });
32
+ it('builds a producer argv with no merge flag and no streamed input', () => {
33
+ assert.deepEqual(argvOf(EAST_C, { emit: 'array', merge: 'none', stream: 'none' }, ['body.beast2', 'config.beast2']), ['east-c', 'run', '-p', 'east-c-std', '--emit', 'array', '-i', 'config.beast2', '-o', 'out.beast2', 'body.beast2']);
34
+ });
35
+ it('starts from the runner argv of every stock runtime', () => {
36
+ const node = variant('east_node', { platforms: ['@elaraai/east-node-std'] });
37
+ const argv = argvOf(node, { emit: 'set', merge: 'none', stream: 'first' }, ['body.beast2', 'rows.beast2']);
38
+ assert.deepEqual(argv.slice(0, 6), ['east-node', 'run', '-p', '@elaraai/east-node-std', '--emit', 'set']);
39
+ });
40
+ });
41
+ describe('mergeCommandIr', () => {
42
+ it('builds a dict merge argv: the merge IR as --merge, the key range as --range, every other input a partial', () => {
43
+ assert.deepEqual(mergeArgvOf(EAST_C, 'function', ['merge.beast2', 'range.beast2', 'p0.beast2', 'p1.beast2', 'p2.beast2']), ['east-c', 'merge', '-p', 'east-c-std', '--merge', 'merge.beast2', '--range', 'range.beast2',
44
+ '-i', 'p0.beast2', '-i', 'p1.beast2', '-i', 'p2.beast2', '-o', 'out.beast2']);
45
+ });
46
+ it('builds a set union argv: the key range first, every other input a partial', () => {
47
+ assert.deepEqual(mergeArgvOf(EAST_C, 'union', ['range.beast2', 'p0.beast2', 'p1.beast2']), ['east-c', 'merge', '-p', 'east-c-std', '--union', '--range', 'range.beast2', '-i', 'p0.beast2', '-i', 'p1.beast2', '-o', 'out.beast2']);
48
+ });
49
+ it('runs the merge command of every stock runtime', () => {
50
+ const py = variant('east_py', { platforms: ['east-py-std'] });
51
+ assert.deepEqual(mergeArgvOf(py, 'union', ['range.beast2', 'p0.beast2']).slice(0, 4), ['east-py', 'merge', '-p', 'east-py-std']);
52
+ const node = variant('east_node', { platforms: [] });
53
+ assert.deepEqual(mergeArgvOf(node, 'function', ['merge.beast2', 'range.beast2', 'p0.beast2']).slice(0, 2), ['east-node', 'merge']);
54
+ });
55
+ it('refuses a custom runner, which has no merge command', () => {
56
+ const custom = variant('custom', { command: ['uv', 'run', 'east-py', 'run'] });
57
+ assert.throws(() => mergeCommandIr(custom, 'union'), { message: 'a custom runner has no merge command' });
58
+ });
59
+ });
60
+ //# sourceMappingURL=stream.spec.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"stream.spec.js","sourceRoot":"","sources":["../../src/stream.spec.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH;;;;GAIG;AAEH,OAAO,EAAE,QAAQ,EAAE,EAAE,EAAE,MAAM,WAAW,CAAC;AACzC,OAAO,MAAM,MAAM,oBAAoB,CAAC;AACxC,OAAO,EAAE,OAAO,EAAE,MAAM,eAAe,CAAC;AACxC,OAAO,EAAE,cAAc,EAAE,eAAe,EAA0B,MAAM,aAAa,CAAC;AAGtF,MAAM,MAAM,GAAgB,OAAO,CAAC,QAAQ,EAAE,EAAE,SAAS,EAAE,CAAC,YAAY,CAAC,EAAE,CAAC,CAAC;AAE7E,sEAAsE;AACtE,SAAS,MAAM,CAAC,MAAmB,EAAE,IAA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c,EAAE,WAAW,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,EAAE,CAAC,CAAC,EAAE,CAAC,WAAW,EAAE,OAAO,CAAC,CAAC,CAAC;IACrI,CAAC,CAAC,CAAC;IAEH,EAAE,CAAC,qDAAqD,EAAE,GAAG,EAAE;QAC7D,MAAM,MAAM,GAAgB,OAAO,CAAC,QAAQ,EAAE,EAAE,OAAO,EAAE,CAAC,IAAI,EAAE,KAAK,EAAE,SAAS,EAAE,KAAK,CAAC,EAAE,CAAC,CAAC;QAC5F,MAAM,CAAC,MAAM,CAAC,GAAG,EAAE,CAAC,cAAc,CAAC,MAAM,EAAE,OAAO,CAAC,EAAE,EAAE,OAAO,EAAE,sCAAsC,EAAE,CAAC,CAAC;IAC5G,CAAC,CAAC,CAAC;AACL,CAAC,CAAC,CAAC"}
@@ -15,6 +15,7 @@
15
15
  * specified paths - the task just references locations, not types.
16
16
  */
17
17
  import { StructType, StringType, ArrayType, BlobType, BooleanType, IntegerType, OptionType, ValueTypeOf } from '@elaraai/east';
18
+ import type { EastTypeValue, FunctionIR } from '@elaraai/east';
18
19
  /**
19
20
  * Task object stored in the object store.
20
21
  *
@@ -116,6 +117,13 @@ export declare const TASK_KIND_PARTITION = "partition";
116
117
  * capability. The spec rides {@link TaskObjectType}'s `metadata` slot as a
117
118
  * beast2-encoded {@link StreamTaskMetadataType}. */
118
119
  export declare const TASK_KIND_STREAM = "stream";
120
+ /** Task kind of a merge unit — the runner's `merge` command over sorted
121
+ * partials of a partitioned task's keyed output (issue #770). The
122
+ * orchestrator writes one such task per partitioned task from the
123
+ * package's {@link PartitionTaskMetadataType} `mergeCommand`, and runs it
124
+ * as an ordinary content-addressed execution per group of partials. It
125
+ * carries no metadata. */
126
+ export declare const TASK_KIND_MERGE = "merge";
119
127
  /**
120
128
  * Metadata of a {@link TASK_KIND_PARTITION} task.
121
129
  *
@@ -146,17 +154,29 @@ export declare const PartitionTaskMetadataType: StructType<{
146
154
  * `encodeEastIR` bundle of the per-key merge `(Key, Value, Value) -> Value`
147
155
  * for a Dict output; `none` otherwise.
148
156
  *
149
- * Its presence (or {@link mergeSets}) selects the SEGMENT-MERGE assembly:
150
- * partials are walked by their segment fences in the orchestrator, disjoint
151
- * segments are byte-copied exactly as a splice does, and only overlapping
152
- * ones are decoded, merged and re-encoded. Appended LAST (BEAST2 encodes
157
+ * Its presence (or {@link mergeSets}) selects the MERGE-TREE assembly:
158
+ * partials whose key ranges overlap are merged by the task's own runner, in
159
+ * a tree of merge executions ({@link mergeCommand}) folding equal keys with
160
+ * this function; disjoint partials are spliced; the orchestrator never
161
+ * decodes a partial. Appended after `targetPartitionBytes` (BEAST2 encodes
153
162
  * struct fields positionally) with a dual decoder — see
154
163
  * {@link decodePartitionTaskMetadata}.
155
164
  */
156
165
  readonly merge: OptionType<BlobType>;
157
- /** Whether a Set output assembles by segment merge (union). The Set twin of
158
- * {@link merge}, which needs no function. Appended LAST. */
166
+ /** Whether a Set output assembles by the merge tree, keeping one of equal
167
+ * elements (`--union`). The Set twin of {@link merge}, which needs no
168
+ * function. */
159
169
  readonly mergeSets: BooleanType;
170
+ /**
171
+ * `encodeEastIR` bundle of the merge command `(input_paths, output_path) ->
172
+ * argv` — `mergeCommandIr` over the task's runner, in `function` mode with
173
+ * {@link merge} and `union` mode with {@link mergeSets} — that the
174
+ * orchestrator's merge units execute; `none` in splice and combine modes.
175
+ * Built at export, so the merge unit task is a package object like any
176
+ * other and nothing is synthesized at run time. Appended LAST with a
177
+ * triple decoder — see {@link decodePartitionTaskMetadata}.
178
+ */
179
+ readonly mergeCommand: OptionType<BlobType>;
160
180
  }>;
161
181
  export type PartitionTaskMetadataType = typeof PartitionTaskMetadataType;
162
182
  export type PartitionTaskMetadata = ValueTypeOf<typeof PartitionTaskMetadataType>;
@@ -164,34 +184,180 @@ export type PartitionTaskMetadata = ValueTypeOf<typeof PartitionTaskMetadataType
164
184
  export declare const encodePartitionTaskMetadata: (value: PartitionTaskMetadata) => Uint8Array;
165
185
  /**
166
186
  * Decode a `TaskObject.metadata` blob of a {@link TASK_KIND_PARTITION} task,
167
- * tolerating the pre-`merge` wire format (dual-decode migration).
187
+ * tolerating the two older wire formats: the v1.0.77 shape without
188
+ * `mergeCommand`, and the pre-`merge` shape.
168
189
  *
169
190
  * @param data - the metadata blob
170
- * @returns the decoded metadata, with `merge`/`mergeSets` defaulted off for
171
- * older bytes
191
+ * @returns the decoded metadata, with `mergeCommand` (and, for the oldest
192
+ * bytes, `merge`/`mergeSets`) defaulted off
172
193
  */
173
194
  export declare function decodePartitionTaskMetadata(data: Uint8Array): PartitionTaskMetadata;
174
195
  /**
175
196
  * Metadata of a {@link TASK_KIND_STREAM} task.
176
197
  *
177
- * The task's wire `inputs` are laid out `[function_ir, stream?, ...inputs]`;
178
- * the compiled body takes one trailing `emit` parameter beyond the wire
179
- * inputs, and the runner writes the `-o` file from the emit sink instead of
180
- * the body's (Null) return value.
198
+ * The task's wire `inputs` are laid out `[function_ir, merge_ir?, stream?,
199
+ * ...inputs]` — `merge_ir` only in `function` merge mode; the compiled body
200
+ * takes one trailing `emit` parameter beyond the wire inputs, and the runner
201
+ * writes the `-o` file from the emit sink instead of the body's (Null) return
202
+ * value.
181
203
  */
182
204
  export declare const StreamTaskMetadataType: StructType<{
183
- /** Whether wire input index 1 is the streamed input (producer tasks have
184
- * no streamed input). */
205
+ /** Whether the first input after the IRs is the streamed input (producer
206
+ * tasks have no streamed input). */
185
207
  readonly stream: BooleanType;
186
208
  /** The output collection kind the emit sink writes: `"array"`, `"set"`, or
187
209
  * `"dict"` — element/key/value types come from the body IR's emit
188
210
  * parameter. */
189
211
  readonly emit: StringType;
212
+ /**
213
+ * How the emit sink treats equal keys, a `StreamMergeMode`: `"none"` —
214
+ * a duplicate key is an error; `"function"` — wire input 1 is the merge IR
215
+ * `(K, V, V) -> V`, folding equal Dict keys; `"union"` — equal Set elements
216
+ * collapse. Appended LAST (BEAST2 encodes struct fields positionally) with a
217
+ * dual decoder — see {@link decodeStreamTaskMetadata}.
218
+ */
219
+ readonly merge: StringType;
190
220
  }>;
191
221
  export type StreamTaskMetadataType = typeof StreamTaskMetadataType;
192
222
  export type StreamTaskMetadata = ValueTypeOf<typeof StreamTaskMetadataType>;
193
223
  /** Encode a {@link StreamTaskMetadataType} value for `TaskObject.metadata`. */
194
224
  export declare const encodeStreamTaskMetadata: (value: StreamTaskMetadata) => Uint8Array;
195
- /** Decode a `TaskObject.metadata` blob of a {@link TASK_KIND_STREAM} task. */
196
- export declare const decodeStreamTaskMetadata: (data: Uint8Array) => StreamTaskMetadata;
225
+ /**
226
+ * Decode a `TaskObject.metadata` blob of a {@link TASK_KIND_STREAM} task,
227
+ * tolerating the pre-`merge` wire format (dual-decode migration).
228
+ *
229
+ * @param data - the metadata blob
230
+ * @returns the decoded metadata, with `merge` defaulted to `"none"` for older
231
+ * bytes
232
+ */
233
+ export declare function decodeStreamTaskMetadata(data: Uint8Array): StreamTaskMetadata;
234
+ /**
235
+ * The plan of one merged component's fan-in (issue #770): the partials whose
236
+ * key ranges overlap, and the key ranges its merge units run over, as the
237
+ * hashes of the range blobs the units take as their input.
238
+ *
239
+ * @remarks
240
+ * The ranges are a pure function of the partials and the task's
241
+ * `targetPartitionBytes` — the boundary keys are fences of the largest
242
+ * partial — so a re-run whose partials are the same objects plans the same
243
+ * ranges; recording them lets it skip the planning probes, and because
244
+ * every unit's inputs are then the same objects, every merge unit
245
+ * cache-hits.
246
+ */
247
+ export declare const MergeRangePlanType: StructType<{
248
+ /** The component's partial hashes, in partition order. */
249
+ readonly partials: ArrayType<StringType>;
250
+ /** The hashes of the component's range blobs — `Struct{from: Option<K>,
251
+ * to: Option<K>}` over the output's key type — in key order; one open
252
+ * range for a component that merges whole. */
253
+ readonly ranges: ArrayType<StringType>;
254
+ }>;
255
+ export type MergeRangePlanType = typeof MergeRangePlanType;
256
+ export type MergeRangePlan = ValueTypeOf<typeof MergeRangePlanType>;
257
+ /**
258
+ * The plan of a partitioned execution (issue #770): the partitioned inputs,
259
+ * where each partition starts in every one of them, the carved slices, and
260
+ * the ranged fan-in of each merged component.
261
+ *
262
+ * @remarks
263
+ * The step interpreter writes it to the object store as the run goes —
264
+ * after the map step with the carved slices, and again after the reduce
265
+ * step has planned each component's merge ranges — and points the `plan`
266
+ * sidecar of the execution's `(taskHash, inputsHash)` directory at it, so a
267
+ * re-plan or a resume that computes the same `partitions`/`boundaries`/
268
+ * `splits` reuses the slices instead of carving them again, partition by
269
+ * partition, and a component of the same partials reuses its ranges.
270
+ */
271
+ export declare const PartitionPlanType: StructType<{
272
+ /** Partitioned input hashes, wire order. */
273
+ readonly partitions: ArrayType<StringType>;
274
+ /** First segment index of each partition of the primary; boundaries[0] = 0. */
275
+ readonly boundaries: ArrayType<IntegerType>;
276
+ /** Per secondary (partitions[1..]): the split point of every partition plus the end; length boundaries.length + 1. */
277
+ readonly splits: ArrayType<ArrayType<StructType<{
278
+ readonly seg: IntegerType;
279
+ readonly offset: IntegerType;
280
+ }>>>;
281
+ /** slices[input][partition] object hashes; empty until carved. */
282
+ readonly slices: ArrayType<ArrayType<StringType>>;
283
+ /** The ranged fan-in of each merged component, once its ranges are
284
+ * planned. Appended LAST (BEAST2 encodes struct fields positionally) with
285
+ * a dual decoder — see {@link decodePartitionPlan}. */
286
+ readonly merges: ArrayType<StructType<{
287
+ /** The component's partial hashes, in partition order. */
288
+ readonly partials: ArrayType<StringType>;
289
+ /** The hashes of the component's range blobs — `Struct{from: Option<K>,
290
+ * to: Option<K>}` over the output's key type — in key order; one open
291
+ * range for a component that merges whole. */
292
+ readonly ranges: ArrayType<StringType>;
293
+ }>>;
294
+ }>;
295
+ export type PartitionPlanType = typeof PartitionPlanType;
296
+ export type PartitionPlan = ValueTypeOf<typeof PartitionPlanType>;
297
+ /** Encode a {@link PartitionPlanType} value for the object store. */
298
+ export declare const encodePartitionPlan: (value: PartitionPlan) => Uint8Array;
299
+ /**
300
+ * Decode a {@link PartitionPlanType} object, tolerating the pre-`merges`
301
+ * wire shape (dual-decode migration): an older plan decodes with no recorded
302
+ * merge ranges, so its partition slices are reused and its ranges planned.
303
+ *
304
+ * @param data - the plan object's bytes
305
+ * @returns the decoded plan
306
+ */
307
+ export declare function decodePartitionPlan(data: Uint8Array): PartitionPlan;
308
+ /**
309
+ * The shape a partition task's `by` projection reads, as extracted from its
310
+ * IR by {@link partitionProjectionShape}.
311
+ *
312
+ * - `fields`: the identity (`names: []`), or a leading prefix of the key's
313
+ * top-level fields — one field, or a struct literal of fields in declared
314
+ * order. Validated against each dataset's top-level key field order.
315
+ * - `path`: a nested leading-field path (`key.a.b`, two or more steps).
316
+ * Validated per step: each must read the FIRST field of its level's
317
+ * struct, which is what keeps the projection monotone in canonical key
318
+ * order.
319
+ */
320
+ export interface ProjectionShape {
321
+ /** Top-level fields (or the identity), or a nested first-field path. */
322
+ kind: 'fields' | 'path';
323
+ /** The fields read, in order; empty for the identity. */
324
+ names: string[];
325
+ }
326
+ /**
327
+ * Extracts the shape a `by` projection reads — see {@link ProjectionShape} —
328
+ * or `null` for any other (unaccepted) shape.
329
+ *
330
+ * @param ir - the projection's function IR, `(Key) -> Projection`
331
+ * @returns the shape, or `null` when the body is not an accepted projection
332
+ */
333
+ export declare function partitionProjectionShape(ir: FunctionIR): ProjectionShape | null;
334
+ /**
335
+ * The East type of a projected key — the type {@link projectKey} values have,
336
+ * and the one to build their comparator for: the key type itself for the
337
+ * identity, a struct of the named leading fields in declared order, or the
338
+ * type at the end of a nested first-field path.
339
+ *
340
+ * @param shape - the projection's shape
341
+ * @param keyType - the partitioned dataset's key type
342
+ * @returns the projected key type
343
+ * @throws {Error} When the shape reads a field the key type does not have.
344
+ *
345
+ * @example
346
+ * ```ts
347
+ * const cmp = compareFor(projectedKeyType(shape, keyTypeValue));
348
+ * cmp(projectKey(shape, a), projectKey(shape, b));
349
+ * ```
350
+ */
351
+ export declare function projectedKeyType(shape: ProjectionShape, keyType: EastTypeValue): EastTypeValue;
352
+ /**
353
+ * Projects a partition key through a `by` shape, without compiling the
354
+ * projection: the key itself for the identity, a struct of the named leading
355
+ * fields built field by field in declared order, or the value at the end of a
356
+ * nested first-field path.
357
+ *
358
+ * @param shape - the projection's shape
359
+ * @param key - a key of the partitioned dataset
360
+ * @returns the projected key, a value of {@link projectedKeyType}
361
+ */
362
+ export declare function projectKey(shape: ProjectionShape, key: unknown): unknown;
197
363
  //# sourceMappingURL=task.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"task.d.ts","sourceRoot":"","sources":["../../src/task.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH;;;;;;;;;;;GAWG;AAEH,OAAO,EAAE,UAAU,EAAE,UAAU,EAAE,SAAS,EAAE,QAAQ,EAAE,WAAW,EAAE,WAAW,EAAE,UAAU,EAAE,WAAW,EAA0C,MAAM,eAAe,CAAC;AAIvK;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAiCG;AACH,eAAO,MAAM,cAAc;IACzB,kFAAkF;;IAElF,uEAAuE;;;;IAEvE,sEAAsE;;;;IAEtE,sFAAsF;;IAEtF,6FAA6F;;IAE7F;;;;;;;OAOG;;;;;;;;;;;;;;;IAEH;;;;;OAKG;;EAEH,CAAC;AACH,MAAM,MAAM,cAAc,GAAG,OAAO,cAAc,CAAC;AAEnD,MAAM,MAAM,UAAU,GAAG,WAAW,CAAC,OAAO,cAAc,CAAC,CAAC;AAmB5D;;;;;;;GAOG;AACH,wBAAgB,gBAAgB,CAAC,IAAI,EAAE,UAAU,GAAG,UAAU,CAW7D;AAMD;;;;kEAIkE;AAClE,eAAO,MAAM,mBAAmB,cAAc,CAAC;AAE/C;;;qDAGqD;AACrD,eAAO,MAAM,gBAAgB,WAAW,CAAC;AAEzC;;;;;;;;;;;;;;GAcG;AACH,eAAO,MAAM,yBAAyB;IACpC,2EAA2E;;IAE3E;mFAC+E;;IAE/E;sDACkD;;IAElD,qEAAqE;;IAErE;;;;;;;;;;OAUG;;IAEH;iEAC6D;;EAE7D,CAAC;AACH,MAAM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