yaml-flow 8.2.0 → 8.2.1
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/browser/asset-integrity.json +3 -3
- package/browser/board-livecards-client.js +1 -1
- package/browser/board-livecards-localstorage.js +4 -6
- package/cli/{board-live-cards-lib-tjYsPt5U.d.ts → board-live-cards-lib-Iq_XAC09.d.ts} +1 -1
- package/cli/browser-api/board-live-cards-browser-adapter.d.ts +4 -3
- package/cli/browser-api/board-live-cards-browser-adapter.js +2 -2
- package/cli/browser-api/card-store-browser-api.d.ts +1 -1
- package/cli/node/artifacts-store-cli.js +8 -8
- package/cli/node/board-live-cards-cli.js +8 -8
- package/cli/node/fs-board-adapter.d.ts +6 -33
- package/cli/node/fs-board-adapter.js +10 -8
- package/cli/node/step-machine-cli.js +2 -2
- package/cli/{types-CSiGbY__.d.ts → types--rXGWbSR.d.ts} +76 -4
- package/examples/board/.board-ws/cards/store/_index.json +17 -0
- package/examples/board/.board-ws/cards/store/card-market-prices.json +80 -0
- package/examples/board/.board-ws/cards/store/card-portfolio-value.json +90 -0
- package/examples/board/.board-ws/cards/store/card-portfolio.json +78 -0
- package/examples/board/cards/cardT-market-prices.json +6 -4
- package/examples/board/cards/cardT-portfolio-value.json +10 -38
- package/examples/board/cards/cardT-portfolio.json +9 -4
- package/examples/board/demo-shell-with-server.html +3 -3
- package/examples/board/server/board-server.js +593 -0
- package/examples/board/server/board-worker/source-def-flows/mock-handler/mock-db.js +13 -0
- package/examples/board/server/board-worker/source-def-flows/sqlite-handler/.retain/compliance.db +0 -0
- package/examples/board/server/board-worker/source-def-flows/sqlite-handler/.retain/optimus.db +0 -0
- package/examples/board/server/board-worker/source-def-flows/sqlite-handler/query.cjs +51 -0
- package/examples/board/server/board-worker/source-def-flows/sqlite-handler/seed-cpm.cjs +197 -0
- package/examples/board/server/board-worker/source-def-flows/sqlite-handler/seed-cpmV2.cjs +128 -0
- package/examples/board/server/board-worker/source-def-flows/sqlite-handler/seed-optimus.cjs +352 -0
- package/examples/board/server/board-worker/source-def-flows/sqlite-handler/sqlite-config.json +3 -0
- package/examples/board/server/board-worker/source-def-flows/sqlite-handler/sqlite-handler.js +84 -0
- package/examples/board/{source-def-flows/url.flow.json → server/board-worker/source-def-flows/sqlite.flow.json} +7 -7
- package/examples/board/{source-def-handlers → server/board-worker/source-def-flows/url-handler}/http-source-handler.js +29 -21
- package/examples/board/server/board-worker/source-def-flows/url.flow.json +73 -0
- package/examples/board/{source_def_flows.json → server/board-worker/source_def_flows.json} +61 -115
- package/examples/board/server/board-worker/task-executor.js +475 -0
- package/examples/board/server/chat-flow/chat-clear-processing.js +41 -0
- package/examples/board/server/chat-flow/chat-open-turn.js +144 -0
- package/examples/board/server/chat-flow/chat-write-assistant.js +44 -0
- package/examples/board/server/chat-flow/copilot-chat/assistant.js +253 -0
- package/examples/board/server/chat-flow/echo-probe/assistant.js +28 -0
- package/examples/board/server/chat-flow/flow-steps.json +167 -0
- package/examples/board/server-config.json +22 -0
- package/examples/board/test/server-http-test.js +707 -0
- package/examples/board/test/{portfolio-tracker-sse-worker.js → sse-worker.js} +9 -8
- package/examples/board-local/demo-shell-localstorage.html +3 -3
- package/lib/{artifacts-store-lib-public-DfU9t5-S.d.cts → artifacts-store-lib-public-C5UL5tyG.d.cts} +3 -31
- package/lib/{artifacts-store-lib-public-BPW_C15z.d.ts → artifacts-store-lib-public-GD4H-fFp.d.ts} +3 -31
- package/lib/artifacts-store-public.d.cts +3 -3
- package/lib/artifacts-store-public.d.ts +3 -3
- package/lib/board-live-cards-node.cjs +10 -8
- package/lib/board-live-cards-node.d.cts +9 -8
- package/lib/board-live-cards-node.d.ts +9 -8
- package/lib/board-live-cards-node.js +10 -8
- package/lib/{board-live-cards-public-W2zK59m0.d.cts → board-live-cards-public-BLXbcBNk.d.cts} +1 -1
- package/lib/{board-live-cards-public-B8b_0k_j.d.ts → board-live-cards-public-BZaNb2mi.d.ts} +1 -1
- package/lib/board-live-cards-public.d.cts +2 -2
- package/lib/board-live-cards-public.d.ts +2 -2
- package/lib/board-live-cards-server-runtime.cjs +4 -6
- package/lib/board-live-cards-server-runtime.d.cts +3 -3
- package/lib/board-live-cards-server-runtime.d.ts +3 -3
- package/lib/board-live-cards-server-runtime.js +4 -6
- package/lib/board-livegraph-runtime/index.cjs +2 -2
- package/lib/board-livegraph-runtime/index.js +2 -2
- package/lib/card-store-public.d.cts +2 -2
- package/lib/card-store-public.d.ts +2 -2
- package/lib/execution-refs.cjs +1 -1
- package/lib/execution-refs.js +1 -1
- package/lib/index.cjs +1 -1
- package/lib/index.d.cts +1 -1
- package/lib/index.d.ts +1 -1
- package/lib/index.js +1 -1
- package/lib/server-runtime/index.cjs +4 -6
- package/lib/server-runtime/index.d.cts +4 -4
- package/lib/server-runtime/index.d.ts +4 -4
- package/lib/server-runtime/index.js +4 -6
- package/lib/step-machine-public/index.d.cts +1 -1
- package/lib/step-machine-public/index.d.ts +1 -1
- package/lib/{storage-interface-BhAON-gW.d.cts → storage-interface-B6ecOulj.d.cts} +25 -3
- package/lib/{storage-interface-BhAON-gW.d.ts → storage-interface-B6ecOulj.d.ts} +25 -3
- package/lib/stores/index.d.cts +1 -1
- package/lib/stores/index.d.ts +1 -1
- package/lib/stores/kv.d.cts +1 -1
- package/lib/stores/kv.d.ts +1 -1
- package/lib/{types-seTI8zta.d.cts → types-Bztd1KoK.d.cts} +55 -3
- package/lib/{types-Bm7IFD7r.d.ts → types-D-xVWPdY.d.ts} +55 -3
- package/package.json +1 -1
- package/examples/board/demo-chat-copilot.flow.json +0 -38
- package/examples/board/demo-chat-copilot.js +0 -185
- package/examples/board/demo-chat-echo.flow.json +0 -38
- package/examples/board/demo-chat-echo.js +0 -92
- package/examples/board/demo-server-config.copilot-chat.json +0 -10
- package/examples/board/demo-server-config.json +0 -10
- package/examples/board/demo-server.js +0 -629
- package/examples/board/demo-task-executor.js +0 -721
- package/examples/board/gandalf-cards/card-source-kinds.json +0 -36
- package/examples/board/gandalf-cards/cards/_index.json +0 -7
- package/examples/board/gandalf-cards/cards/card-source-kinds.json +0 -64
- package/examples/board/scripts/copilot_wrapper.bat +0 -157
- package/examples/board/scripts/copilot_wrapper_helper.ps1 +0 -190
- package/examples/board/scripts/workiq_wrapper.mjs +0 -66
- package/examples/board/source-def-flows/copilot.flow.json +0 -33
- package/examples/board/source-def-flows/url-list.flow.json +0 -33
- package/examples/board/source-def-flows/workiq.flow.json +0 -34
- package/examples/board/source-def-handlers/copilot-source-handler.js +0 -141
- package/examples/board/test/demo-http-test.js +0 -362
- /package/examples/board/{source-def-flows → server/board-worker/source-def-flows}/mock.flow.json +0 -0
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
/**
|
|
2
|
-
*
|
|
2
|
+
* sse-worker.js
|
|
3
3
|
*
|
|
4
4
|
* SSE consumer worker thread.
|
|
5
5
|
*
|
|
6
|
-
* Spawned by
|
|
6
|
+
* Spawned by demo-http-test.js via worker_threads.
|
|
7
7
|
* Receives { sseUrl } in workerData, opens the SSE stream, and forwards
|
|
8
8
|
* every parsed frame to the main thread via parentPort.postMessage.
|
|
9
9
|
*
|
|
@@ -22,16 +22,20 @@ const req = http.get(sseUrl, (res) => {
|
|
|
22
22
|
let buf = '';
|
|
23
23
|
res.setEncoding('utf-8');
|
|
24
24
|
res.on('data', (chunk) => {
|
|
25
|
-
|
|
25
|
+
// Normalize CRLF-delimited SSE blocks to a single delimiter style.
|
|
26
|
+
buf += chunk.replace(/\r\n/g, '\n');
|
|
26
27
|
while (true) {
|
|
27
28
|
const idx = buf.indexOf('\n\n');
|
|
28
29
|
if (idx === -1) break;
|
|
29
30
|
const block = buf.slice(0, idx);
|
|
30
31
|
buf = buf.slice(idx + 2);
|
|
31
|
-
|
|
32
|
+
const dataLines = [];
|
|
32
33
|
for (const line of block.split('\n')) {
|
|
33
|
-
if (line.startsWith('data:
|
|
34
|
+
if (line.startsWith('data:')) {
|
|
35
|
+
dataLines.push(line.slice(5).replace(/^ /, ''));
|
|
36
|
+
}
|
|
34
37
|
}
|
|
38
|
+
const data = dataLines.join('\n');
|
|
35
39
|
if (!data) continue;
|
|
36
40
|
try {
|
|
37
41
|
parentPort.postMessage({ type: 'frame', payload: JSON.parse(data) });
|
|
@@ -43,6 +47,3 @@ const req = http.get(sseUrl, (res) => {
|
|
|
43
47
|
});
|
|
44
48
|
|
|
45
49
|
req.on('error', (err) => parentPort.postMessage({ type: 'error', message: err.message }));
|
|
46
|
-
|
|
47
|
-
// Worker stays alive as long as the SSE connection is open.
|
|
48
|
-
// Main thread calls sseWorker.terminate() to clean up.
|
|
@@ -6,13 +6,13 @@
|
|
|
6
6
|
<title>Example Board Demo (LocalStorage Runtime)</title>
|
|
7
7
|
<link rel="icon" type="image/svg+xml" href="../../browser/favicon.svg" />
|
|
8
8
|
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.3/dist/css/bootstrap.min.css" rel="stylesheet" />
|
|
9
|
-
<script src="https://cdn.jsdelivr.net/npm/yaml-flow@8.2.
|
|
9
|
+
<script src="https://cdn.jsdelivr.net/npm/yaml-flow@8.2.1/browser/compute-jsonata.js"></script>
|
|
10
10
|
<script src="https://cdn.jsdelivr.net/npm/chart.js"></script>
|
|
11
11
|
<script src="https://cdn.jsdelivr.net/npm/marked/marked.min.js"></script>
|
|
12
12
|
<script src="https://cdn.jsdelivr.net/npm/dompurify/dist/purify.min.js"></script>
|
|
13
13
|
<script src="https://cdn.jsdelivr.net/npm/leader-line/leader-line.min.js"></script>
|
|
14
|
-
<script src="https://cdn.jsdelivr.net/npm/yaml-flow@8.2.
|
|
15
|
-
<script src="https://cdn.jsdelivr.net/npm/yaml-flow@8.2.
|
|
14
|
+
<script src="https://cdn.jsdelivr.net/npm/yaml-flow@8.2.1/browser/live-cards.js"></script>
|
|
15
|
+
<script src="https://cdn.jsdelivr.net/npm/yaml-flow@8.2.1/browser/board-livecards-localstorage.js"></script>
|
|
16
16
|
</head>
|
|
17
17
|
<body class="bg-light">
|
|
18
18
|
<div class="container-fluid py-3">
|
package/lib/{artifacts-store-lib-public-DfU9t5-S.d.cts → artifacts-store-lib-public-C5UL5tyG.d.cts}
RENAMED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { C as CommandInput, a as CommandResult } from './board-live-cards-public-
|
|
2
|
-
import { B as BlobStorage } from './storage-interface-
|
|
1
|
+
import { C as CommandInput, a as CommandResult } from './board-live-cards-public-BLXbcBNk.cjs';
|
|
2
|
+
import { B as BlobStorage } from './storage-interface-B6ecOulj.cjs';
|
|
3
3
|
|
|
4
4
|
/**
|
|
5
5
|
* artifacts-store-lib.ts
|
|
@@ -24,31 +24,6 @@ interface ArtifactsStore {
|
|
|
24
24
|
list(prefix?: string): ArtifactInfo[];
|
|
25
25
|
remove(key: string): void;
|
|
26
26
|
}
|
|
27
|
-
interface ChatIndexRecord {
|
|
28
|
-
serial: number;
|
|
29
|
-
role: string;
|
|
30
|
-
stored_name: string;
|
|
31
|
-
path: string;
|
|
32
|
-
updated_at?: string | null;
|
|
33
|
-
}
|
|
34
|
-
interface ChatRecord extends ChatIndexRecord {
|
|
35
|
-
text: string;
|
|
36
|
-
}
|
|
37
|
-
interface ChatSignal {
|
|
38
|
-
count: number;
|
|
39
|
-
latest_mtime_ms: number;
|
|
40
|
-
processing: boolean;
|
|
41
|
-
}
|
|
42
|
-
interface ChatArtifactsStore {
|
|
43
|
-
indexKey(cardPrefix: string): string;
|
|
44
|
-
loadIndex(cardPrefix: string): ChatIndexRecord[];
|
|
45
|
-
saveIndex(cardPrefix: string, records: ChatIndexRecord[]): void;
|
|
46
|
-
nextSerial(cardPrefix: string): number;
|
|
47
|
-
appendIndexRecord(cardPrefix: string, record: ChatIndexRecord): void;
|
|
48
|
-
readRecords(cardPrefix: string): ChatRecord[];
|
|
49
|
-
clear(cardPrefix: string): void;
|
|
50
|
-
readSignal(cardPrefix: string): ChatSignal;
|
|
51
|
-
}
|
|
52
27
|
interface FileArtifactsStore {
|
|
53
28
|
nextSerial(cardPrefix: string, seedNames?: string[]): number;
|
|
54
29
|
buildStoredName(displayName: string, serial: number, opts?: {
|
|
@@ -81,9 +56,6 @@ interface CardFileMetadataStore {
|
|
|
81
56
|
resolve(cardData: unknown, index: number, expectedStoredName?: string | null): CardFileLookupResult;
|
|
82
57
|
}
|
|
83
58
|
declare function createArtifactsStore(blob: BlobStorage): ArtifactsStore;
|
|
84
|
-
declare function createChatArtifactsStore(store: ArtifactsStore, opts?: {
|
|
85
|
-
indexFileName?: string;
|
|
86
|
-
}): ChatArtifactsStore;
|
|
87
59
|
declare function createFileArtifactsStore(store: ArtifactsStore): FileArtifactsStore;
|
|
88
60
|
declare function createCardFileMetadataStore(): CardFileMetadataStore;
|
|
89
61
|
|
|
@@ -116,4 +88,4 @@ interface ArtifactsStorePublic {
|
|
|
116
88
|
}
|
|
117
89
|
declare function createArtifactsStorePublic(store: ArtifactsStore): ArtifactsStorePublic;
|
|
118
90
|
|
|
119
|
-
export { type ArtifactsStorePublic as A, createArtifactsStorePublic as a, createCardFileMetadataStore as b, createArtifactsStore as c,
|
|
91
|
+
export { type ArtifactsStorePublic as A, createArtifactsStorePublic as a, createCardFileMetadataStore as b, createArtifactsStore as c, createFileArtifactsStore as d };
|
package/lib/{artifacts-store-lib-public-BPW_C15z.d.ts → artifacts-store-lib-public-GD4H-fFp.d.ts}
RENAMED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { C as CommandInput, a as CommandResult } from './board-live-cards-public-
|
|
2
|
-
import { B as BlobStorage } from './storage-interface-
|
|
1
|
+
import { C as CommandInput, a as CommandResult } from './board-live-cards-public-BZaNb2mi.js';
|
|
2
|
+
import { B as BlobStorage } from './storage-interface-B6ecOulj.js';
|
|
3
3
|
|
|
4
4
|
/**
|
|
5
5
|
* artifacts-store-lib.ts
|
|
@@ -24,31 +24,6 @@ interface ArtifactsStore {
|
|
|
24
24
|
list(prefix?: string): ArtifactInfo[];
|
|
25
25
|
remove(key: string): void;
|
|
26
26
|
}
|
|
27
|
-
interface ChatIndexRecord {
|
|
28
|
-
serial: number;
|
|
29
|
-
role: string;
|
|
30
|
-
stored_name: string;
|
|
31
|
-
path: string;
|
|
32
|
-
updated_at?: string | null;
|
|
33
|
-
}
|
|
34
|
-
interface ChatRecord extends ChatIndexRecord {
|
|
35
|
-
text: string;
|
|
36
|
-
}
|
|
37
|
-
interface ChatSignal {
|
|
38
|
-
count: number;
|
|
39
|
-
latest_mtime_ms: number;
|
|
40
|
-
processing: boolean;
|
|
41
|
-
}
|
|
42
|
-
interface ChatArtifactsStore {
|
|
43
|
-
indexKey(cardPrefix: string): string;
|
|
44
|
-
loadIndex(cardPrefix: string): ChatIndexRecord[];
|
|
45
|
-
saveIndex(cardPrefix: string, records: ChatIndexRecord[]): void;
|
|
46
|
-
nextSerial(cardPrefix: string): number;
|
|
47
|
-
appendIndexRecord(cardPrefix: string, record: ChatIndexRecord): void;
|
|
48
|
-
readRecords(cardPrefix: string): ChatRecord[];
|
|
49
|
-
clear(cardPrefix: string): void;
|
|
50
|
-
readSignal(cardPrefix: string): ChatSignal;
|
|
51
|
-
}
|
|
52
27
|
interface FileArtifactsStore {
|
|
53
28
|
nextSerial(cardPrefix: string, seedNames?: string[]): number;
|
|
54
29
|
buildStoredName(displayName: string, serial: number, opts?: {
|
|
@@ -81,9 +56,6 @@ interface CardFileMetadataStore {
|
|
|
81
56
|
resolve(cardData: unknown, index: number, expectedStoredName?: string | null): CardFileLookupResult;
|
|
82
57
|
}
|
|
83
58
|
declare function createArtifactsStore(blob: BlobStorage): ArtifactsStore;
|
|
84
|
-
declare function createChatArtifactsStore(store: ArtifactsStore, opts?: {
|
|
85
|
-
indexFileName?: string;
|
|
86
|
-
}): ChatArtifactsStore;
|
|
87
59
|
declare function createFileArtifactsStore(store: ArtifactsStore): FileArtifactsStore;
|
|
88
60
|
declare function createCardFileMetadataStore(): CardFileMetadataStore;
|
|
89
61
|
|
|
@@ -116,4 +88,4 @@ interface ArtifactsStorePublic {
|
|
|
116
88
|
}
|
|
117
89
|
declare function createArtifactsStorePublic(store: ArtifactsStore): ArtifactsStorePublic;
|
|
118
90
|
|
|
119
|
-
export { type ArtifactsStorePublic as A, createArtifactsStorePublic as a, createCardFileMetadataStore as b, createArtifactsStore as c,
|
|
91
|
+
export { type ArtifactsStorePublic as A, createArtifactsStorePublic as a, createCardFileMetadataStore as b, createArtifactsStore as c, createFileArtifactsStore as d };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import './board-live-cards-public-
|
|
2
|
-
export { A as ArtifactsStorePublic, a as createArtifactsStorePublic } from './artifacts-store-lib-public-
|
|
3
|
-
import './storage-interface-
|
|
1
|
+
import './board-live-cards-public-BLXbcBNk.cjs';
|
|
2
|
+
export { A as ArtifactsStorePublic, a as createArtifactsStorePublic } from './artifacts-store-lib-public-C5UL5tyG.cjs';
|
|
3
|
+
import './storage-interface-B6ecOulj.cjs';
|
|
4
4
|
import './execution-refs.cjs';
|
|
5
5
|
import './types-BBhqYGhE.cjs';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import './board-live-cards-public-
|
|
2
|
-
export { A as ArtifactsStorePublic, a as createArtifactsStorePublic } from './artifacts-store-lib-public-
|
|
3
|
-
import './storage-interface-
|
|
1
|
+
import './board-live-cards-public-BZaNb2mi.js';
|
|
2
|
+
export { A as ArtifactsStorePublic, a as createArtifactsStorePublic } from './artifacts-store-lib-public-GD4H-fFp.js';
|
|
3
|
+
import './storage-interface-B6ecOulj.js';
|
|
4
4
|
import './execution-refs.js';
|
|
5
5
|
import './types-BBhqYGhE.js';
|