@koda-sl/baker-cli 0.122.0-dev.57a9836c5 → 0.122.0-dev.fff192e73
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 +42 -39
- package/dist/{chunk-SH6L4BCQ.js → chunk-MWFJ5NOP.js} +73 -335
- package/dist/chunk-MWFJ5NOP.js.map +1 -0
- package/dist/cli.js +1811 -1745
- package/dist/cli.js.map +1 -1
- package/dist/engine/index.d.ts +0 -58
- package/dist/engine/index.js +1 -1
- package/package.json +1 -1
- package/dist/chunk-SH6L4BCQ.js.map +0 -1
package/dist/engine/index.d.ts
CHANGED
|
@@ -47,13 +47,6 @@ declare class BackendClient$1 {
|
|
|
47
47
|
putUrl: string;
|
|
48
48
|
publicUrl: string;
|
|
49
49
|
}>;
|
|
50
|
-
/** Remote cache lookup. A miss (404) — or an old backend without the route — returns null. */
|
|
51
|
-
getCacheEntry<T>(cacheKey: string, signal?: AbortSignal): Promise<T | null>;
|
|
52
|
-
putCacheEntry(entry: {
|
|
53
|
-
cacheKey: string;
|
|
54
|
-
}, signal?: AbortSignal): Promise<void>;
|
|
55
|
-
/** Durable run-history record — POST /api/canvas/runs (idempotent server-side on runId). */
|
|
56
|
-
recordRun(payload: unknown, signal?: AbortSignal): Promise<void>;
|
|
57
50
|
getArtifact(kind: string, name: string, version?: string, signal?: AbortSignal): Promise<ArtifactResponse>;
|
|
58
51
|
}
|
|
59
52
|
|
|
@@ -346,39 +339,6 @@ type RunResult = {
|
|
|
346
339
|
duration_ms: number;
|
|
347
340
|
};
|
|
348
341
|
outputs_dir: string;
|
|
349
|
-
node_runs: NodeRunRecord[];
|
|
350
|
-
};
|
|
351
|
-
type NodeRunRecord = {
|
|
352
|
-
node_id: string;
|
|
353
|
-
node_type: string;
|
|
354
|
-
cached: boolean;
|
|
355
|
-
duration_ms: number;
|
|
356
|
-
credits: number;
|
|
357
|
-
};
|
|
358
|
-
/**
|
|
359
|
-
* Live run telemetry: the plan (post-prune node list + dependency edges) fires
|
|
360
|
-
* once before any node executes, then start/settled/failed per node. Consumers
|
|
361
|
-
* stream these into run-history progress snapshots; a throwing consumer is
|
|
362
|
-
* swallowed — telemetry must never fail a paid run.
|
|
363
|
-
*/
|
|
364
|
-
type RunProgressEvent = {
|
|
365
|
-
kind: "plan";
|
|
366
|
-
nodes: Array<{
|
|
367
|
-
node_id: string;
|
|
368
|
-
node_type: string;
|
|
369
|
-
deps: string[];
|
|
370
|
-
params: unknown;
|
|
371
|
-
}>;
|
|
372
|
-
} | {
|
|
373
|
-
kind: "node_start";
|
|
374
|
-
node_id: string;
|
|
375
|
-
} | {
|
|
376
|
-
kind: "node_settled";
|
|
377
|
-
run: NodeRunRecord;
|
|
378
|
-
outputs: Record<string, unknown>;
|
|
379
|
-
} | {
|
|
380
|
-
kind: "node_failed";
|
|
381
|
-
node_id: string;
|
|
382
342
|
};
|
|
383
343
|
type RunOptions = {
|
|
384
344
|
signal?: AbortSignal;
|
|
@@ -386,7 +346,6 @@ type RunOptions = {
|
|
|
386
346
|
cache_policy?: "read_write" | "bypass" | "read_only";
|
|
387
347
|
/** Max nodes of one layer in flight at once; invalid or missing → 5. */
|
|
388
348
|
concurrency?: number;
|
|
389
|
-
onProgress?: (event: RunProgressEvent) => void;
|
|
390
349
|
};
|
|
391
350
|
type EngineOptions = {
|
|
392
351
|
registry: NodeRegistry;
|
|
@@ -395,13 +354,6 @@ type EngineOptions = {
|
|
|
395
354
|
cache: CacheStore;
|
|
396
355
|
outputsDir: string;
|
|
397
356
|
log?: LogFn;
|
|
398
|
-
/**
|
|
399
|
-
* Stamp durable canvas-assets URLs onto fresh node outputs before they are
|
|
400
|
-
* cached — the precondition for remote cache portability and run-history
|
|
401
|
-
* records. Best-effort: a failed upload logs a warning and keeps the entry
|
|
402
|
-
* local-only, never fails the node.
|
|
403
|
-
*/
|
|
404
|
-
persistAssets?: boolean;
|
|
405
357
|
};
|
|
406
358
|
declare class Engine$1 {
|
|
407
359
|
private readonly registry;
|
|
@@ -410,7 +362,6 @@ declare class Engine$1 {
|
|
|
410
362
|
private readonly cache;
|
|
411
363
|
private readonly outputsDir;
|
|
412
364
|
private readonly log;
|
|
413
|
-
private readonly persistAssets;
|
|
414
365
|
constructor(opts: EngineOptions);
|
|
415
366
|
validate(canvas: unknown): {
|
|
416
367
|
ok: true;
|
|
@@ -439,8 +390,6 @@ declare class Engine$1 {
|
|
|
439
390
|
}>;
|
|
440
391
|
run(input: unknown, opts?: RunOptions): Promise<RunResult>;
|
|
441
392
|
private runLayers;
|
|
442
|
-
/** Progress consumers are observers only — an exception there must never fail the run. */
|
|
443
|
-
private emitProgress;
|
|
444
393
|
/**
|
|
445
394
|
* Dead-node elimination: when the canvas declares an `output`, execute only the
|
|
446
395
|
* nodes that output transitively depends on. Orphaned nodes (left by an edit or
|
|
@@ -518,13 +467,6 @@ declare function createEngineFromEnv(opts?: {
|
|
|
518
467
|
cacheDir?: string;
|
|
519
468
|
outputsDir?: string;
|
|
520
469
|
log?: (line: string) => void;
|
|
521
|
-
/**
|
|
522
|
-
* Layer the company-scoped remote cache over the local one (and stamp
|
|
523
|
-
* durable asset URLs onto fresh outputs) so a fresh sandbox re-runs an
|
|
524
|
-
* already-computed canvas at zero credits. Defaults to on; disable with
|
|
525
|
-
* `remoteCache: false` or env BAKER_CANVAS_REMOTE_CACHE=off.
|
|
526
|
-
*/
|
|
527
|
-
remoteCache?: boolean;
|
|
528
470
|
}): Engine$1;
|
|
529
471
|
|
|
530
472
|
export { BackendClient, Engine, LocalAssetStore, LocalCacheStore, ValidationError, createEngineFromEnv, defaultRegistry, generateCatalog, validateCanvasDeep };
|
package/dist/engine/index.js
CHANGED
package/package.json
CHANGED