@opengeni/ogtool 0.3.29-canary.0 → 0.3.31-canary.0

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
@@ -23,13 +23,58 @@ to disk. `ogtool doctor` reports the selected delivery mode without printing the
23
23
 
24
24
  Commands:
25
25
 
26
- - `ogtool list`
26
+ - `ogtool list` — a bounded page of callable paths and short descriptions, one tool per line
27
+ - `ogtool list --json` — compact JSON with `catalogDigest`, `total`, `offset`, `nextOffset`, and `tools: [{path, description}]`
28
+ - `ogtool list [--json] [--query <substring>] [--limit <1..100>] [--offset <integer>]`
29
+ - `ogtool list --full` — the previous full catalog JSON, including identity and schemas
30
+ - `ogtool show <tool-path-or-model-name>` — one tool's details and schemas as JSON
27
31
  - `ogtool call <tool-path-or-model-name> [json-object]`
28
32
  - `ogtool declarations [output-file]`
29
33
  - `ogtool doctor`
30
34
  - `ogtool --version`
31
35
 
36
+ Start with `list`, then use `show docs.search` before constructing a call. Compact
37
+ descriptions collapse whitespace and use at most 160 Unicode code points, including
38
+ an ellipsis when shortened; a missing/empty description falls back to the title.
39
+ Text mode displays C0, C1, and DEL control characters as literal `\uNNNN` escapes
40
+ so descriptions and title fallbacks cannot execute terminal control sequences.
41
+ The byte budget includes this escape expansion. This is text-only presentation:
42
+ catalog content, query matching, and explicit JSON/full/schema output remain unchanged.
43
+ Catalog order and callable paths are preserved. Compact output contains no identities,
44
+ schemas, approval annotations, or attempt IDs. JSON includes the frozen catalog digest
45
+ so a machine caller can detect a changed catalog between pages.
46
+
47
+ Compact pages default to at most 50 tools; `--limit` accepts 1 through 100. The complete
48
+ stdout page, including JSON escaping, metadata, text continuation hints, and final
49
+ newline, is at most 16 KiB. The CLI drops trailing entries until it fits, never
50
+ truncates a callable path, and fails clearly if even one entry cannot fit. The
51
+ catalog's maximum valid callable path fits this bound.
52
+
53
+ `--query` is a literal, case-sensitive substring match against the callable path or
54
+ full whitespace-normalized description (title fallback), including text beyond the
55
+ displayed summary. An empty query matches all tools. `total` counts filtered matches;
56
+ `--offset` is a nonnegative safe integer within that filtered order, not the unfiltered
57
+ catalog. Follow the returned `nextOffset` rather than adding your requested limit:
58
+ the byte cap may return fewer tools. Keep the query unchanged and verify the JSON
59
+ `catalogDigest` is unchanged when walking pages. `nextOffset: null` means finished.
60
+ Empty/no-match/past-end pages return no tools and no next offset; text still prints
61
+ the total/offset footer. Both `--flag value` and `--flag=value` are supported.
62
+
63
+ `--full` rejects `--json`, `--query`, `--limit`, and `--offset`, including explicitly
64
+ supplied defaults. Unknown/duplicate flags and extra arguments are errors.
65
+ `show` accepts the same exact path/model-name/identity aliases as `call`
66
+ and rejects unknown or ambiguous names. Its JSON output (including the final newline)
67
+ is limited to 64 KiB; oversized details fail without partial output or schema
68
+ truncation. Use `list --full` redirected to a file, or `declarations <output-file>`,
69
+ for larger schemas. Existing scripts parsing the old `list` JSON must use `list --full`.
70
+
71
+ The Connected Machine fallback, `"$OPENGENI_CODEMODE_NATIVE_CLIENT" codemode`,
72
+ supports the same `list`, `list --json`, `list --full`, and `show` discovery behavior.
73
+ It does not provide the JavaScript CLI's `declarations` command.
74
+
32
75
  The HTTP client submits a caller-chosen operation id and polls the durable result. A lost response
33
76
  therefore cannot silently replay a side effect. `@opengeni/ogtool` also re-exports the typed
34
77
  `@opengeni/codemode` client for application code. Codemode is a projection of the attempt's one
35
- tool authority, not a second tool or credential surface.
78
+ tool authority, not a second tool or credential surface. Aborting the CLI/client wait stops only
79
+ local observation; it does not cancel a journaled server operation, which must be reconciled by the
80
+ same operation id or settled by the owning attempt lifecycle.