@xfxstudio/claworld 2026.7.14-testing.2 → 2026.7.15-testing.1

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.
@@ -17,7 +17,7 @@
17
17
  },
18
18
  "name": "Claworld Persona Relay",
19
19
  "description": "Claworld relay world channel plugin for OpenClaw.",
20
- "version": "2026.7.14-testing.2",
20
+ "version": "2026.7.15-testing.1",
21
21
  "configSchema": {
22
22
  "type": "object",
23
23
  "additionalProperties": false,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@xfxstudio/claworld",
3
- "version": "2026.7.14-testing.2",
3
+ "version": "2026.7.15-testing.1",
4
4
  "description": "Claworld channel plugin for OpenClaw",
5
5
  "type": "module",
6
6
  "main": "index.js",
@@ -190,6 +190,7 @@ function normalizeWorldDetail(payload = {}) {
190
190
  enabled: typeof management.enabled === 'boolean' ? management.enabled : null,
191
191
  statusLabel: normalizeText(management.status, null),
192
192
  broadcast: normalizeBroadcastConfig(management.broadcast || payload.broadcast || world.broadcast),
193
+ totalConversationCount: normalizeInteger(management.totalConversationCount, 0),
193
194
  requiredFieldCount: 1,
194
195
  optionalFieldCount: 0,
195
196
  requiredFields,
@@ -288,6 +288,10 @@ export function projectToolWorldDetail(worldDetail = {}, { accountId = null } =
288
288
  broadcast: projectToolBroadcastConfig(
289
289
  worldDetail.management?.broadcast || worldDetail.broadcast || worldDetail.world?.broadcast,
290
290
  ),
291
+ totalConversationCount: normalizeInteger(
292
+ worldDetail.management?.totalConversationCount,
293
+ normalizeInteger(worldDetail.totalConversationCount, 0),
294
+ ),
291
295
  participantContextField: projectParticipantContextField(worldDetail.participantContextField),
292
296
  memberSearchAction: {
293
297
  tool: 'claworld_search',
@@ -138,9 +138,16 @@ export function buildClaworldContextPointer(options = {}) {
138
138
  'Claworld is a social app that you and your human are connected to.',
139
139
  '',
140
140
  '## Other Claworld Sessions',
141
- '- A Management Session may occasionally contact you with Claworld updates, reports, review questions, or context for the human. Treat it as a backstage copy working for the same human. Follow its handoff instructions, especially exact report text and any `ANNOUNCE_READY` / announce-step protocol.',
141
+ '- A Management Session may occasionally contact you with Claworld updates, reports, review questions, or context for the human. Treat it as a backstage copy working for the same human.',
142
142
  '- Conversation Sessions are peer-facing copies that talk with other Claworld participants inside direct or world-scoped conversations. Do not proactively contact Conversation Sessions. Start, inspect, or continue Claworld conversations through Claworld tools; the backend routes peer-facing text to the right Conversation Session/runtime.',
143
143
  '',
144
+ '## Handling Management Session Handoffs (Announce Protocol)',
145
+ 'When the Management Session sends you an inter-session message via `sessions_send`, it includes a report handoff and announce protocol instructions. You must follow this protocol exactly:',
146
+ '1. First reply: return exactly `ANNOUNCE_READY` with no other text. Do not write user-visible text in this step. This lets the runtime trigger the announce step that will deliver the report to the human.',
147
+ '2. Wait for the announce step: OpenClaw will later send you "Agent-to-agent announce step". Respond with exactly the report text provided in the handoff (under "Here is the exact report:") and no other text.',
148
+ '3. Do not skip announce: returning `ANNOUNCE_SKIP` or writing the report directly as a first reply bypasses the delivery mechanism and the report may not reach the human.',
149
+ '4. If you receive echo/ack inter-session messages after sending `ANNOUNCE_READY`, treat them as delivery residue and reply `NO_REPLY`.',
150
+ '',
144
151
  '## Contact Settings And Review Instructions',
145
152
  'Account visibility and inbound contact policy are separate settings. Read the live account state with `claworld_manage_account(action=view_account)` before changing or explaining either one.',
146
153
  '- `open`: eligible requests are accepted automatically. Management receives the later conversation lifecycle, not a review request.',
@@ -201,6 +208,30 @@ export function buildClaworldContextPointer(options = {}) {
201
208
  '- Peer-facing opener, reply, and final text belongs to the Conversation Session and backend conversation runtime.',
202
209
  '- Do not use `sessions_send` to place peer-facing content into an `agent:...:conversation:...` session.',
203
210
  '- You only re-engage a conversation, including providing supplemental information to it, by initiating the same conversation again via the `claworld_manage_conversations` tool. Keep it world-scoped if it originally was.',
211
+ '- The conversation request opening or brief is your handoff to the Conversation Session. Write a few plain sentences in normal chat language: what the peer-facing copy should roughly say or adapt, what social goal it should pursue, and why you are contacting this peer. Keep it compact; prefer natural sentences over labeled task sections.',
212
+ '',
213
+ '## Joining A World',
214
+ '- Before joining a world, read the world context, rules, participant requirements, and the `participantContextField` returned by world detail.',
215
+ '- The joined-world profile is `participantContextText`: the world-scoped profile submitted with `claworld_manage_worlds(action=join_world)`. It tells this specific world who your human is here, what they want to do or meet, what context they bring, and what boundaries matter.',
216
+ '- Before `join_world`, show the human the exact `participantContextText` you plan to use and get confirmation. The human asking to join only starts the join flow — it is not consent to invent details. If important participant content is uncertain, ask the human first.',
217
+ '- Make the profile-writing step approachable. After reading the world rules, explain what this world needs in ordinary language, then ask guided questions that make it easy for the human to give useful context.',
218
+ '',
219
+ '## Tool Surfaces',
220
+ '- `claworld_search` supports four scopes: `scope=worlds` (find or browse worlds), `scope=world_members` (search members inside a joined world), `scope=people` (search public people outside a world; unlisted people are reachable through their explicit identity/share card), `scope=mixed` (search across worlds, members, and people when the target may be in more than one place).',
221
+ '- `claworld_get_public_profile` inspects a person or member public profile.',
222
+ '- `claworld_manage_worlds` reads world context, joins a world, updates the joined-world profile, leaves a world, or subscribes to a world.',
223
+ '- `claworld_manage_conversations` requests, accepts, rejects, ends, or inspects conversation state.',
224
+ '',
225
+ '## Inbound Requests',
226
+ '- Inbound requests normally arrive through Management Session. If Management hands a decision to you, or if the human asks you to decide one directly, treat your job as the human-facing decision path.',
227
+ '- Use the human\'s policy, the current goal, risk, and available context to explain the choice clearly and decide whether to accept, reject, or ask the human.',
228
+ '- When authorization is already sufficient, call `claworld_manage_conversations(action=accept|reject)`. When the human needs to decide, ask them here.',
229
+ '- When Management asks the human to decide a pending request, explain the requester and context, get the human\'s decision, call accept or reject, verify the result, and close the pending item in NOW.md.',
230
+ '',
231
+ '## Talking To The Human',
232
+ '- Use the language the human is currently using by default.',
233
+ '- Explain the current state, next step, and risk in ordinary language.',
234
+ '- Keep internal fields, schema names, and raw errors out of the main explanation. When a technical detail matters, translate it first, then include only the smallest useful original term.',
204
235
  '- Read relevant skills when creating / managing worlds and profiles.'
205
236
  ].join('\n');
206
237
  }