@inline-openclaw/inline 0.0.38 → 0.0.39

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 (41) hide show
  1. package/README.md +20 -3
  2. package/dist/account-inspect-api.js +34 -7
  3. package/dist/account-inspect-api.js.map +4 -4
  4. package/dist/approval-handler.runtime.js +1032 -92
  5. package/dist/approval-handler.runtime.js.map +14 -14
  6. package/dist/channel-plugin-api.js +1807 -319
  7. package/dist/channel-plugin-api.js.map +18 -17
  8. package/dist/index.d.ts +1 -1
  9. package/dist/inline/accounts.d.ts.map +1 -1
  10. package/dist/inline/actions.d.ts +1 -1
  11. package/dist/inline/actions.d.ts.map +1 -1
  12. package/dist/inline/approval-native.d.ts.map +1 -1
  13. package/dist/inline/channel.d.ts.map +1 -1
  14. package/dist/inline/config-schema.d.ts +125 -0
  15. package/dist/inline/config-schema.d.ts.map +1 -1
  16. package/dist/inline/exec-approvals.d.ts.map +1 -1
  17. package/dist/inline/message-tools.d.ts.map +1 -1
  18. package/dist/inline/monitor.d.ts.map +1 -1
  19. package/dist/inline/parent-context-tool.d.ts +10 -0
  20. package/dist/inline/parent-context-tool.d.ts.map +1 -0
  21. package/dist/inline/policy.d.ts +30 -1
  22. package/dist/inline/policy.d.ts.map +1 -1
  23. package/dist/inline/reply-threads.d.ts +12 -0
  24. package/dist/inline/reply-threads.d.ts.map +1 -1
  25. package/dist/inline/shared.d.ts +1 -1
  26. package/dist/inline/thread-participation.d.ts +10 -0
  27. package/dist/inline/thread-participation.d.ts.map +1 -0
  28. package/dist/inline/tool-targets.d.ts +36 -0
  29. package/dist/inline/tool-targets.d.ts.map +1 -0
  30. package/dist/runtime-register-api.d.ts.map +1 -1
  31. package/dist/runtime-register-api.js +1805 -151
  32. package/dist/runtime-register-api.js.map +19 -15
  33. package/dist/runtime-setter-api.js +11 -15
  34. package/dist/runtime-setter-api.js.map +3 -3
  35. package/dist/runtime.d.ts +2 -2
  36. package/dist/runtime.d.ts.map +1 -1
  37. package/dist/setup-entry.d.ts +1 -1
  38. package/dist/setup-plugin-api.js +34 -7
  39. package/dist/setup-plugin-api.js.map +4 -4
  40. package/openclaw.plugin.json +723 -56
  41. package/package.json +6 -6
package/README.md CHANGED
@@ -26,12 +26,14 @@ By default, Inline reply threads stay off to preserve the old compatibility beha
26
26
  When enabled:
27
27
 
28
28
  - inbound reply-thread messages use the parent chat as the base conversation target and the child reply-thread chat id as `MessageThreadId`
29
+ - bot-participated reply threads can continue without an explicit bot mention by default, matching Slack-style thread behavior
30
+ - reply-thread context includes the anchor message plus child-thread history by default; parent-chat history is opt-in
29
31
  - outbound `thread-reply` sends into the child reply-thread chat
30
32
  - `thread-create` creates a real Inline reply thread instead of a plain chat alias
31
33
 
32
34
  ## Install
33
35
 
34
- Requires OpenClaw `2026.5.18` or newer.
36
+ Requires OpenClaw `2026.5.28` or newer.
35
37
 
36
38
  From npm (once published):
37
39
 
@@ -140,6 +142,8 @@ channels:
140
142
  replyThreads: false # optional, default false; enable Inline reply-thread support
141
143
  requireMention: true # optional: default is false
142
144
  replyToBotWithoutMention: true # if true, replies to bot messages can bypass mention requirement
145
+ replyThreadRequireExplicitMention: false # optional, default false; bot-participated reply threads continue without @mention
146
+ replyThreadParentHistoryLimit: 10 # optional, default 10; set 0 to disable parent-chat context before the anchor
143
147
 
144
148
  # Inbound context history (used to build richer thread context for the agent):
145
149
  historyLimit: 50 # group chats
@@ -159,6 +163,8 @@ channels:
159
163
  groups:
160
164
  "88":
161
165
  requireMention: false
166
+ replyThreadRequireExplicitMention: true
167
+ replyThreadParentHistoryLimit: 2
162
168
  allowFrom:
163
169
  - "42"
164
170
  tools:
@@ -188,6 +194,8 @@ Reply behavior summary:
188
194
  - `replyToId` is always an Inline message id.
189
195
  - Inline reply threads are separate and use OpenClaw `threadId`.
190
196
  - Keep `replyThreads` off if you only want classic message replies.
197
+ - Bot-participated reply threads continue without `@bot` by default, including from persisted recent participation state. Set `replyThreadRequireExplicitMention: true` if a chat should require `@bot` on every reply-thread message.
198
+ - `replyThreadParentHistoryLimit` defaults to `10`, so reply-thread turns include nearby parent-chat context before the anchor. Set it to `0` only when a chat should stay strictly thread-local.
191
199
 
192
200
  If you set `dmPolicy: "open"`, set `allowFrom: ["*"]`.
193
201
 
@@ -203,7 +211,7 @@ For `message send`/plugin outbound sends:
203
211
 
204
212
  - Use `openclaw message send --channel inline --target chat:<id> --message "..."`.
205
213
  - If `channels.inline.defaultTo` is set, OpenClaw uses it when no explicit target is supplied. Named accounts can override it with `channels.inline.accounts.<account>.defaultTo`.
206
- - Some OpenClaw 2026.5.18 CLI help text lists only built-in channel ids, but installed plugin channel ids such as `inline` are accepted.
214
+ - Some OpenClaw CLI help text lists only built-in channel ids, but installed plugin channel ids such as `inline` are accepted.
207
215
  - `chat:<id>` targets a chat id.
208
216
  - `user:<id>` targets a user id (DM peer).
209
217
  - `inline:user:<id>` and `inline:chat:<id>` are accepted and normalized.
@@ -236,6 +244,7 @@ Inline reply-thread semantics are behind `channels.inline.capabilities.replyThre
236
244
  - disabled: `thread-reply` behaves like the old compatibility reply path
237
245
  - enabled: `thread-reply` expects `threadId` to be the child reply-thread chat id, while `to` stays the parent chat id
238
246
  - enabled: `thread-create` creates a real reply thread from a parent chat and optional `replyToId` anchor
247
+ - enabled: if the current reply-thread message has no direct media, OpenClaw can inherit the anchor message media so image/file-only thread starters remain visible to the agent
239
248
 
240
249
  You can gate action groups from config:
241
250
 
@@ -263,7 +272,15 @@ Named accounts can override the same `reactionNotifications` mode and `reactionA
263
272
 
264
273
  ## Extra Agent Tools
265
274
 
266
- The plugin also registers a dedicated `inline_members` tool for space-member discovery outside the `message` action surface.
275
+ The plugin also registers dedicated tools outside the `message` action surface.
276
+
277
+ `inline_parent_context` fetches more parent-chat history for the current Inline reply-thread session when the automatic context window is not enough.
278
+
279
+ - Defaults to the current reply thread when invoked from one
280
+ - Optional inputs: `threadId`, `parentChatId`, `parentMessageId`, `beforeMessageId`, `limit`, `includeAnchor`, `accountId`
281
+ - Returned messages are ordered oldest to newest and include media/entity summaries
282
+
283
+ `inline_members` handles space-member discovery:
267
284
 
268
285
  - Required input: `spaceId`
269
286
  - Optional filters: `query`, `userId`, `limit`, `accountId`
@@ -14550,10 +14550,15 @@ var InlineActionsSchema = exports_external.object({
14550
14550
  var InlineCapabilitiesSchema = exports_external.object({
14551
14551
  replyThreads: exports_external.boolean().optional()
14552
14552
  }).strict();
14553
+ var InlineReplyThreadModeSchema = exports_external.enum(["auto", "thread", "main"]);
14553
14554
  var InlineTargetSchema = exports_external.union([exports_external.string(), exports_external.number()]);
14554
14555
  var InlineAllowEntrySchema = exports_external.union([exports_external.string(), exports_external.number()]);
14555
14556
  var InlineGroupSchema = exports_external.object({
14556
14557
  requireMention: exports_external.boolean().optional(),
14558
+ replyThreadMode: InlineReplyThreadModeSchema.optional(),
14559
+ replyThreadAutoCreateMinMessages: exports_external.number().int().min(0).optional(),
14560
+ replyThreadRequireExplicitMention: exports_external.boolean().optional(),
14561
+ replyThreadParentHistoryLimit: exports_external.number().int().min(0).optional(),
14557
14562
  allowFrom: exports_external.array(InlineAllowEntrySchema).optional(),
14558
14563
  systemPrompt: exports_external.string().optional(),
14559
14564
  tools: ToolPolicySchema.optional(),
@@ -14593,6 +14598,7 @@ var InlineStreamingSchema = exports_external.union([
14593
14598
  label: exports_external.union([exports_external.string(), exports_external.literal(false)]).optional(),
14594
14599
  labels: exports_external.array(exports_external.string()).optional(),
14595
14600
  maxLines: exports_external.number().int().positive().optional(),
14601
+ maxLineChars: exports_external.number().int().positive().optional(),
14596
14602
  render: exports_external.enum(["text", "rich"]).optional(),
14597
14603
  toolProgress: exports_external.boolean().optional(),
14598
14604
  commandText: InlineStreamingCommandTextSchema.optional()
@@ -14620,6 +14626,7 @@ var InlineRuntimeStreamingSchema = exports_external.union([
14620
14626
  label: exports_external.union([exports_external.string(), exports_external.literal(false)]).optional(),
14621
14627
  labels: exports_external.array(exports_external.string()).optional(),
14622
14628
  maxLines: exports_external.number().int().positive().optional(),
14629
+ maxLineChars: exports_external.number().int().positive().optional(),
14623
14630
  render: exports_external.enum(["text", "rich"]).optional(),
14624
14631
  toolProgress: exports_external.boolean().optional(),
14625
14632
  commandText: InlineStreamingCommandTextSchema.optional()
@@ -14645,6 +14652,10 @@ var InlineAccountSchemaBase = exports_external.object({
14645
14652
  groupPolicy: GroupPolicySchema.optional().default("allowlist"),
14646
14653
  groups: exports_external.record(exports_external.string(), InlineGroupSchema.optional()).optional(),
14647
14654
  requireMention: exports_external.boolean().optional(),
14655
+ replyThreadMode: InlineReplyThreadModeSchema.optional(),
14656
+ replyThreadAutoCreateMinMessages: exports_external.number().int().min(0).optional(),
14657
+ replyThreadRequireExplicitMention: exports_external.boolean().optional(),
14658
+ replyThreadParentHistoryLimit: exports_external.number().int().min(0).optional(),
14648
14659
  replyToBotWithoutMention: exports_external.boolean().optional(),
14649
14660
  historyLimit: exports_external.number().int().min(0).optional(),
14650
14661
  dmHistoryLimit: exports_external.number().int().min(0).optional(),
@@ -14916,9 +14927,7 @@ function inspectInlineAccount(params) {
14916
14927
  }
14917
14928
  const tokenFile = account.tokenFile?.trim() ?? "";
14918
14929
  if (tokenFile) {
14919
- const token = tryReadSecretFileSync(tokenFile, "Inline bot token", {
14920
- rejectSymlink: true
14921
- }) ?? "";
14930
+ const token = tryReadInlineTokenFile(tokenFile);
14922
14931
  return {
14923
14932
  ...account,
14924
14933
  token: token || null,
@@ -14978,13 +14987,31 @@ async function resolveInlineToken(account) {
14978
14987
  }
14979
14988
  throw new Error("Inline token missing (set channels.inline.token, channels.inline.tokenFile, INLINE_TOKEN, or INLINE_BOT_TOKEN)");
14980
14989
  }
14981
- const token = tryReadSecretFileSync(tokenFile, "Inline bot token", {
14982
- rejectSymlink: true
14983
- });
14990
+ const token = readInlineTokenFile(tokenFile);
14984
14991
  if (!token)
14985
14992
  throw new Error(`Inline tokenFile is empty or unreadable: ${tokenFile}`);
14986
14993
  return token;
14987
14994
  }
14995
+ function tryReadInlineTokenFile(tokenFile) {
14996
+ try {
14997
+ return tryReadSecretFileSync(tokenFile, "Inline bot token", {
14998
+ rejectSymlink: true
14999
+ }) ?? "";
15000
+ } catch {
15001
+ return "";
15002
+ }
15003
+ }
15004
+ function readInlineTokenFile(tokenFile) {
15005
+ try {
15006
+ return tryReadSecretFileSync(tokenFile, "Inline bot token", {
15007
+ rejectSymlink: true
15008
+ }) ?? "";
15009
+ } catch (error51) {
15010
+ throw new Error(`Inline tokenFile is empty or unreadable: ${tokenFile}`, {
15011
+ cause: error51
15012
+ });
15013
+ }
15014
+ }
14988
15015
 
14989
15016
  // src/account-inspect-api.ts
14990
15017
  function inspectInlineReadOnlyAccount(cfg, accountId) {
@@ -14994,5 +15021,5 @@ export {
14994
15021
  inspectInlineReadOnlyAccount
14995
15022
  };
14996
15023
 
14997
- //# debugId=FF5F089AF31525E364756E2164756E21
15024
+ //# debugId=037AA7E34FED47C364756E2164756E21
14998
15025
  //# sourceMappingURL=account-inspect-api.js.map