@melite/engine-contract 0.1.5-pre-alpha → 0.2.2-alpha

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 CHANGED
@@ -1,8 +1,3 @@
1
- ---
2
- description: The engine Service Definition — the engines seat, engine-agnostic stage types, and the pinned engine-id vocabulary every engine adapter and the runs lane share.
3
- kind: package-library
4
- ---
5
-
6
1
  # @melite/engine-contract
7
2
 
8
3
  `@melite/engine-contract` declares the one contract every run-path engine
package/lib/index.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- export type { EngineParamValue, EngineStageRow, EngineStageOutcome, EngineRunOutcome, EngineRunOptions, EngineExecutor, EngineRecord, } from "./types.js";
1
+ export type { EngineParamValue, EngineStageRow, EngineStageOutcome, EngineRunOutcome, EngineRunOptions, EngineExecutor, EngineRecord, EngineRef, } from "./types.js";
2
2
  export type { PortSpec, ParamSpec, ActionSpec } from "./vocabulary.js";
3
3
  export { AGENT_ENGINE_ID, COMFYUI_ENGINE_ID, CRAFT_ENGINE_ID, EnginesService, engineIdOk, enginesContract, } from "./engines.js";
4
4
  export { enginesContract as default } from "./engines.js";
package/lib/types.d.ts CHANGED
@@ -30,12 +30,25 @@ export interface EngineStageOutcome {
30
30
  readonly outputs: Readonly<Record<string, EngineParamValue>>;
31
31
  readonly artifacts: readonly string[];
32
32
  }
33
+ declare const BRAND: unique symbol;
34
+ /** A string carrying a compile-time-only brand B (the
35
+ * @deepseek-ai/dsh-brand mechanics, declared local — see the block
36
+ * comment above). */
37
+ type Branded<B extends string> = string & {
38
+ readonly [BRAND]: B;
39
+ };
40
+ /** The engine's own handle for one submitted run (ComfyUI's
41
+ * promptId). Minted ONCE at the transport that pulled it off the
42
+ * wire (comfyui-cordis's /prompt POST), de-branded by nothing —
43
+ * the ledger stores the string it already is. */
44
+ export type EngineRef = Branded<"EngineRef">;
33
45
  /** A whole submit's outcome. `engineRef` is the engine's own
34
46
  * handle for the submitted work (ComfyUI's promptId) — opaque to
35
- * the consumer, carried for the ledger. */
47
+ * the consumer, carried for the ledger; branded at its producer
48
+ * (the dsh-brand convention), never a bare string. */
36
49
  export interface EngineRunOutcome {
37
50
  readonly stages: readonly EngineStageOutcome[];
38
- readonly engineRef?: string;
51
+ readonly engineRef?: EngineRef;
39
52
  /** THE REPLAY VERDICT (D11): true when the executor's seated tap
40
53
  * folded zero engine events before settlement — the engine served
41
54
  * memo'd outputs without executing. Optional so existing
@@ -80,4 +93,5 @@ export interface EngineRecord {
80
93
  readonly executor: EngineExecutor;
81
94
  readonly probe?: () => Promise<void>;
82
95
  }
96
+ export {};
83
97
  //# sourceMappingURL=types.d.ts.map
@@ -14,10 +14,14 @@ export interface PortSpec<K extends string = string> {
14
14
  * random, and the one minter resolves it so every node sharing the
15
15
  * seed shares the minted value. A variant preset pinning a param
16
16
  * the surface does not offer, or a value outside the envelope,
17
- * refuses at the family door. */
17
+ * refuses at the family door. `"image"` is the SCALAR media seat —
18
+ * the value is a media path (a string at the wire), the form face
19
+ * is the picker + upload square, never freehand text (the NO-DROP
20
+ * law's write half: run-899a8448 typed a stage name into a media
21
+ * seat that declared as plain string). */
18
22
  export interface ParamSpec {
19
23
  readonly name: string;
20
- readonly type: "number" | "string" | "boolean" | "enum" | "image_list";
24
+ readonly type: "number" | "string" | "boolean" | "enum" | "image" | "image_list";
21
25
  readonly bounds?: readonly [number, number];
22
26
  readonly options?: readonly string[];
23
27
  readonly rule?: "seed-sentinel";
package/package.json CHANGED
@@ -1,9 +1,9 @@
1
1
  {
2
2
  "name": "@melite/engine-contract",
3
- "version": "0.1.5-pre-alpha",
4
- "license": "SSPL-1.0",
3
+ "version": "0.2.2-alpha",
4
+ "license": "AGPL-3.0-or-later",
5
5
  "type": "module",
6
- "description": "The engine Service Definition (stroke 53, the engine-generics seam): one registry seat every engine provider registers into and every run-path consumer resolves through — ComfyUI today, MCP servers (blender/unity/godot) next. Stage rows are engine-agnostic; graph surgery (spliceWorkflow) stays inside the owning engine's executor. Source-plane TS (erasable syntax, no build step).",
6
+ "description": "The engine Service Definition — the engines seat, engine-agnostic stage types, and the pinned engine-id vocabulary every engine adapter and the runs lane share.",
7
7
  "exports": {
8
8
  ".": {
9
9
  "types": "./lib/index.d.ts",
@@ -23,23 +23,34 @@
23
23
  },
24
24
  "./package.json": "./package.json"
25
25
  },
26
- "devDependencies": {
27
- "@types/node": "^22.20.0",
28
- "typescript": "^5.9.3",
29
- "@deepseek-ai/cordis": "^4.0.4"
30
- },
31
26
  "files": [
32
27
  "lib/index.js",
33
28
  "lib/**/*.js",
34
29
  "lib/**/*.d.ts"
35
30
  ],
36
31
  "peerDependencies": {
37
- "@deepseek-ai/cordis": "^4.0.4"
32
+ "@deepseek-ai/cordis": "^4.0.5"
33
+ },
34
+ "repository": {
35
+ "type": "git",
36
+ "url": "https://github.com/JayDataEngineer/melite.git",
37
+ "directory": "packages/engines/contract"
38
38
  },
39
+ "keywords": [
40
+ "melite",
41
+ "comfyui",
42
+ "cordis",
43
+ "agent",
44
+ "media-generation",
45
+ "library"
46
+ ],
39
47
  "scripts": {
40
48
  "build": "tsc -p tsconfig.build.json",
41
49
  "typecheck": "tsc --noEmit"
42
50
  },
51
+ "engines": {
52
+ "node": ">=22.18.0"
53
+ },
43
54
  "publishConfig": {
44
55
  "access": "public"
45
56
  }