@darkhorseprojects/circuitry 0.4.0 → 0.4.2
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/dist/cli.js +7346 -9
- package/dist/index.d.ts +1 -8
- package/dist/index.js +7404 -821
- package/dist/resolve.d.ts +9 -0
- package/dist/resolve.js +7548 -0
- package/package.json +8 -6
- package/dist/bundle.d.ts +0 -32
- package/dist/host.d.ts +0 -41
- package/dist/node.d.ts +0 -58
- package/dist/node.js +0 -824
- package/dist/presets.d.ts +0 -4
- package/dist/runtime.d.ts +0 -16
- package/dist/scheduler.d.ts +0 -30
- package/dist/simulation.d.ts +0 -89
- package/dist/tools.d.ts +0 -553
- package/dist/types.d.ts +0 -41
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@darkhorseprojects/circuitry",
|
|
3
|
-
"version": "0.4.
|
|
3
|
+
"version": "0.4.2",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"main": "./dist/index.js",
|
|
6
6
|
"types": "./dist/index.d.ts",
|
|
@@ -9,9 +9,9 @@
|
|
|
9
9
|
"types": "./dist/index.d.ts",
|
|
10
10
|
"import": "./dist/index.js"
|
|
11
11
|
},
|
|
12
|
-
"./
|
|
13
|
-
"types": "./dist/
|
|
14
|
-
"import": "./dist/
|
|
12
|
+
"./resolve": {
|
|
13
|
+
"types": "./dist/resolve.d.ts",
|
|
14
|
+
"import": "./dist/resolve.js"
|
|
15
15
|
}
|
|
16
16
|
},
|
|
17
17
|
"bin": {
|
|
@@ -36,8 +36,10 @@
|
|
|
36
36
|
"type": "git",
|
|
37
37
|
"url": "git+https://github.com/darkhorseprojects/circuitry.git"
|
|
38
38
|
},
|
|
39
|
-
"dependencies": {
|
|
40
|
-
|
|
39
|
+
"dependencies": {},
|
|
40
|
+
"devDependencies": {
|
|
41
|
+
"@types/node": "^20.11.0",
|
|
42
|
+
"typescript": "^5.3.3",
|
|
41
43
|
"yaml": "^2.8.4",
|
|
42
44
|
"zod": "^3.25.76"
|
|
43
45
|
}
|
package/dist/bundle.d.ts
DELETED
|
@@ -1,32 +0,0 @@
|
|
|
1
|
-
type SceneElement = {
|
|
2
|
-
id: string;
|
|
3
|
-
type: string;
|
|
4
|
-
x?: number;
|
|
5
|
-
y?: number;
|
|
6
|
-
frameId?: string | null;
|
|
7
|
-
containerId?: string | null;
|
|
8
|
-
boundElements?: readonly {
|
|
9
|
-
id: string;
|
|
10
|
-
type: string;
|
|
11
|
-
}[] | null;
|
|
12
|
-
startBinding?: {
|
|
13
|
-
elementId?: string;
|
|
14
|
-
} | null;
|
|
15
|
-
endBinding?: {
|
|
16
|
-
elementId?: string;
|
|
17
|
-
} | null;
|
|
18
|
-
};
|
|
19
|
-
export declare const BUNDLE_MIME = "application/vnd.circuitry.bundle+yaml";
|
|
20
|
-
export type CircuitryBundle = {
|
|
21
|
-
version: 1;
|
|
22
|
-
createdAt: string;
|
|
23
|
-
elements: SceneElement[];
|
|
24
|
-
};
|
|
25
|
-
export declare const createBundleFromSelection: (elements: readonly SceneElement[], selectedIds: Readonly<Record<string, true>>) => CircuitryBundle | null;
|
|
26
|
-
export declare const stringifyBundle: (bundle: CircuitryBundle) => string;
|
|
27
|
-
export declare const parseBundleText: (text: string) => CircuitryBundle;
|
|
28
|
-
export declare const importBundleElements: (bundle: CircuitryBundle, opts?: {
|
|
29
|
-
offsetX?: number;
|
|
30
|
-
offsetY?: number;
|
|
31
|
-
}) => SceneElement[];
|
|
32
|
-
export {};
|
package/dist/host.d.ts
DELETED
|
@@ -1,41 +0,0 @@
|
|
|
1
|
-
import type { CircuitryGraph, CircuitryRuntimeInputs, CircuitryValidationResult, CircuitryValidationStandard } from "./graph";
|
|
2
|
-
import type { SimulationRunItem } from "./simulation";
|
|
3
|
-
export interface CircuitryHost {
|
|
4
|
-
readGraph(input: {
|
|
5
|
-
filename?: string;
|
|
6
|
-
}): Promise<{
|
|
7
|
-
filename: string;
|
|
8
|
-
graph: CircuitryGraph;
|
|
9
|
-
text: string;
|
|
10
|
-
lastRun?: any;
|
|
11
|
-
}>;
|
|
12
|
-
validateGraph(input: {
|
|
13
|
-
text?: string;
|
|
14
|
-
filename?: string;
|
|
15
|
-
graph?: CircuitryGraph;
|
|
16
|
-
standard?: CircuitryValidationStandard;
|
|
17
|
-
}): Promise<CircuitryValidationResult>;
|
|
18
|
-
writeGraph(input: {
|
|
19
|
-
text?: string;
|
|
20
|
-
filename?: string;
|
|
21
|
-
graph?: CircuitryGraph;
|
|
22
|
-
mode?: "replace";
|
|
23
|
-
standard?: CircuitryValidationStandard;
|
|
24
|
-
}): Promise<{
|
|
25
|
-
filename: string;
|
|
26
|
-
graph: CircuitryGraph;
|
|
27
|
-
mode: "replace";
|
|
28
|
-
}>;
|
|
29
|
-
runGraph(input: {
|
|
30
|
-
source?: "current" | "text";
|
|
31
|
-
text?: string;
|
|
32
|
-
filename?: string;
|
|
33
|
-
selectedNodeId?: string;
|
|
34
|
-
inputs?: CircuitryRuntimeInputs;
|
|
35
|
-
standard?: CircuitryValidationStandard;
|
|
36
|
-
hostModel?: string;
|
|
37
|
-
}): Promise<{
|
|
38
|
-
completedAt: string;
|
|
39
|
-
runItems: SimulationRunItem[];
|
|
40
|
-
}>;
|
|
41
|
-
}
|
package/dist/node.d.ts
DELETED
|
@@ -1,58 +0,0 @@
|
|
|
1
|
-
import type { CircuitryHost } from "./host";
|
|
2
|
-
import type { CircuitryGraph, CircuitryRuntimeInputs, CircuitryValidationStandard } from "./graph";
|
|
3
|
-
import type { NodeExecutionRequest, NodeExecutionResult, SimulationRunItem } from "./simulation";
|
|
4
|
-
export declare const runNodeWithPiSDK: ({ model, prompt, images, tools, }: NodeExecutionRequest) => Promise<NodeExecutionResult>;
|
|
5
|
-
export type CircuitryResourceOrigins = Record<string, string>;
|
|
6
|
-
export type LoadedCircuitryGraph = {
|
|
7
|
-
filename: string;
|
|
8
|
-
text: string;
|
|
9
|
-
graph: CircuitryGraph;
|
|
10
|
-
origins: CircuitryResourceOrigins;
|
|
11
|
-
};
|
|
12
|
-
export declare const loadCircuitryGraphFile: (filename?: string, standard?: CircuitryValidationStandard, stack?: string[]) => Promise<LoadedCircuitryGraph>;
|
|
13
|
-
export declare class NodeCircuitryHost implements CircuitryHost {
|
|
14
|
-
private resolveGraphFile;
|
|
15
|
-
private runFileFor;
|
|
16
|
-
private exists;
|
|
17
|
-
private parseIssue;
|
|
18
|
-
private parseSourceGraph;
|
|
19
|
-
private parseAndResolveGraph;
|
|
20
|
-
private readGraphFile;
|
|
21
|
-
readGraph(input?: {
|
|
22
|
-
filename?: string;
|
|
23
|
-
}): Promise<{
|
|
24
|
-
filename: string;
|
|
25
|
-
graph: CircuitryGraph;
|
|
26
|
-
text: string;
|
|
27
|
-
lastRun: unknown;
|
|
28
|
-
}>;
|
|
29
|
-
validateGraph(input: {
|
|
30
|
-
text?: string;
|
|
31
|
-
filename?: string;
|
|
32
|
-
graph?: CircuitryGraph;
|
|
33
|
-
standard?: CircuitryValidationStandard;
|
|
34
|
-
}): Promise<import("./graph").CircuitryValidationResult>;
|
|
35
|
-
writeGraph(input: {
|
|
36
|
-
text?: string;
|
|
37
|
-
filename?: string;
|
|
38
|
-
graph?: CircuitryGraph;
|
|
39
|
-
mode?: "replace";
|
|
40
|
-
standard?: CircuitryValidationStandard;
|
|
41
|
-
}): Promise<{
|
|
42
|
-
filename: string;
|
|
43
|
-
graph: CircuitryGraph;
|
|
44
|
-
mode: "replace";
|
|
45
|
-
}>;
|
|
46
|
-
runGraph(input?: {
|
|
47
|
-
source?: "current" | "text";
|
|
48
|
-
text?: string;
|
|
49
|
-
filename?: string;
|
|
50
|
-
selectedNodeId?: string;
|
|
51
|
-
inputs?: CircuitryRuntimeInputs;
|
|
52
|
-
standard?: CircuitryValidationStandard;
|
|
53
|
-
hostModel?: string;
|
|
54
|
-
}): Promise<{
|
|
55
|
-
completedAt: string;
|
|
56
|
-
runItems: SimulationRunItem[];
|
|
57
|
-
}>;
|
|
58
|
-
}
|