wicked-core-ts 0.7.2 → 0.7.3

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 (2) hide show
  1. package/index.d.ts +39 -2
  2. package/package.json +6 -6
package/index.d.ts CHANGED
@@ -169,6 +169,41 @@ export declare class Core {
169
169
  * `decline`/`cancel`. Resolves to `"ok"` on success, rejects if no matching elicitation exists.
170
170
  */
171
171
  resolveElicitation(runId: string, elicitationId: string, action: string, response?: any | undefined | null): Promise<string>
172
+ /**
173
+ * Validate + launch a campaign — a DAG of Runs (DES-CAMPAIGN-001). `defJson` is a
174
+ * `CampaignDef` JSON object in the engine wire shape (snake_case): `{ id, name?, nodes:
175
+ * [{ node_id, run_spec: { problem, clis, entity_mode, human_confirm?, repo_ref?,
176
+ * workflow_id? } }], edges?: [{ from, to, condition? }], policy?, max_concurrency }`.
177
+ * Resolves to the campaign id. Fire-and-forget: independent nodes dispatch immediately and
178
+ * progress arrives as the `campaign*` CoreEvents — `subscribe()` first. Rejects a cycle /
179
+ * empty / duplicate-edge / unknown-edge-endpoint def at launch, before anything persists.
180
+ */
181
+ launchCampaign(defJson: string): Promise<string>
182
+ /**
183
+ * Resume a campaign from its persisted state (after a pause, crash, or a fresh process) —
184
+ * the scheduler re-derives the ready set from the persisted node statuses and re-attaches
185
+ * any mid-run node, never re-running a completed node. Resolves to the campaign status
186
+ * token (`running` | `paused` | `completed` | `partially_completed` | `failed` |
187
+ * `cancelled`); rejects for an unknown id.
188
+ */
189
+ resumeCampaign(id: string): Promise<string>
190
+ /**
191
+ * Cancel a campaign — cancel every in-flight node's Run and mark the rest `Cancelled`.
192
+ * Resolves to the campaign status token; rejects for an unknown id.
193
+ */
194
+ cancelCampaign(id: string): Promise<string>
195
+ /**
196
+ * A campaign's full state — the DAG (embedded def), per-node statuses, per-node run ids and
197
+ * attempt counters — as a JSON `Campaign` object (engine wire shape, snake_case), or the
198
+ * JSON literal `null` when the id is unknown. The read a DAG/scoreboard view builds from.
199
+ */
200
+ campaignDetail(id: string): Promise<string>
201
+ /**
202
+ * Every campaign on the store, as a JSON array of `Campaign` objects. Read-only store
203
+ * connection (the `project_list` pattern) — the single-writer actor is not involved, so a
204
+ * long campaign list cannot queue behind dispatch work.
205
+ */
206
+ campaignList(): Promise<string>
172
207
  /** The agent session ids currently on the store, as a JSON array of strings. */
173
208
  sessions(): Promise<string>
174
209
  /**
@@ -349,8 +384,10 @@ export declare class Core {
349
384
  * bookkeeping store (FINDING-009). `get_coverage_report` above reads `self.db_path` (the daemon
350
385
  * `core.db`), which holds run/governance nodes but none of a repo's domain/requirement nodes, so
351
386
  * it reports a vacuous `coverage: 1.0` over an empty denominator and cannot name a repo. This
352
- * resolves the repo from the registry, opens its `code_graph_db` (`<root>/.codegraph/estate.db`,
353
- * the one spelling every consumer shares), and recomputes over it. An unknown `repo_ref` is an
387
+ * resolves the repo from the registry, opens its `code_graph_db` (the engine-resolved path
388
+ * every consumer shares the legacy in-tree `<root>/.codegraph/estate.db` for a repo that
389
+ * already has one, else the estate home's `<estate_root>/<key>/estate.db`; see wicked-core's
390
+ * `code_graph.rs` ADR), and recomputes over it. An unknown `repo_ref` is an
354
391
  * ERROR, never a silent vacuous report — the caller must name a real repo.
355
392
  * Resolves to the coverage report as a JSON string (`ts_return_type` pins it — the crew adapter
356
393
  * used to cast away an `unknown` here; #225 review).
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "wicked-core-ts",
3
- "version": "0.7.2",
3
+ "version": "0.7.3",
4
4
  "description": "Node/TypeScript bindings (napi-rs) for wicked-core: drive the in-process orchestration engine from JS/TS.",
5
5
  "license": "MIT",
6
6
  "repository": {
@@ -41,11 +41,11 @@
41
41
  "smoke:all": "node smoke.mjs && node smoke-lifecycle.mjs && node smoke-terminal.mjs"
42
42
  },
43
43
  "optionalDependencies": {
44
- "wicked-core-ts-darwin-arm64": "0.7.2",
45
- "wicked-core-ts-darwin-x64": "0.7.2",
46
- "wicked-core-ts-linux-arm64-gnu": "0.7.2",
47
- "wicked-core-ts-linux-x64-gnu": "0.7.2",
48
- "wicked-core-ts-win32-x64-msvc": "0.7.2"
44
+ "wicked-core-ts-darwin-arm64": "0.7.3",
45
+ "wicked-core-ts-darwin-x64": "0.7.3",
46
+ "wicked-core-ts-linux-arm64-gnu": "0.7.3",
47
+ "wicked-core-ts-linux-x64-gnu": "0.7.3",
48
+ "wicked-core-ts-win32-x64-msvc": "0.7.3"
49
49
  },
50
50
  "devDependencies": {
51
51
  "@napi-rs/cli": "^2.18.4"