cc-claw 0.17.0 → 0.17.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.
- package/dist/cli.js +17 -6
- package/package.json +1 -1
package/dist/cli.js
CHANGED
|
@@ -33,7 +33,7 @@ var VERSION;
|
|
|
33
33
|
var init_version = __esm({
|
|
34
34
|
"src/version.ts"() {
|
|
35
35
|
"use strict";
|
|
36
|
-
VERSION = true ? "0.17.
|
|
36
|
+
VERSION = true ? "0.17.1" : (() => {
|
|
37
37
|
try {
|
|
38
38
|
return JSON.parse(readFileSync(join(process.cwd(), "package.json"), "utf-8")).version ?? "unknown";
|
|
39
39
|
} catch {
|
|
@@ -12834,7 +12834,6 @@ var init_classify2 = __esm({
|
|
|
12834
12834
|
function shouldRequireApproval(input) {
|
|
12835
12835
|
if (input.execMode !== "approved") return false;
|
|
12836
12836
|
if (input.intent !== "agentic") return false;
|
|
12837
|
-
if (input.isResuming) return false;
|
|
12838
12837
|
if (input.messageText.startsWith(">>")) return false;
|
|
12839
12838
|
if (EXEMPT_TIERS.has(input.bootstrapTier)) return false;
|
|
12840
12839
|
if (input.isSideQuest) return false;
|
|
@@ -16468,8 +16467,23 @@ Tap to toggle:`,
|
|
|
16468
16467
|
setSessionStartedAt(chatId);
|
|
16469
16468
|
logActivity(getDb(), { chatId, source: "telegram", eventType: "config_changed", summary: "New session started", detail: { field: "session", action: "reset", summarized } });
|
|
16470
16469
|
if (typeof channel.sendKeyboard === "function" && oldSessionId) {
|
|
16471
|
-
|
|
16470
|
+
let adapter;
|
|
16471
|
+
try {
|
|
16472
|
+
adapter = getAdapterForChat(chatId);
|
|
16473
|
+
} catch {
|
|
16474
|
+
adapter = null;
|
|
16475
|
+
}
|
|
16476
|
+
const currentModel = getModel(chatId) ?? adapter?.defaultModel ?? "default";
|
|
16477
|
+
const modelLabel = adapter ? formatModelShort(currentModel) : currentModel;
|
|
16478
|
+
const backendLabel = adapter?.displayName ?? getBackend(chatId) ?? "not set";
|
|
16479
|
+
const msg2 = `\u2705 New session started. Previous session archived${exchangeCount > 0 ? ` (${exchangeCount} exchanges)` : ""}.
|
|
16480
|
+
|
|
16481
|
+
\u{1F9E0} ${backendLabel} \xB7 ${modelLabel}`;
|
|
16472
16482
|
const kbMsgId = await channel.sendKeyboard(chatId, msg2, [
|
|
16483
|
+
[
|
|
16484
|
+
{ label: "Switch Backend", data: "menu:backend", style: "primary" },
|
|
16485
|
+
{ label: "Switch Model", data: "menu:model", style: "primary" }
|
|
16486
|
+
],
|
|
16473
16487
|
[{ label: "Undo", data: "newchat:undo" }]
|
|
16474
16488
|
]);
|
|
16475
16489
|
if (kbMsgId) {
|
|
@@ -19193,14 +19207,11 @@ You're still in discussion mode \u2014 try again or click a button to exit.`, {
|
|
|
19193
19207
|
}
|
|
19194
19208
|
}
|
|
19195
19209
|
const execMode = getExecMode(chatId);
|
|
19196
|
-
const sessionId = getSessionId(chatId);
|
|
19197
|
-
const isResuming = !!sessionId;
|
|
19198
19210
|
if (shouldRequireApproval({
|
|
19199
19211
|
execMode,
|
|
19200
19212
|
intent,
|
|
19201
19213
|
bootstrapTier: bootstrapTier ?? "full",
|
|
19202
19214
|
messageText: text,
|
|
19203
|
-
isResuming,
|
|
19204
19215
|
isSideQuest: hasSqPrefix
|
|
19205
19216
|
})) {
|
|
19206
19217
|
const planDirective = buildPlanningDirective();
|
package/package.json
CHANGED