@letterstory/cli 0.25.5 → 0.25.6

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/lib/cli.mjs CHANGED
@@ -44,7 +44,7 @@ import {
44
44
  } from "./commands.mjs";
45
45
 
46
46
  // Keep in sync with cli/package.json.
47
- export const VERSION = "0.25.5";
47
+ export const VERSION = "0.25.6";
48
48
 
49
49
  // Flags that never take a value. Listing them explicitly means `deploy get --json <id>`
50
50
  // can't accidentally swallow the id as --json's value.
@@ -455,10 +455,13 @@ Seers (event-driven signals -> drafts):
455
455
  seers list List seers with recent activity
456
456
  seers get <seer-id> One seer's full config + poll state
457
457
  seers providers Provider catalog: config fields + behavior keys
458
- seers create --name <n> --collection <uuid> --provider <p>
458
+ seers create --name <n> --provider <p> [--collection <uuid>]
459
459
  [--mode suggest|auto] [--interval <min>] [--config '<json>'|--config-file <path>]
460
- seers update <seer-id> [--name] [--collection] [--mode] [--enabled true|false]
461
- [--interval <min>] [--config '<json>'|--config-file <path>]
460
+ --collection is optional: omit it for a
461
+ detect-only seer (scans + judges, never
462
+ produces). --mode auto requires one.
463
+ seers update <seer-id> [--name] [--collection <uuid> | --clear-collection] [--mode]
464
+ [--enabled true|false] [--interval <min>] [--config '<json>'|--config-file <path>]
462
465
  seers delete <seer-id> --yes
463
466
  seers run <seer-id> [--dry-run] [--no-produce] [--async]
464
467
  Run now — THE DOOR (one seer run from the balance).
@@ -16,6 +16,16 @@ import { readFileSync, writeFileSync } from "node:fs";
16
16
  import { CliError } from "../client.mjs";
17
17
  import { flagStr, flagBool, requirePositional, printResult, ok, argsFromFlags } from "./shared.mjs";
18
18
 
19
+ // A single-value flag the API clears with an explicit `null` (same idiom as
20
+ // strategy.mjs's clearableList): `--clear-collection` sends null, `--collection <uuid>`
21
+ // sends it, neither sends nothing (no change).
22
+ const clearableValue = (flag, clearFlag) => ({
23
+ value: (flags) => {
24
+ if (flags[clearFlag]) return null;
25
+ return flagStr(flags[flag]);
26
+ },
27
+ });
28
+
19
29
  /**
20
30
  * How the ratcheted commands in this file source their tool inputs — see `argsFromFlags` in
21
31
  * shared.mjs and `scripts/parity-check.ts`. The rest of the module predates the field-level
@@ -46,7 +56,9 @@ export const ARGS = {
46
56
  },
47
57
  create_seer: {
48
58
  name: { flag: "name", required: true },
49
- collection_id: { flag: "collection", required: true },
59
+ // Optional (2026-09-18): omit it for a detect-only seer — it can scan and judge
60
+ // forever but never produce (auto mode is rejected without one).
61
+ collection_id: { flag: "collection" },
50
62
  provider: { flag: "provider", required: true },
51
63
  mode: { flag: "mode", enum: ["suggest", "auto"] },
52
64
  poll_interval_minutes: { flag: "interval", type: "num" },
@@ -57,7 +69,9 @@ export const ARGS = {
57
69
  update_seer: {
58
70
  seer_id: { positional: 0, label: "seer-id", required: true },
59
71
  name: { flag: "name" },
60
- collection_id: { flag: "collection" },
72
+ // --collection <uuid> sets it, --clear-collection sends null (the seer becomes
73
+ // detect-only — rejected if it's mode "auto"), neither leaves it unchanged.
74
+ collection_id: clearableValue("collection", "clear-collection"),
61
75
  mode: { flag: "mode", enum: ["suggest", "auto"] },
62
76
  enabled: { value: (flags) => readEnabledFlag(flags) },
63
77
  poll_interval_minutes: { flag: "interval", type: "num" },
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@letterstory/cli",
3
- "version": "0.25.5",
3
+ "version": "0.25.6",
4
4
  "description": "Spin up and manage Letterstory phantom blogs from your terminal.",
5
5
  "type": "module",
6
6
  "license": "UNLICENSED",