@moda-ai/cli 1.55.10 → 1.55.12

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.
@@ -0,0 +1,19 @@
1
+ import {
2
+ parseScopeInt,
3
+ pullSkills,
4
+ runSkillSync,
5
+ runSkillsCommand
6
+ } from "./cli-y8gbbe9k.js";
7
+ import"./cli-4x9w6ey7.js";
8
+ import"./cli-k7vwt56h.js";
9
+ import"./cli-ryd7nzke.js";
10
+ import"./cli-09rr5smg.js";
11
+ import"./cli-kwz900s4.js";
12
+ import"./cli-ssfq84k5.js";
13
+ import"./cli-0v6na3yp.js";
14
+ export {
15
+ runSkillsCommand,
16
+ runSkillSync,
17
+ pullSkills,
18
+ parseScopeInt
19
+ };
@@ -0,0 +1,54 @@
1
+ import {
2
+ runPromptsCommand
3
+ } from "./cli-90hb4ng0.js";
4
+ import"./cli-mm48br00.js";
5
+ import {
6
+ runHarnessCommand
7
+ } from "./cli-m0fa54ny.js";
8
+ import"./cli-97fnztpy.js";
9
+ import {
10
+ runSkillsCommand
11
+ } from "./cli-y8gbbe9k.js";
12
+ import"./cli-4x9w6ey7.js";
13
+ import"./cli-k7vwt56h.js";
14
+ import"./cli-ryd7nzke.js";
15
+ import"./cli-09rr5smg.js";
16
+ import {
17
+ CliInputError
18
+ } from "./cli-kwz900s4.js";
19
+ import"./cli-ssfq84k5.js";
20
+ import"./cli-0v6na3yp.js";
21
+
22
+ // src/sync.ts
23
+ async function runSyncCommand(context) {
24
+ const resource = context.positionals[0] ?? "harness";
25
+ const rest = context.positionals.slice(1);
26
+ if (resource === "harness") {
27
+ return runHarnessCommand({
28
+ ...context,
29
+ command: "harness",
30
+ positional: "sync",
31
+ positionals: ["sync", ...rest]
32
+ });
33
+ }
34
+ if (resource === "prompts") {
35
+ await runPromptsCommand(["sync", ...rest], context.flags, {
36
+ profile: context.profile,
37
+ env: context.env
38
+ });
39
+ return { exitCode: 0 };
40
+ }
41
+ if (resource === "skills") {
42
+ const exitCode = await runSkillsCommand({
43
+ ...context,
44
+ command: "skills",
45
+ positional: "pull",
46
+ positionals: ["pull", ...rest]
47
+ });
48
+ return { exitCode };
49
+ }
50
+ throw new CliInputError(`Unknown sync resource '${resource}'.`, "Usage: moda sync [harness|prompts|skills] [--dry-run] [--profile=NAME]");
51
+ }
52
+ export {
53
+ runSyncCommand
54
+ };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@moda-ai/cli",
3
- "version": "1.55.10",
3
+ "version": "1.55.12",
4
4
  "description": "CLI for Moda: production monitoring and evals for AI agents.",
5
5
  "type": "module",
6
6
  "bin": {
@@ -56,11 +56,8 @@
56
56
  },
57
57
  "dependencies": {
58
58
  "@inquirer/prompts": "^8.4.1",
59
- "fast-glob": "^3.3.3",
60
59
  "open": "^11.0.0",
61
- "yaml": "^2.9.1",
62
- "zod": "^3.25.76",
63
- "@modelcontextprotocol/sdk": "^1.30.0"
60
+ "zod": "^3.25.76"
64
61
  },
65
62
  "devDependencies": {
66
63
  "@moda/database": "*",
@@ -69,10 +66,13 @@
69
66
  "@moda/harness-snapshot": "*",
70
67
  "@moda/integration-skills": "*",
71
68
  "@moda/messaging": "*",
69
+ "@modelcontextprotocol/sdk": "^1.30.0",
72
70
  "@types/node": "^22.10.5",
73
71
  "eslint": "^9.17.0",
72
+ "fast-glob": "^3.3.3",
74
73
  "typescript": "^5.7.2",
75
- "vitest": "^4.0.14"
74
+ "vitest": "^4.0.14",
75
+ "yaml": "^2.9.1"
76
76
  },
77
77
  "engines": {
78
78
  "node": ">=18.0.0"
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "schema_version": "moda.skill_index.v1",
3
- "bundled_at": "2026-10-15T04:43:16.280Z",
4
- "cli_version": "1.55.10",
3
+ "bundled_at": "2026-10-15T05:06:16.495Z",
4
+ "cli_version": "1.55.12",
5
5
  "skills": [
6
6
  {
7
7
  "id": "integration-cloudflare-think",
@@ -276,9 +276,9 @@ Branch on the exit code; it is stable and cheaper than parsing the payload:
276
276
  | Exit | Meaning | How to treat it |
277
277
  |---|---|---|
278
278
  | `0` | ok — answer is grounded in Moda Cloud intelligence | Trust it. |
279
- | `1` | error — bad input, API/network failure, or unexpected failure | Read `errors[]`; retry only when the code is retryable. |
279
+ | `1` | error — bad input, unknown id (`not_found`), access denied, API/network failure | Read `errors[0].code`; retry only `network_error` / 5xx `api_error`. For `not_found`, find a valid id first (the `cause` names the command). |
280
280
  | `3` | degraded — Moda Cloud was unavailable; answer synthesized from local Data API evidence | Answer is present but lower-trust; verify before acting. |
281
- | `4` | auth required — credentials are missing or expired | Run the `login_command` from the `auth` payload (`moda auth login`), then re-run `resume_command`. |
281
+ | `4` | auth required — no API key, or the API rejected it (HTTP 401) | Set `MODA_API_KEY` or run the `login_command` from the `auth` payload (`moda auth login --api-key`), then re-run. |
282
282
  | `5` | input required — a choice is needed that the non-interactive run could not answer | Pick a choice from the `input_request` payload and re-invoke the same command with that choice's `resume_flags` appended. |
283
283
  | `130` | cancelled | Treat as interrupted or closed pipe; do not retry blindly. |
284
284
 
@@ -1302,8 +1302,14 @@ moda feedback "trace is a refund request, not this problem" \
1302
1302
  from local evidence — not a failure (`investigate`/`failures` always exit
1303
1303
  `0` on success). Treat exit `1` as the only hard error (see
1304
1304
  [Agent protocol](#agent-protocol)).
1305
- - Errors print to stderr with non-zero exit. Check stderr before claiming
1306
- success.
1305
+ - Errors exit non-zero. In agent/JSON mode the error envelope is printed to
1306
+ stdout (`status: "error"`, `errors[0].code`), even with `--quiet`; human
1307
+ mode prints prose to stderr. Check the exit code before claiming success.
1308
+ - An unknown trace, problem, or cluster id exits 1 with
1309
+ `errors[0].code: "not_found"`; it is not an empty success.
1310
+ - `moda world-state` returns success with a warning when state is missing.
1311
+ This can mean an unknown trace or a real trace without generated state.
1312
+ Use `moda context <id> --metadata-only` to check whether the trace exists.
1307
1313
  - If the JSON has `"conversations": []` or `"frustrations": []`, the call
1308
1314
  worked but the time window is empty — widen `--days-back` before
1309
1315
  concluding "no data".