@tritard/waterbrother 0.16.55 → 0.16.56
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 +1 -0
- package/package.json +1 -1
- package/src/gateway.js +4 -11
package/README.md
CHANGED
|
@@ -300,6 +300,7 @@ Current Telegram behavior:
|
|
|
300
300
|
- Telegram owners can pair visible chat participants conversationally or with `/pair <user-id|@username>`, and owner requests like “add Austin as editor” now pair the person if needed and add them to the shared project directly
|
|
301
301
|
- Telegram also answers live state questions from room state now, including prompts like “is Austin paired?”, “is Austin in the project?”, “who is in the room?”, and “what project is this chat bound to?”
|
|
302
302
|
- Telegram owners can also use conversational project and member requests like “share this project in this chat”, “switch to TelegramTest”, or “add Austin as editor”, and Waterbrother routes those through the same project and shared-room actions
|
|
303
|
+
- In Telegram groups, directly addressed execution requests now run conversationally in `execute` mode when the operator lock is held; `/run <prompt>` remains the explicit execution form
|
|
303
304
|
- shared projects now support `/room`, `/events`, `/members`, `/invites`, `/whoami`, `/people`, `/tasks`, `/mode`, `/claim`, `/release`, `/invite`, `/accept-invite`, `/approve-invite`, `/reject-invite`, `/remove-member`, `/room-runtime`, and `/task ...` from Telegram
|
|
304
305
|
- Telegram now supports `/whoami` for Telegram-id and shared-room membership visibility, plus `/events` for recent shared-room activity
|
|
305
306
|
- `/room` now includes pending invite count plus task ownership summaries
|
package/package.json
CHANGED
package/src/gateway.js
CHANGED
|
@@ -249,7 +249,7 @@ function buildRemoteHelp() {
|
|
|
249
249
|
"<code>/clear</code> clear the current remote conversation history",
|
|
250
250
|
"",
|
|
251
251
|
"In private chats, any other message is sent to the linked Waterbrother session.",
|
|
252
|
-
"In groups,
|
|
252
|
+
"In groups, directly addressed execution requests run when the shared room is in <code>execute</code> mode and the operator lock is held. <code>/run <prompt></code> still works as the explicit execution form.",
|
|
253
253
|
"",
|
|
254
254
|
"<b>Current limitation</b>",
|
|
255
255
|
"• fallback remote runs still use <code>approval=never</code> if no live TUI host is attached",
|
|
@@ -2546,8 +2546,9 @@ Ask them to run <code>/whoami</code> and then <code>/accept-invite ${escapeTeleg
|
|
|
2546
2546
|
const groupIntent = this.isGroupChat(message)
|
|
2547
2547
|
? (isExplicitRun ? { kind: "execution", reason: "explicit /run" } : classifyTelegramGroupIntent(promptText))
|
|
2548
2548
|
: { kind: "execution", reason: "private chat" };
|
|
2549
|
+
const shouldExecutePrompt = !this.isGroupChat(message) || groupIntent.kind === "execution";
|
|
2549
2550
|
const sharedBinding = await this.bindSharedRoomForMessage(message, sessionId);
|
|
2550
|
-
const stateIntent = parseTelegramStateIntent(promptText);
|
|
2551
|
+
const stateIntent = !shouldExecutePrompt ? parseTelegramStateIntent(promptText) : null;
|
|
2551
2552
|
if (stateIntent) {
|
|
2552
2553
|
try {
|
|
2553
2554
|
const markup = await this.handleStateIntent(message, sessionId, stateIntent);
|
|
@@ -2667,7 +2668,7 @@ Ask them to run <code>/whoami</code> and then <code>/accept-invite ${escapeTeleg
|
|
|
2667
2668
|
return;
|
|
2668
2669
|
}
|
|
2669
2670
|
const manifest = await buildSelfAwarenessManifest({ cwd: sharedBinding.session.cwd || this.cwd, runtime: this.runtime, currentSession: sharedBinding.session });
|
|
2670
|
-
const localConceptAnswer = resolveLocalConceptQuestion(promptText, manifest);
|
|
2671
|
+
const localConceptAnswer = shouldExecutePrompt ? null : resolveLocalConceptQuestion(promptText, manifest);
|
|
2671
2672
|
if (
|
|
2672
2673
|
this.isGroupChat(message)
|
|
2673
2674
|
&& sharedBinding.project?.enabled
|
|
@@ -2697,14 +2698,6 @@ Ask them to run <code>/whoami</code> and then <code>/accept-invite ${escapeTeleg
|
|
|
2697
2698
|
await this.sendMessage(message.chat.id, escapeTelegramHtml(planHint), message.message_id, { parseMode: "HTML" });
|
|
2698
2699
|
return;
|
|
2699
2700
|
}
|
|
2700
|
-
if (this.isGroupChat(message) && groupIntent.kind === "execution" && !isExplicitRun) {
|
|
2701
|
-
await this.sendMarkup(
|
|
2702
|
-
message.chat.id,
|
|
2703
|
-
"Execution requests in groups must use <code>/run <prompt></code>. Discussion and planning can stay as normal targeted messages.",
|
|
2704
|
-
message.message_id
|
|
2705
|
-
);
|
|
2706
|
-
return;
|
|
2707
|
-
}
|
|
2708
2701
|
if (localConceptAnswer) {
|
|
2709
2702
|
await this.sendMarkup(message.chat.id, renderTelegramChunks(localConceptAnswer).join("\n\n"), message.message_id);
|
|
2710
2703
|
return;
|