@insmind/cli 1.3.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.
Files changed (153) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +11 -0
  3. package/contracts/operations/agent.send/input.schema.json +335 -0
  4. package/contracts/operations/agent.send/output.schema.json +248 -0
  5. package/contracts/operations/auth.status/input.schema.json +7 -0
  6. package/contracts/operations/auth.status/output.schema.json +119 -0
  7. package/contracts/operations/dam.copy/input.schema.json +42 -0
  8. package/contracts/operations/dam.copy/output.schema.json +43 -0
  9. package/contracts/operations/dam.delete/input.schema.json +24 -0
  10. package/contracts/operations/dam.delete/output.schema.json +5 -0
  11. package/contracts/operations/dam.download/input.schema.json +28 -0
  12. package/contracts/operations/dam.download/output.schema.json +51 -0
  13. package/contracts/operations/dam.folder.list/input.schema.json +36 -0
  14. package/contracts/operations/dam.folder.list/output.schema.json +104 -0
  15. package/contracts/operations/dam.get/input.schema.json +16 -0
  16. package/contracts/operations/dam.get/output.schema.json +107 -0
  17. package/contracts/operations/dam.list/input.schema.json +73 -0
  18. package/contracts/operations/dam.list/output.schema.json +145 -0
  19. package/contracts/operations/dam.move/input.schema.json +42 -0
  20. package/contracts/operations/dam.move/output.schema.json +40 -0
  21. package/contracts/operations/dam.rename/input.schema.json +42 -0
  22. package/contracts/operations/dam.rename/output.schema.json +43 -0
  23. package/contracts/operations/dam.repository.list/input.schema.json +7 -0
  24. package/contracts/operations/dam.repository.list/output.schema.json +65 -0
  25. package/contracts/operations/dam.search/input.schema.json +79 -0
  26. package/contracts/operations/dam.search/output.schema.json +145 -0
  27. package/contracts/operations/dam.tag.list/input.schema.json +21 -0
  28. package/contracts/operations/dam.tag.list/output.schema.json +52 -0
  29. package/contracts/operations/dam.upload/input.schema.json +43 -0
  30. package/contracts/operations/dam.upload/output.schema.json +107 -0
  31. package/contracts/operations/editor.apply/input.schema.json +177 -0
  32. package/contracts/operations/editor.apply/output.schema.json +15 -0
  33. package/contracts/operations/editor.connect/input.schema.json +13 -0
  34. package/contracts/operations/editor.connect/output.schema.json +17 -0
  35. package/contracts/operations/editor.disconnect/input.schema.json +7 -0
  36. package/contracts/operations/editor.disconnect/output.schema.json +14 -0
  37. package/contracts/operations/editor.save/input.schema.json +7 -0
  38. package/contracts/operations/editor.save/output.schema.json +23 -0
  39. package/contracts/operations/editor.screenshot/input.schema.json +7 -0
  40. package/contracts/operations/editor.screenshot/output.schema.json +16 -0
  41. package/contracts/operations/editor.snapshot/input.schema.json +7 -0
  42. package/contracts/operations/editor.snapshot/output.schema.json +148 -0
  43. package/contracts/operations/model.get/input.schema.json +16 -0
  44. package/contracts/operations/model.get/output.schema.json +167 -0
  45. package/contracts/operations/model.list/input.schema.json +13 -0
  46. package/contracts/operations/model.list/output.schema.json +97 -0
  47. package/contracts/operations/task.get/input.schema.json +14 -0
  48. package/contracts/operations/task.get/output.schema.json +103 -0
  49. package/contracts/operations/task.list/input.schema.json +18 -0
  50. package/contracts/operations/task.list/output.schema.json +53 -0
  51. package/contracts/operations/tool.call/input.schema.json +31 -0
  52. package/contracts/operations/tool.call/output.schema.json +115 -0
  53. package/contracts/operations/tool.list/input.schema.json +6 -0
  54. package/contracts/operations/tool.list/output.schema.json +40 -0
  55. package/dist/bin/agent-worker.js +41 -0
  56. package/dist/bin/insmind-cli.js +60 -0
  57. package/dist/bin/postinstall.js +69 -0
  58. package/dist/src/bootstrap/create-cli.js +124 -0
  59. package/dist/src/bootstrap/create-runtime.js +451 -0
  60. package/dist/src/bootstrap/run-agent-worker.js +37 -0
  61. package/dist/src/bootstrap/validators.js +169 -0
  62. package/dist/src/cli/action-binding.js +109 -0
  63. package/dist/src/cli/agent-commands.js +75 -0
  64. package/dist/src/cli/auth-commands.js +58 -0
  65. package/dist/src/cli/credits-command.js +23 -0
  66. package/dist/src/cli/dam-commands.js +470 -0
  67. package/dist/src/cli/editor-commands.js +74 -0
  68. package/dist/src/cli/errors.js +208 -0
  69. package/dist/src/cli/model-commands.js +62 -0
  70. package/dist/src/cli/org-commands.js +58 -0
  71. package/dist/src/cli/presenter.js +123 -0
  72. package/dist/src/cli/prompt.js +30 -0
  73. package/dist/src/cli/task-commands.js +48 -0
  74. package/dist/src/cli/tool-commands.js +101 -0
  75. package/dist/src/cli/update-command.js +15 -0
  76. package/dist/src/contracts/schema.js +4 -0
  77. package/dist/src/features/agent/creative-agent-adapter.js +42 -0
  78. package/dist/src/features/agent/creative-protocol.js +421 -0
  79. package/dist/src/features/agent/creative-stream.js +138 -0
  80. package/dist/src/features/agent/filems-resource-auth-key-provider.js +23 -0
  81. package/dist/src/features/agent/resource-authorizer.js +47 -0
  82. package/dist/src/features/agent/result-reader.js +30 -0
  83. package/dist/src/features/agent/use-cases.js +153 -0
  84. package/dist/src/features/auth/access-policy.js +101 -0
  85. package/dist/src/features/auth/credential-store.js +62 -0
  86. package/dist/src/features/auth/sso-service.js +196 -0
  87. package/dist/src/features/auth/state.js +129 -0
  88. package/dist/src/features/auth/use-cases.js +162 -0
  89. package/dist/src/features/credits/use-cases.js +52 -0
  90. package/dist/src/features/dam/asset-projection.js +278 -0
  91. package/dist/src/features/dam/dam-api-adapter.js +562 -0
  92. package/dist/src/features/dam/file-downloader.js +242 -0
  93. package/dist/src/features/dam/object-storage.js +193 -0
  94. package/dist/src/features/dam/operation-executor.js +72 -0
  95. package/dist/src/features/dam/registered-uploader.js +247 -0
  96. package/dist/src/features/dam/repository-catalog.js +127 -0
  97. package/dist/src/features/dam/storage-upload.js +141 -0
  98. package/dist/src/features/dam/transient-uploader.js +17 -0
  99. package/dist/src/features/dam/use-cases.js +470 -0
  100. package/dist/src/features/editor/bridge-client.js +109 -0
  101. package/dist/src/features/editor/bridge-process.js +229 -0
  102. package/dist/src/features/editor/bridge-server.js +337 -0
  103. package/dist/src/features/editor/protocol.js +1 -0
  104. package/dist/src/features/editor/public-url.js +36 -0
  105. package/dist/src/features/editor/session-state.js +78 -0
  106. package/dist/src/features/editor/session.js +213 -0
  107. package/dist/src/features/editor/use-cases.js +88 -0
  108. package/dist/src/features/org/org-service.js +76 -0
  109. package/dist/src/features/org/use-cases.js +163 -0
  110. package/dist/src/features/skill/bundled-skills.js +63 -0
  111. package/dist/src/features/skill/installer.js +271 -0
  112. package/dist/src/features/task/agent-background.js +63 -0
  113. package/dist/src/features/task/store.js +97 -0
  114. package/dist/src/features/task/types.js +1 -0
  115. package/dist/src/features/task/use-cases.js +139 -0
  116. package/dist/src/features/tool/catalog.js +83 -0
  117. package/dist/src/features/tool/dynamic-schema.js +128 -0
  118. package/dist/src/features/tool/mns-catalog-adapter.js +265 -0
  119. package/dist/src/features/tool/tool-api-adapter.js +369 -0
  120. package/dist/src/features/tool/use-cases.js +180 -0
  121. package/dist/src/features/update/latest-version.js +37 -0
  122. package/dist/src/features/update/update-notification.js +271 -0
  123. package/dist/src/features/update/update-service.js +226 -0
  124. package/dist/src/platform/installation-owner.js +81 -0
  125. package/dist/src/platform/json-input.js +67 -0
  126. package/dist/src/platform/local-json-file.js +59 -0
  127. package/dist/src/platform/open-browser.js +8 -0
  128. package/dist/src/platform/redact.js +80 -0
  129. package/dist/src/platform/remote-error-evidence.js +80 -0
  130. package/dist/src/platform/remote-protocol.js +10 -0
  131. package/dist/src/platform/resource-auth-key.js +1 -0
  132. package/dist/src/platform/safe-upload-file.js +146 -0
  133. package/dist/src/platform/signature.js +20 -0
  134. package/dist/src/platform/signed-http-transport.js +144 -0
  135. package/dist/src/platform/task-observer.js +1 -0
  136. package/dist/src/platform/url-safety.js +100 -0
  137. package/dist/src/product/billing.js +47 -0
  138. package/dist/src/product/config.js +85 -0
  139. package/dist/src/product/locale.js +38 -0
  140. package/dist/src/product/text.js +3 -0
  141. package/dist/src/telemetry/invocation.js +156 -0
  142. package/dist/src/telemetry/sls-sink.js +30 -0
  143. package/package.json +53 -0
  144. package/skills/insmind-cli/SKILL.md +15 -0
  145. package/skills/insmind-cli/references/agent.md +34 -0
  146. package/skills/insmind-cli/references/auth.md +8 -0
  147. package/skills/insmind-cli/references/creation.md +40 -0
  148. package/skills/insmind-cli/references/dam.md +51 -0
  149. package/skills/insmind-cli/references/editor.md +184 -0
  150. package/skills/insmind-cli/references/errors.md +29 -0
  151. package/skills/insmind-cli/references/generation-constraints.md +36 -0
  152. package/skills/insmind-cli/references/tool.md +31 -0
  153. package/skills/insmind-cli/references/update.md +11 -0
@@ -0,0 +1,184 @@
1
+ # AI+ Editor
2
+
3
+ ## Scope
4
+
5
+ Use `insmind-cli editor` to inspect and operate one current AI+ Editor work in a browser. This version supports one Editor Session, direct Shapes and Connectors on the current Page, and serial operations by one operator.
6
+
7
+ Supported Shapes: `rectangle`, `rounded-rectangle`, `triangle-up`, `ellipse`, `diamond`. A Connector binds one Shape to another and uses `straight` or `elbowed` lineType. Groups, images, videos, standalone text, nested elements, free or half-bound Connectors, connector labels, endpoint coordinates, selection changes and page management are unsupported.
8
+
9
+ If the current Page has unsupported direct elements, snapshot, apply and screenshot return `UNSUPPORTED_PAGE_CONTENT`. Stop and ask the user to use a blank or dedicated Page; preserve the existing work.
10
+
11
+ ## Workflow
12
+
13
+ 1. Connect with `insmind-cli editor connect [target]`. Omit target to create a production Board, provide a numeric work ID to open a work, or provide a supported insMind production Editor URL. Use the form matching the user's target. Connection succeeds only after browser login, work loading, Board type, edit/save permissions and page-content checks pass. Stop on a connection failure.
14
+ 2. Read `insmind-cli editor snapshot`.
15
+ 3. Build a complete, ordered Action JSON array from that Snapshot and run `insmind-cli editor apply --input actions.json`, or use `--input -` for stdin.
16
+ 4. Read a fresh Snapshot after each Apply. For layout, text or Connector changes, also run `insmind-cli editor screenshot --json` and view the actual PNG at the returned absolute `path`. A file's existence or an accepted Action does not prove correct rendering.
17
+ 5. After structural and visual checks pass, run `insmind-cli editor save --json`. Only a successful save proves persistence; deliver its returned `workId` and public `url`. A new Board receives its work ID on the first explicit save. Preserve any environment parameters in the returned URL. Save waits for real persistence and may take up to 5 minutes 30 seconds. Keep waiting for the command and do not issue concurrent Editor operations.
18
+ 6. Run `insmind-cli editor disconnect` after saving.
19
+
20
+ Connecting replaces the old Session and opens the work. A failed precheck clears the attempted Session but leaves the browser page open. The user handles browser login or access issues, then reconnects. CLI credentials do not replace browser AI+ login. If the SPA loads or switches works, the Session disconnects; reconnect to the intended work before editing.
21
+
22
+ ## Verify the work
23
+
24
+ Use the latest post-Apply Snapshot for fields and relationships, and the actual screenshot for paths, text and layout. Check all of the following:
25
+
26
+ - Each Connector's `fromId` and `toId` point to the intended Shapes in the correct semantic direction.
27
+ - Every visible path starts and ends at the corresponding Shape boundaries without crossing endpoint fill or text. Check adjacent collinear connectors individually.
28
+ - Connectors avoid unrelated Shapes, unexplained detours, reversals and wrong links.
29
+ - Text remains readable without clipping, overflow or unintended wrapping.
30
+ - Shapes, text and Connectors have the intended spacing and do not overlap unexpectedly.
31
+ - The reading direction and composition make relationships easy to follow.
32
+
33
+ When a fix is actionable, read the latest Snapshot first and submit full element Updates, never patches. If correct Connector IDs still produce a path crossing an endpoint, resubmit that Connector's full Update to trigger native path recalculation; preserve correct business relationships. Read a new Snapshot and screenshot after visual changes. Save when no actionable issue remains.
34
+
35
+ ## Snapshot contract
36
+
37
+ ```ts
38
+ type FocusedPageSnapshot = {
39
+ elements: Array<FocusedShape | FocusedConnector>;
40
+ selectedIds: string[];
41
+ };
42
+
43
+ type FocusedShape = {
44
+ _type: "shape";
45
+ id: string;
46
+ shapeType:
47
+ | "rectangle"
48
+ | "rounded-rectangle"
49
+ | "triangle-up"
50
+ | "ellipse"
51
+ | "diamond";
52
+ x: number;
53
+ y: number;
54
+ w: number;
55
+ h: number;
56
+ text?: string;
57
+ fill: string;
58
+ stroke: string | null;
59
+ };
60
+
61
+ type FocusedConnector = {
62
+ _type: "connector";
63
+ id: string;
64
+ fromId: string;
65
+ toId: string;
66
+ lineType: "straight" | "elbowed";
67
+ color: string;
68
+ };
69
+ ```
70
+
71
+ `x` and `y` locate the Shape's top-left corner in Page coordinates; `w` and `h` are its dimensions. `selectedIds` is read-only. Use short semantic IDs such as `start`, `review`, and `start-to-review`; the Bridge maps them to internal Editor IDs. Connector endpoints express a directed relationship.
72
+
73
+ ## Action contract
74
+
75
+ ```ts
76
+ type FocusedEditorAction =
77
+ | { _type: "create"; element: FocusedShape | FocusedConnector }
78
+ | { _type: "update"; element: FocusedShape | FocusedConnector }
79
+ | { _type: "delete"; id: string };
80
+ ```
81
+
82
+ - Input is a JSON array applied in order.
83
+ - Create IDs must be unique. A Connector can reference a Shape created earlier in the same array.
84
+ - Update supplies the entire element and cannot change `id` or `_type`.
85
+ - Delete requires an existing ID; deleting a Shape also removes its bound Connectors.
86
+ - Extra fields are rejected. Numbers must be finite; `w` and `h` must exceed zero.
87
+ - Colors use `#RRGGBB` or `#RRGGBBAA`. Only Shape `stroke` accepts `null`.
88
+ - The whole batch is validated before one rollback-capable transaction. An invalid Action prevents all writes; correct it before submitting.
89
+
90
+ ## Example
91
+
92
+ This array creates a left-to-right Start → Review? → Done flowchart:
93
+
94
+ ```json
95
+ [
96
+ {
97
+ "_type": "create",
98
+ "element": {
99
+ "_type": "shape",
100
+ "id": "start",
101
+ "shapeType": "rounded-rectangle",
102
+ "x": 80,
103
+ "y": 160,
104
+ "w": 180,
105
+ "h": 80,
106
+ "text": "Start",
107
+ "fill": "#ffffff",
108
+ "stroke": "#222222"
109
+ }
110
+ },
111
+ {
112
+ "_type": "create",
113
+ "element": {
114
+ "_type": "shape",
115
+ "id": "review",
116
+ "shapeType": "diamond",
117
+ "x": 360,
118
+ "y": 140,
119
+ "w": 140,
120
+ "h": 120,
121
+ "text": "Review?",
122
+ "fill": "#f2f6ff",
123
+ "stroke": "#222222"
124
+ }
125
+ },
126
+ {
127
+ "_type": "create",
128
+ "element": {
129
+ "_type": "shape",
130
+ "id": "done",
131
+ "shapeType": "rounded-rectangle",
132
+ "x": 600,
133
+ "y": 160,
134
+ "w": 180,
135
+ "h": 80,
136
+ "text": "Done",
137
+ "fill": "#e8f7ed",
138
+ "stroke": "#222222"
139
+ }
140
+ },
141
+ {
142
+ "_type": "create",
143
+ "element": {
144
+ "_type": "connector",
145
+ "id": "start-to-review",
146
+ "fromId": "start",
147
+ "toId": "review",
148
+ "lineType": "straight",
149
+ "color": "#222222"
150
+ }
151
+ },
152
+ {
153
+ "_type": "create",
154
+ "element": {
155
+ "_type": "connector",
156
+ "id": "review-to-done",
157
+ "fromId": "review",
158
+ "toId": "done",
159
+ "lineType": "straight",
160
+ "color": "#222222"
161
+ }
162
+ }
163
+ ]
164
+ ```
165
+
166
+ For existing elements, start from their complete latest Snapshot objects, change only the intended fields, and submit full Updates.
167
+
168
+ ## Failures
169
+
170
+ - `LOGIN_REQUIRED`: stop editing and let the user sign in on the opened AI+ page, then reconnect. CLI login cannot replace it.
171
+ - `EDITOR_NOT_READY`: check loading and reconnect; do not write until connection succeeds.
172
+ - `WORK_NOT_EDITABLE`: stop; the current user lacks editing or saving permission.
173
+ - `EDITOR_SESSION_NOT_FOUND`: reconnect to the target and read a Snapshot.
174
+ - `EDITOR_NOT_CONNECTED`: reconnect to the target rather than polling the old Session.
175
+ - `UNSUPPORTED_PAGE_CONTENT`: stop and request a blank or dedicated Page.
176
+ - `INVALID_ACTIONS`: correct the Actions from this contract and a fresh Snapshot; do not retry unchanged.
177
+ - `APPLY_FAILED`: the batch rolled back; read the Snapshot and confirm the prior state before proceeding.
178
+ - `EDITOR_ROLLBACK_FAILED`: stop apply and save; inspect only through Snapshot/screenshots and report the uncertainty.
179
+ - `SAVE_FAILED`: retain the Session, address the stated cause and retry save if appropriate; do not claim it is saved before success.
180
+ - `EDITOR_BUSY`: wait for the current command and keep operations serial.
181
+ - `EDITOR_RPC_TIMEOUT`: execution status is unknown and the Bridge closes. Ordinary RPCs wait one minute; Save allows 5 minutes 30 seconds. Reads may reconnect to the same work and retry. For apply or save, reconnect to the same work and inspect its real state first; stop if inspection is impossible.
182
+ - `PROTOCOL_VERSION_MISMATCH`: stop and update insMind CLI or use an Editor with the matching protocol.
183
+
184
+ A timed-out, cancelled or disconnected write may already have been submitted. Observe the real state before recovery to avoid duplicate creation, Apply or Save.
@@ -0,0 +1,29 @@
1
+ # Output and errors
2
+
3
+ - `stdout` contains results only. Parse structured command JSON directly.
4
+ - `stderr` contains warnings, authorization notices and errors. Keep them separate from results.
5
+ - Exit `0`: success.
6
+ - Exit `1`: runtime, service or state failure. Follow explicit `error.details.next_steps`; if none are provided, stop and report.
7
+ - Exit `2`: command or argument error. Read the command's `--help` and correct the invocation.
8
+ - Exit `130`: user interruption. Stop immediately; do not retry automatically.
9
+ - `INSUFFICIENT_CREDITS`: follow `error.details.next_steps`, direct the user to https://www.insmind.com/pricing, and submit again only after credits are available. Use `insmind-cli credits` to inspect the balance.
10
+
11
+ ## Missing creation output
12
+
13
+ If an Agent or Tool request may already have been submitted, empty output, long execution or a host's completed-script message does not justify another creation. The original command prints a Task ID to stderr. Continue waiting if its execution session remains available; otherwise query the original task:
14
+
15
+ ```bash
16
+ insmind-cli task list
17
+ insmind-cli task get <id>
18
+ ```
19
+
20
+ Use a known ID directly. Otherwise locate the task by time, operation and input summary. Ask the user when multiple candidates cannot be distinguished; do not automatically pick the newest.
21
+
22
+ - `completed`: deliver `result`; use its `message.contextId` for continuation.
23
+ - `running`: the original execution is updating or the Tool is processing. Query the same ID again after a few seconds.
24
+ - `unknown`: completion is unconfirmed. Recheck the same ID; explain if it remains unknown. `partialResult` is a message snapshot, not a complete deliverable.
25
+ - `failed`: report `note` and the original error; do not resubmit automatically.
26
+
27
+ Exit `0` from `task get` means the query succeeded; `state` determines whether the creation completed. Repeated reads of one ID return the same usage, which must not be added again. Do not resume waiting or resubmit after a user interruption.
28
+
29
+ Do not infer internal causes from unknown errors or disclose local credentials, request signatures or sensitive URL query values. If safe recovery steps are absent, preserve the public error code from stderr and explain the failure.
@@ -0,0 +1,36 @@
1
+ # Generation constraints and media roles
2
+
3
+ Use one Generation Constraints Part for a model and dynamic parameters. `model` is the machine identifier; copy parameter fields and values from `model get` and preserve the user's choices:
4
+
5
+ ```json
6
+ {
7
+ "message": {
8
+ "parts": [
9
+ { "text": "<user request>" },
10
+ {
11
+ "data": {
12
+ "model": "<model>",
13
+ "arguments": {
14
+ "resolution": "2K"
15
+ }
16
+ }
17
+ }
18
+ ]
19
+ }
20
+ }
21
+ ```
22
+
23
+ `arguments` can be supplied without `model`, allowing the service Agent to select one. With a model, the CLI validates the supplied arguments against live detail; do not fill every Tool-required parameter for an Agent request. Put prompt text in a Text Part and media in separate URL Parts, not in `arguments`. Preserve input Part order. Use `metadata.role` for `reference`, `first_frame` or `last_frame`; do not inject frame-role text. For example:
24
+
25
+ ```json
26
+ {
27
+ "message": {
28
+ "parts": [
29
+ { "text": "Generate a transition video" },
30
+ { "url": "file:///absolute/first.png", "metadata": { "role": "first_frame" } },
31
+ { "url": "file:///absolute/last.png", "metadata": { "role": "last_frame" } },
32
+ { "data": { "model": "<model>", "arguments": { "mode": "<value>" } } }
33
+ ]
34
+ }
35
+ }
36
+ ```
@@ -0,0 +1,31 @@
1
+ # Tool creation
2
+
3
+ For long creation work, submit once with `--async`, then query the returned `taskId` with `insmind-cli task get <taskId>`. Repeat queries while running; read `result` only when completed. An empty response, query timeout, unknown state, or host session ending is not a reason to generate again. If the ID is missing, use `task list` to locate the original task. The default command still waits for its result; keep waiting on that same process. See [status handling](errors.md).
4
+
5
+ Discover live metadata in this order:
6
+
7
+ ```bash
8
+ insmind-cli tool list
9
+ insmind-cli model list --tool <tool>
10
+ insmind-cli model get <model>
11
+ insmind-cli tool call <tool> --input request.json --async
12
+ insmind-cli task get <taskId>
13
+ ```
14
+
15
+ `tool list` lists available Tools. Model discovery provides current descriptions, prices, estimated duration and structured parameters. Follow each parameter's `required`, `type` and `description`; for SELECT parameters use `options[].value`. Explicitly supply a required parameter's `default` when the user did not specify it. Read `usageDescription` for combinations such as video mode and frame/media requirements; individual fields cannot establish these rules. Do not freeze catalog values in prompts or scripts.
16
+
17
+ Provide all required fields. Put width, height, resolution and similar requirements in dedicated structured parameters when available, rather than only in prompt text. `tool call <tool> --schema` is the parameter union of all models in the Tool; after selecting a model, use its `model get` parameters and `usageDescription`.
18
+
19
+ Copy the returned `model` identifier into the top-level `model` field of request JSON (runtime `arguments.model`), alongside its parameters:
20
+
21
+ ```json
22
+ {
23
+ "model": "<model>",
24
+ "prompt": "<required prompt>",
25
+ "<parameter>": "<value>"
26
+ }
27
+ ```
28
+
29
+ Success returns `content` and `usage`. Content contains text or resource links; usage identifies the model and the published credit price range, not an actual charge.
30
+
31
+ Keep each resource link, returned name, local path and display name together. Preserve the association through downloads, renames and reordering; do not pair results by request order. Check each final link's content against its name before delivery, viewing the resource when necessary.
@@ -0,0 +1,11 @@
1
+ # Update
2
+
3
+ ```bash
4
+ insmind-cli update
5
+ ```
6
+
7
+ This command checks npm `latest` for `@insmind/cli`, updates supported global npm or pnpm installations, and synchronizes the bundled `insmind-cli` Agent Skill even when the CLI is already current. npm enables lifecycle scripts only for this package with `--allow-scripts=@insmind/cli`; pnpm uses `--allow-build=@insmind/cli`.
8
+
9
+ Normal CLI use checks for updates at most once an hour and shows at most one notice per local day. Run `insmind-cli update` after a notice. Automatic checks neither install updates nor repair the Skill; `CI=true` disables checks.
10
+
11
+ For an installation managed by a host connector, follow the update command's channel-specific instructions so the host keeps its CLI and Skill versions matched. The command takes no arguments and has no `--json`. Unsupported installations receive explicit global npm or pnpm installation instructions. If the CLI updated but Skill verification failed, keep the new CLI version, follow stderr recovery steps and rerun the update command.