@realtimex/sdk 2.0.4 → 2.0.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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@realtimex/sdk",
3
- "version": "2.0.4",
3
+ "version": "2.0.6",
4
4
  "description": "SDK for building Local Apps that integrate with RealtimeX",
5
5
  "main": "dist/index.js",
6
6
  "module": "dist/index.mjs",
@@ -25,6 +25,7 @@
25
25
  "sdk:generate:force": "node ../scripts/generate-v1-sdk.mjs --force",
26
26
  "sdk:diff": "node ../scripts/generate-v1-sdk.mjs --dry-run",
27
27
  "skill:generate": "node ../scripts/generate-skill.mjs --force",
28
+ "skill:local-test": "node ../scripts/local-test-realtimex-skill.mjs",
28
29
  "pp-cli:build": "node ../scripts/build-pp-cli-packages.mjs",
29
30
  "pp-cli:publish": "node ../scripts/publish-pp-cli-packages.mjs",
30
31
  "prepublishOnly": "npm run build && npm run skill:generate"
@@ -16,177 +16,85 @@ metadata:
16
16
 
17
17
  ## Prerequisites: Install the CLI
18
18
 
19
- This skill drives the `realtimex-pp-cli` binary. Verify the CLI is installed before invoking any command from this skill. If it is missing, install it first:
19
+ This skill drives the `realtimex-pp-cli` binary. Verify the CLI is installed and exactly matches this skill's SDK version before invoking any command from this skill. If it is missing or the version does not match, reinstall the pinned version first:
20
20
 
21
- 1. Install via npm:
21
+ 1. Install or reinstall the pinned version via npm:
22
22
  ```bash
23
- npm install -g @realtimex/pp-cli@2.0.4
23
+ npm install -g @realtimex/pp-cli@2.0.6
24
24
  ```
25
- 2. Verify: `realtimex-pp-cli --version`
25
+ 2. Verify the exact version:
26
+ ```bash
27
+ realtimex-pp-cli --version
28
+ ```
29
+ The output must be `realtimex-pp-cli 2.0.6`.
26
30
 
27
- If `--version` reports "command not found" after install, the npm global bin directory is not on `$PATH`. Do not proceed with skill commands until verification succeeds.
31
+ If `--version` reports "command not found" after install, the npm global bin directory is not on `$PATH`. If it reports any version other than `2.0.6`, reinstall with the pinned npm command above. Do not proceed with skill commands until exact-version verification succeeds.
28
32
 
29
33
  ## Command Reference
30
34
 
31
- **chat-feedback** — Manage chat feedback
32
-
33
- - `realtimex-pp-cli chat-feedback <slug> <chatId>` — Update workspace chat feedback.
34
-
35
- **chats** — Manage chats
36
-
37
- - `realtimex-pp-cli chats <slug>` — Get workspace chats.
38
-
39
- **config** — Manage config
40
-
41
- - `realtimex-pp-cli config get-workspace` — Get or create workspace config.
42
- - `realtimex-pp-cli config update-workspace` — Update workspace config.
43
-
44
- **delete-chats** — Manage delete chats
45
-
46
- - `realtimex-pp-cli delete-chats <slug>` — Delete selected workspace chats.
47
-
48
- **delete-edited-chats** — Manage delete edited chats
49
-
50
- - `realtimex-pp-cli delete-edited-chats <slug>` — Delete edited workspace chats from a starting id.
51
-
52
- **document** — Manage document
53
-
54
- - `realtimex-pp-cli document <slug> <docPath>` — Get document content for a workspace document.
55
-
56
- **linked-terminal-message** — Manage linked terminal message
57
-
58
- - `realtimex-pp-cli linked-terminal-message <slug>` — Persist a linked terminal message.
59
-
60
- **llm-provider** — Manage llm provider
61
-
62
- - `realtimex-pp-cli llm-provider <slug>` — Get workspace LLM provider metadata.
63
-
64
- **local-llm-tuning-suggestion** — Manage local llm tuning suggestion
65
-
66
- - `realtimex-pp-cli local-llm-tuning-suggestion <slug>` — Generate a local LLM tuning suggestion.
67
-
68
- **pfp** — Manage pfp
69
-
70
- - `realtimex-pp-cli pfp <slug>` — Get a workspace profile picture.
71
-
72
- **prompt-history** — Manage prompt history
73
-
74
- - `realtimex-pp-cli prompt-history delete-workspace` — Clear workspace prompt history.
75
- - `realtimex-pp-cli prompt-history delete-workspace-entry` — Delete a workspace prompt history entry.
76
- - `realtimex-pp-cli prompt-history get-workspace` — Get workspace prompt history.
77
-
78
- **realtimex-developer-search** — Manage realtimex developer search
79
-
80
- - `realtimex-pp-cli realtimex-developer-search <slug>` — Validate search provider configuration.
81
-
82
- **remove-and-unembed** — Manage remove and unembed
35
+ **clear-workspace-default-agent** — Manage clear workspace default agent
83
36
 
84
- - `realtimex-pp-cli remove-and-unembed <slug>` — Remove and unembed a document.
37
+ - `realtimex-pp-cli clear-workspace-default-agent <workspaceSlug>` — Clear the default CLI agent from a workspace.
85
38
 
86
- **remove-pfp** — Manage remove pfp
39
+ **create-thread** — Manage create thread
87
40
 
88
- - `realtimex-pp-cli remove-pfp <slug>` — Remove a workspace profile picture.
41
+ - `realtimex-pp-cli create-thread <workspaceSlug>` — Create a thread in one workspace. The name is optional but recommended.
89
42
 
90
- **reset-vector-db** — Manage reset vector db
43
+ **create-workspace** — Manage create workspace
91
44
 
92
- - `realtimex-pp-cli reset-vector-db <slug>` Reset workspace vector database records.
45
+ - `realtimex-pp-cli create-workspace`Create a workspace. Requires a human-readable workspace name.
93
46
 
94
- **stream-chat** — Manage stream chat
47
+ **delete-thread** — Manage delete thread
95
48
 
96
- - `realtimex-pp-cli stream-chat <slug>` — Stream a chat response for a workspace default thread.
49
+ - `realtimex-pp-cli delete-thread <workspaceSlug> <threadSlug>` — Delete one thread by exact workspace slug and exact thread slug.
97
50
 
98
- **suggested-messages** — Manage suggested messages
51
+ **delete-workspace** — Manage delete workspace
99
52
 
100
- - `realtimex-pp-cli suggested-messages get-workspace`Get suggested messages for a workspace.
101
- - `realtimex-pp-cli suggested-messages save-workspace` — Save suggested messages for a workspace.
53
+ - `realtimex-pp-cli delete-workspace <workspaceSlug>` Delete one workspace by exact workspace slug.
102
54
 
103
- **terminal-goal** — Manage terminal goal
55
+ **get-thread** — Manage get thread
104
56
 
105
- - `realtimex-pp-cli terminal-goal <slug>` — Create a terminal goal for a workspace.
57
+ - `realtimex-pp-cli get-thread <workspaceSlug> <threadSlug>` — Get one thread by exact workspace slug and exact thread slug.
106
58
 
107
- **terminal-goal-draft** — Manage terminal goal draft
59
+ **get-workspace** — Manage get workspace
108
60
 
109
- - `realtimex-pp-cli terminal-goal-draft <slug>` — Draft a terminal goal for a workspace.
61
+ - `realtimex-pp-cli get-workspace <workspaceSlug>` — Get one workspace by exact workspace slug.
110
62
 
111
- **terminal-session-details** — Manage terminal session details
63
+ **list-llm-models** — Manage list llm models
112
64
 
113
- - `realtimex-pp-cli terminal-session-details <slug>` — Get workspace terminal session details.
65
+ - `realtimex-pp-cli list-llm-models <provider>` — List models for one provider id. Use an exact model id from this response with send-llm-message.
114
66
 
115
- **terminal-ui-events** — Manage terminal ui events
67
+ **list-llm-providers** — Manage list llm providers
116
68
 
117
- - `realtimex-pp-cli terminal-ui-events <slug>` Persist terminal UI events.
69
+ - `realtimex-pp-cli list-llm-providers`List supported LLM providers. Use provider ids from this response with list-llm-models and send-llm-message.
118
70
 
119
- **thread** — Manage thread
71
+ **list-threads** — Manage list threads
120
72
 
121
- - `realtimex-pp-cli thread coordinate-task`Coordinate a task into a workspace thread.
122
- - `realtimex-pp-cli thread create` — Create a workspace thread.
123
- - `realtimex-pp-cli thread delete` — Delete a workspace thread.
124
- - `realtimex-pp-cli thread fork` — Fork the workspace default thread.
125
- - `realtimex-pp-cli thread get` — Get a workspace thread.
73
+ - `realtimex-pp-cli list-threads <workspaceSlug>` List threads for one exact workspace slug.
126
74
 
127
- **thread-bulk-delete** — Manage thread bulk delete
75
+ **list-workspaces** — Manage list workspaces
128
76
 
129
- - `realtimex-pp-cli thread-bulk-delete <slug>` Bulk delete workspace threads.
77
+ - `realtimex-pp-cli list-workspaces`List all workspaces visible to the current API caller. Use this before choosing a workspace slug.
130
78
 
131
- **thread-events** — Manage thread events
79
+ **prepare** — Manage prepare
132
80
 
133
- - `realtimex-pp-cli thread-events <slug>` Open an SSE stream for workspace thread events.
81
+ - `realtimex-pp-cli prepare` — Return compact workspace, thread, LLM provider, model, and CLI agent context for agents before choosing arguments.
134
82
 
135
- **threads** — Manage threads
83
+ **rename-thread** — Manage rename thread
136
84
 
137
- - `realtimex-pp-cli threads <slug>` — List workspace threads.
85
+ - `realtimex-pp-cli rename-thread <workspaceSlug> <threadSlug>` — Rename one thread by exact workspace slug and exact thread slug. Only the name is changed.
138
86
 
139
- **tts** — Manage tts
87
+ **rename-workspace** — Manage rename workspace
140
88
 
141
- - `realtimex-pp-cli tts <slug> <chatId>` — Generate text-to-speech audio for a workspace chat.
89
+ - `realtimex-pp-cli rename-workspace <workspaceSlug>` — Rename one workspace by exact workspace slug. Only the name is changed.
142
90
 
143
- **update** — Manage update
91
+ **send-llm-message** — Manage send llm message
144
92
 
145
- - `realtimex-pp-cli update <slug>` — Update workspace settings by slug.
93
+ - `realtimex-pp-cli send-llm-message <workspaceSlug> <threadSlug>` — Send one non-streaming LLM message to an exact thread.
146
94
 
147
- **update-chat** — Manage update chat
95
+ **set-workspace-default-agent** — Manage set workspace default agent
148
96
 
149
- - `realtimex-pp-cli update-chat <slug>` — Update a workspace chat response.
150
-
151
- **update-embeddings** — Manage update embeddings
152
-
153
- - `realtimex-pp-cli update-embeddings <slug>` — Update workspace document embeddings.
154
-
155
- **update-pin** — Manage update pin
156
-
157
- - `realtimex-pp-cli update-pin <slug>` — Update workspace document pin status.
158
-
159
- **upload** — Manage upload
160
-
161
- - `realtimex-pp-cli upload <slug>` — Upload a document to workspace documents.
162
-
163
- **upload-and-embed** — Manage upload and embed
164
-
165
- - `realtimex-pp-cli upload-and-embed <slug>` — Upload and embed a document.
166
-
167
- **upload-link** — Manage upload link
168
-
169
- - `realtimex-pp-cli upload-link <slug>` — Upload a link to workspace documents.
170
-
171
- **upload-pfp** — Manage upload pfp
172
-
173
- - `realtimex-pp-cli upload-pfp <slug>` — Upload a workspace profile picture.
174
-
175
- **vision-availability** — Manage vision availability
176
-
177
- - `realtimex-pp-cli vision-availability <slug>` — Get workspace vision availability.
178
-
179
- **workspace** — Manage workspace
180
-
181
- - `realtimex-pp-cli workspace create` — Create a workspace using the app workspace creation behavior.
182
- - `realtimex-pp-cli workspace delete` — Delete a workspace.
183
- - `realtimex-pp-cli workspace get` — Get a workspace by slug.
184
- - `realtimex-pp-cli workspace hide-chat` — Hide a workspace chat.
185
- - `realtimex-pp-cli workspace search` — Search workspaces and threads.
186
-
187
- **workspaces** — Manage workspaces
188
-
189
- - `realtimex-pp-cli workspaces` — List workspaces using the app workspace list behavior.
97
+ - `realtimex-pp-cli set-workspace-default-agent <workspaceSlug>` — Set the default CLI agent for a workspace.
190
98
 
191
99
 
192
100
  ### Finding the right command
@@ -206,7 +114,7 @@ Run `realtimex-pp-cli auth setup` to print the URL and steps for getting a key (
206
114
  export REALTIMEX_APP_ID_AUTH="<your-key>"
207
115
  ```
208
116
 
209
- Or persist it in `~/.config/realtimex-developer-pp-cli/config.toml`.
117
+ Or persist it in `~/.config/realtimex-cli-pp-cli/config.toml`.
210
118
 
211
119
  Run `realtimex-pp-cli doctor` to verify setup.
212
120
 
@@ -218,7 +126,7 @@ Add `--agent` to any command. Expands to: `--json --compact --no-input --no-colo
218
126
  - **Filterable** — `--select` keeps a subset of fields. Dotted paths descend into nested structures; arrays traverse element-wise. Critical for keeping context small on verbose APIs:
219
127
 
220
128
  ```bash
221
- realtimex-pp-cli thread get mock-value mock-value --agent --select id,name,status
129
+ realtimex-pp-cli clear-workspace-default-agent mock-value --agent --select id,name,status
222
130
  ```
223
131
  - **Previewable** — `--dry-run` shows the request without sending
224
132
  - **Offline-friendly** — sync/search commands can use the local SQLite store when available
@@ -270,7 +178,7 @@ A profile is a saved set of flag values, reused across invocations. Use it when
270
178
 
271
179
  ```
272
180
  realtimex-pp-cli profile save briefing --json
273
- realtimex-pp-cli --profile briefing thread get mock-value mock-value
181
+ realtimex-pp-cli --profile briefing clear-workspace-default-agent mock-value
274
182
  realtimex-pp-cli profile list --json
275
183
  realtimex-pp-cli profile show briefing
276
184
  realtimex-pp-cli profile delete briefing --yes
@@ -310,8 +218,15 @@ Verify: `claude mcp list`
310
218
 
311
219
  ## Direct Use
312
220
 
313
- 1. Check if installed: `which realtimex-pp-cli`
314
- If not found, offer to install (see Prerequisites at the top of this skill).
221
+ 1. Check whether the CLI is installed and version-matched:
222
+ ```bash
223
+ realtimex-pp-cli --version
224
+ ```
225
+ If the command is missing or the output is not exactly `realtimex-pp-cli 2.0.6`, reinstall the pinned version:
226
+ ```bash
227
+ npm install -g @realtimex/pp-cli@2.0.6
228
+ ```
229
+ Then run `realtimex-pp-cli --version` again and proceed only after exact-version verification succeeds.
315
230
  2. Match the user query to the best command from the Unique Capabilities and Command Reference above.
316
231
  3. Execute with the `--agent` flag:
317
232
  ```bash
@@ -321,6 +236,46 @@ Verify: `claude mcp list`
321
236
 
322
237
  ## Constraints
323
238
 
324
- Use only the `realtimex-pp-cli` commands documented by this skill. Never call the RealTimeX API directly with `curl`, `fetch`, raw HTTP clients, or custom scripts.
239
+ This skill intentionally exposes a small action-first command set. Prefer these generated commands over older nested resource commands.
240
+
241
+ * Use only documented `realtimex-pp-cli` commands.
242
+ * Never call the RealTimeX API directly with `curl`, `fetch`, raw HTTP clients, or custom scripts.
243
+ * If the current CLI cannot do the requested task, say the feature is not available and will be added soon.
244
+ * Use `--agent` on every command.
245
+ * Always run first:
246
+
247
+ ```bash
248
+ realtimex-pp-cli prepare --agent
249
+ ```
325
250
 
326
- If a requested task is impossible with the current CLI commands, do not work around it through direct API calls or undocumented behavior. Say the feature is not available and will be added soon.
251
+ * Use exact workspace slugs, thread slugs, provider ids, model ids, agent `canonical`, and agent `modelId` values from `prepare`.
252
+ * Do not guess workspace, thread, model, provider, agent, message, target, or option values.
253
+ * If required context is missing or ambiguous, ask a concise clarification question before running a command.
254
+ * Never assume a workspace or thread that the user has not referenced.
255
+ * If the user does not name or contextually reference a workspace for a workspace/thread/message operation, ask which workspace to use before running a command.
256
+ * If the user names or contextually references a thread but does not name or contextually reference its workspace, ask which workspace contains that thread before running a command.
257
+ * When the user explicitly uses contextual references such as "current workspace", "this thread", "the thread just created", "that workspace", or similar references, resolve them from the available conversation context only when the reference is unambiguous.
258
+ * If multiple plausible matches exist, ask the user to choose.
259
+
260
+ For `send-llm-message`:
261
+
262
+ * Require all four values to be explicitly named or explicitly referenced in the current request:
263
+ * workspace
264
+ * thread
265
+ * LLM provider
266
+ * LLM model
267
+ * If any of those four values are missing or ambiguous, ask for the missing values before running the command.
268
+ * Use provider/model only from:
269
+ * `prepare.models`
270
+ * `list-llm-providers`
271
+ * `list-llm-models`
272
+ * Never use `prepare.agents[].models` for `send-llm-message`.
273
+ * Prefer provider `realtimexai` unless the user explicitly asks for local `nodellama`.
274
+ * Only choose a model id that exists in the selected provider's LLM model list.
275
+ * If the requested model is unavailable, ask which available model to use instead.
276
+
277
+ For workspace default-agent setup:
278
+
279
+ * Use `prepare.agents` only.
280
+ * Use exact agent `canonical` and optional agent `modelId` values from `prepare.agents`.
281
+ * Never use `prepare.models` for workspace default-agent setup.