localclawd 1.2.1 → 1.2.3

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 (2) hide show
  1. package/dist/cli.mjs +426 -327
  2. package/package.json +1 -1
package/dist/cli.mjs CHANGED
@@ -87564,7 +87564,7 @@ var init_isEqual = __esm(() => {
87564
87564
 
87565
87565
  // src/utils/userAgent.ts
87566
87566
  function getClaudeCodeUserAgent() {
87567
- return `claude-code/${"1.2.1"}`;
87567
+ return `claude-code/${"1.2.3"}`;
87568
87568
  }
87569
87569
 
87570
87570
  // src/utils/workloadContext.ts
@@ -87586,7 +87586,7 @@ function getUserAgent() {
87586
87586
  const clientApp = process.env.CLAUDE_AGENT_SDK_CLIENT_APP ? `, client-app/${process.env.CLAUDE_AGENT_SDK_CLIENT_APP}` : "";
87587
87587
  const workload = getWorkload();
87588
87588
  const workloadSuffix = workload ? `, workload/${workload}` : "";
87589
- return `claude-cli/${"1.2.1"} (${process.env.USER_TYPE}, ${process.env.CLAUDE_CODE_ENTRYPOINT ?? "cli"}${agentSdkVersion}${clientApp}${workloadSuffix})`;
87589
+ return `claude-cli/${"1.2.3"} (${process.env.USER_TYPE}, ${process.env.CLAUDE_CODE_ENTRYPOINT ?? "cli"}${agentSdkVersion}${clientApp}${workloadSuffix})`;
87590
87590
  }
87591
87591
  function getMCPUserAgent() {
87592
87592
  const parts = [];
@@ -87600,7 +87600,7 @@ function getMCPUserAgent() {
87600
87600
  parts.push(`client-app/${process.env.CLAUDE_AGENT_SDK_CLIENT_APP}`);
87601
87601
  }
87602
87602
  const suffix = parts.length > 0 ? ` (${parts.join(", ")})` : "";
87603
- return `claude-code/${"1.2.1"}${suffix}`;
87603
+ return `claude-code/${"1.2.3"}${suffix}`;
87604
87604
  }
87605
87605
  function getWebFetchUserAgent() {
87606
87606
  return `Claude-User (${getClaudeCodeUserAgent()}; +https://support.anthropic.com/)`;
@@ -130791,7 +130791,7 @@ function getAttributionHeader(fingerprint) {
130791
130791
  if (!isAttributionHeaderEnabled()) {
130792
130792
  return "";
130793
130793
  }
130794
- const version = `${"1.2.1"}.${fingerprint}`;
130794
+ const version = `${"1.2.3"}.${fingerprint}`;
130795
130795
  const entrypoint = process.env.CLAUDE_CODE_ENTRYPOINT ?? "unknown";
130796
130796
  const cch = "";
130797
130797
  const workload = getWorkload();
@@ -146980,7 +146980,7 @@ var init_metadata = __esm(() => {
146980
146980
  COMPOUND_OPERATOR_REGEX = /\s*(?:&&|\|\||[;|])\s*/;
146981
146981
  WHITESPACE_REGEX = /\s+/;
146982
146982
  getVersionBase = memoize_default(() => {
146983
- const match = "1.2.1".match(/^\d+\.\d+\.\d+(?:-[a-z]+)?/);
146983
+ const match = "1.2.3".match(/^\d+\.\d+\.\d+(?:-[a-z]+)?/);
146984
146984
  return match ? match[0] : undefined;
146985
146985
  });
146986
146986
  buildEnvContext = memoize_default(async () => {
@@ -147020,9 +147020,9 @@ var init_metadata = __esm(() => {
147020
147020
  isGithubAction: isEnvTruthy(process.env.GITHUB_ACTIONS),
147021
147021
  isClaudeCodeAction: isEnvTruthy(process.env.CLAUDE_CODE_ACTION),
147022
147022
  isClaudeAiAuth: isClaudeAISubscriber(),
147023
- version: "1.2.1",
147023
+ version: "1.2.3",
147024
147024
  versionBase: getVersionBase(),
147025
- buildTime: "2026-04-15T02:12:12.680Z",
147025
+ buildTime: "2026-04-18T19:07:42.573Z",
147026
147026
  deploymentEnvironment: env3.detectDeploymentEnvironment(),
147027
147027
  ...isEnvTruthy(process.env.GITHUB_ACTIONS) && {
147028
147028
  githubEventName: process.env.GITHUB_EVENT_NAME,
@@ -179501,7 +179501,7 @@ function getTelemetryAttributes() {
179501
179501
  attributes["session.id"] = sessionId;
179502
179502
  }
179503
179503
  if (shouldIncludeAttribute("OTEL_METRICS_INCLUDE_VERSION")) {
179504
- attributes["app.version"] = "1.2.1";
179504
+ attributes["app.version"] = "1.2.3";
179505
179505
  }
179506
179506
  const oauthAccount = getOauthAccountInfo();
179507
179507
  if (oauthAccount) {
@@ -180402,7 +180402,8 @@ function getEffectiveContextWindowSize(model) {
180402
180402
  }
180403
180403
  function getAutoCompactThreshold(model) {
180404
180404
  const effectiveContextWindow = getEffectiveContextWindowSize(model);
180405
- const autocompactThreshold = effectiveContextWindow - AUTOCOMPACT_BUFFER_TOKENS;
180405
+ const scaledBuffer = Math.min(AUTOCOMPACT_BUFFER_TOKENS, Math.floor(effectiveContextWindow * 0.1));
180406
+ const autocompactThreshold = effectiveContextWindow - scaledBuffer;
180406
180407
  const envPercent = process.env.CLAUDE_AUTOCOMPACT_PCT_OVERRIDE;
180407
180408
  if (envPercent) {
180408
180409
  const parsed = parseFloat(envPercent);
@@ -234010,7 +234011,6 @@ var init_stdio2 = __esm(() => {
234010
234011
  // node_modules/eventsource-parser/dist/stream.js
234011
234012
  var EventSourceParserStream;
234012
234013
  var init_stream = __esm(() => {
234013
- init_dist4();
234014
234014
  init_dist4();
234015
234015
  EventSourceParserStream = class EventSourceParserStream extends TransformStream {
234016
234016
  constructor({ onError, onRetry, onComment } = {}) {
@@ -242293,7 +242293,7 @@ function getInstallationEnv() {
242293
242293
  return;
242294
242294
  }
242295
242295
  function getClaudeCodeVersion() {
242296
- return "1.2.1";
242296
+ return "1.2.3";
242297
242297
  }
242298
242298
  async function getInstalledVSCodeExtensionVersion(command) {
242299
242299
  const { stdout } = await execFileNoThrow(command, ["--list-extensions", "--show-versions"], {
@@ -247567,7 +247567,7 @@ async function setupSdkMcpClients(sdkMcpConfigs, sendMcpMessage) {
247567
247567
  const client4 = new Client({
247568
247568
  name: "localclawd",
247569
247569
  title: "localclawd",
247570
- version: "1.2.1",
247570
+ version: "1.2.3",
247571
247571
  description: "local-first AI coding tool",
247572
247572
  websiteUrl: PRODUCT_URL
247573
247573
  }, {
@@ -247909,7 +247909,7 @@ var init_client9 = __esm(() => {
247909
247909
  const client4 = new Client({
247910
247910
  name: "localclawd",
247911
247911
  title: "localclawd",
247912
- version: "1.2.1",
247912
+ version: "1.2.3",
247913
247913
  description: "local-first AI coding tool",
247914
247914
  websiteUrl: PRODUCT_URL
247915
247915
  }, {
@@ -262299,7 +262299,7 @@ function computeFingerprint(messageText, version) {
262299
262299
  }
262300
262300
  function computeFingerprintFromMessages(messages) {
262301
262301
  const firstMessageText = extractFirstMessageText(messages);
262302
- return computeFingerprint(firstMessageText, "1.2.1");
262302
+ return computeFingerprint(firstMessageText, "1.2.3");
262303
262303
  }
262304
262304
  var FINGERPRINT_SALT = "59cf53e54c78";
262305
262305
  var init_fingerprint = () => {};
@@ -262341,7 +262341,7 @@ async function sideQuery(opts) {
262341
262341
  betas.push(STRUCTURED_OUTPUTS_BETA_HEADER);
262342
262342
  }
262343
262343
  const messageText = extractFirstUserMessageText(messages);
262344
- const fingerprint = computeFingerprint(messageText, "1.2.1");
262344
+ const fingerprint = computeFingerprint(messageText, "1.2.3");
262345
262345
  const attributionHeader = getAttributionHeader(fingerprint);
262346
262346
  const systemBlocks = [
262347
262347
  attributionHeader ? { type: "text", text: attributionHeader } : null,
@@ -283065,7 +283065,7 @@ var init_user = __esm(() => {
283065
283065
  deviceId,
283066
283066
  sessionId: getSessionId(),
283067
283067
  email: getEmail(),
283068
- appVersion: "1.2.1",
283068
+ appVersion: "1.2.3",
283069
283069
  platform: getHostPlatformForAnalytics(),
283070
283070
  organizationUuid,
283071
283071
  accountUuid,
@@ -284130,7 +284130,7 @@ async function initializeBetaTracing(resource) {
284130
284130
  });
284131
284131
  logs.setGlobalLoggerProvider(loggerProvider);
284132
284132
  setLoggerProvider(loggerProvider);
284133
- const eventLogger = logs.getLogger("com.anthropic.claude_code.events", "1.2.1");
284133
+ const eventLogger = logs.getLogger("com.anthropic.claude_code.events", "1.2.3");
284134
284134
  setEventLogger(eventLogger);
284135
284135
  process.on("beforeExit", async () => {
284136
284136
  await loggerProvider?.forceFlush();
@@ -284170,7 +284170,7 @@ async function initializeTelemetry() {
284170
284170
  const platform2 = getPlatform();
284171
284171
  const baseAttributes = {
284172
284172
  [ATTR_SERVICE_NAME4]: "claude-code",
284173
- [ATTR_SERVICE_VERSION4]: "1.2.1"
284173
+ [ATTR_SERVICE_VERSION4]: "1.2.3"
284174
284174
  };
284175
284175
  if (platform2 === "wsl") {
284176
284176
  const wslVersion = getWslVersion();
@@ -284215,7 +284215,7 @@ async function initializeTelemetry() {
284215
284215
  } catch {}
284216
284216
  };
284217
284217
  registerCleanup(shutdownTelemetry2);
284218
- return meterProvider2.getMeter("com.anthropic.claude_code", "1.2.1");
284218
+ return meterProvider2.getMeter("com.anthropic.claude_code", "1.2.3");
284219
284219
  }
284220
284220
  const meterProvider = new MeterProvider4({
284221
284221
  resource,
@@ -284235,7 +284235,7 @@ async function initializeTelemetry() {
284235
284235
  });
284236
284236
  logs.setGlobalLoggerProvider(loggerProvider);
284237
284237
  setLoggerProvider(loggerProvider);
284238
- const eventLogger = logs.getLogger("com.anthropic.claude_code.events", "1.2.1");
284238
+ const eventLogger = logs.getLogger("com.anthropic.claude_code.events", "1.2.3");
284239
284239
  setEventLogger(eventLogger);
284240
284240
  logForDebugging("[3P telemetry] Event logger set successfully");
284241
284241
  process.on("beforeExit", async () => {
@@ -284297,7 +284297,7 @@ Current timeout: ${timeoutMs}ms
284297
284297
  }
284298
284298
  };
284299
284299
  registerCleanup(shutdownTelemetry);
284300
- return meterProvider.getMeter("com.anthropic.claude_code", "1.2.1");
284300
+ return meterProvider.getMeter("com.anthropic.claude_code", "1.2.3");
284301
284301
  }
284302
284302
  async function flushTelemetry() {
284303
284303
  const meterProvider = getMeterProvider();
@@ -285487,7 +285487,7 @@ function detectLinuxGlobPatternWarnings() {
285487
285487
  }
285488
285488
  async function getDoctorDiagnostic() {
285489
285489
  const installationType = await getCurrentInstallationType();
285490
- const version = typeof MACRO !== "undefined" ? "1.2.1" : "unknown";
285490
+ const version = typeof MACRO !== "undefined" ? "1.2.3" : "unknown";
285491
285491
  const installationPath = await getInstallationPath();
285492
285492
  const invokedBinary = getInvokedBinary();
285493
285493
  const multipleInstallations = await detectMultipleInstallations();
@@ -286428,8 +286428,8 @@ async function updateLatest(channelOrVersion, forceReinstall = false) {
286428
286428
  const maxVersion = await getMaxVersion();
286429
286429
  if (maxVersion && gt(version, maxVersion)) {
286430
286430
  logForDebugging(`Native installer: maxVersion ${maxVersion} is set, capping update from ${version} to ${maxVersion}`);
286431
- if (gte("1.2.1", maxVersion)) {
286432
- logForDebugging(`Native installer: current version ${"1.2.1"} is already at or above maxVersion ${maxVersion}, skipping update`);
286431
+ if (gte("1.2.3", maxVersion)) {
286432
+ logForDebugging(`Native installer: current version ${"1.2.3"} is already at or above maxVersion ${maxVersion}, skipping update`);
286433
286433
  logEvent("tengu_native_update_skipped_max_version", {
286434
286434
  latency_ms: Date.now() - startTime,
286435
286435
  max_version: maxVersion,
@@ -286440,7 +286440,7 @@ async function updateLatest(channelOrVersion, forceReinstall = false) {
286440
286440
  version = maxVersion;
286441
286441
  }
286442
286442
  }
286443
- if (!forceReinstall && version === "1.2.1" && await versionIsAvailable(version) && await isPossibleLocalClawdBinary(executablePath)) {
286443
+ if (!forceReinstall && version === "1.2.3" && await versionIsAvailable(version) && await isPossibleLocalClawdBinary(executablePath)) {
286444
286444
  logForDebugging(`Found ${version} at ${executablePath}, skipping install`);
286445
286445
  logEvent("tengu_native_update_complete", {
286446
286446
  latency_ms: Date.now() - startTime,
@@ -330829,7 +330829,7 @@ function getAnthropicEnvMetadata() {
330829
330829
  function getBuildAgeMinutes() {
330830
330830
  if (false)
330831
330831
  ;
330832
- const buildTime = new Date("2026-04-15T02:12:12.680Z").getTime();
330832
+ const buildTime = new Date("2026-04-18T19:07:42.573Z").getTime();
330833
330833
  if (isNaN(buildTime))
330834
330834
  return;
330835
330835
  return Math.floor((Date.now() - buildTime) / 60000);
@@ -359154,7 +359154,7 @@ function Feedback({
359154
359154
  platform: env3.platform,
359155
359155
  gitRepo: envInfo.isGit,
359156
359156
  terminal: env3.terminal,
359157
- version: "1.2.1",
359157
+ version: "1.2.3",
359158
359158
  transcript: normalizeMessagesForAPI(messages),
359159
359159
  errors: sanitizedErrors,
359160
359160
  lastApiRequest: getLastAPIRequest(),
@@ -359346,7 +359346,7 @@ function Feedback({
359346
359346
  ", ",
359347
359347
  env3.terminal,
359348
359348
  ", v",
359349
- "1.2.1"
359349
+ "1.2.3"
359350
359350
  ]
359351
359351
  }, undefined, true, undefined, this)
359352
359352
  ]
@@ -359452,7 +359452,7 @@ ${sanitizedDescription}
359452
359452
  ` + `**Environment Info**
359453
359453
  ` + `- Platform: ${env3.platform}
359454
359454
  ` + `- Terminal: ${env3.terminal}
359455
- ` + `- Version: ${"1.2.1"}
359455
+ ` + `- Version: ${"1.2.3"}
359456
359456
  ` + `- Feedback ID: ${feedbackId}
359457
359457
  ` + `
359458
359458
  **Errors**
@@ -362080,7 +362080,7 @@ function buildPrimarySection() {
362080
362080
  }, undefined, false, undefined, this);
362081
362081
  return [{
362082
362082
  label: "Version",
362083
- value: "1.2.1"
362083
+ value: "1.2.3"
362084
362084
  }, {
362085
362085
  label: "Session name",
362086
362086
  value: nameValue
@@ -366679,7 +366679,7 @@ function Config({
366679
366679
  }
366680
366680
  }, undefined, false, undefined, this)
366681
366681
  }, undefined, false, undefined, this) : showSubmenu === "ChannelDowngrade" ? /* @__PURE__ */ jsx_dev_runtime175.jsxDEV(ChannelDowngradeDialog, {
366682
- currentVersion: "1.2.1",
366682
+ currentVersion: "1.2.3",
366683
366683
  onChoice: (choice) => {
366684
366684
  setShowSubmenu(null);
366685
366685
  setTabsHidden(false);
@@ -366691,7 +366691,7 @@ function Config({
366691
366691
  autoUpdatesChannel: "stable"
366692
366692
  };
366693
366693
  if (choice === "stay") {
366694
- newSettings.minimumVersion = "1.2.1";
366694
+ newSettings.minimumVersion = "1.2.3";
366695
366695
  }
366696
366696
  updateSettingsForSource("userSettings", newSettings);
366697
366697
  setSettingsData((prev_27) => ({
@@ -372629,9 +372629,17 @@ function createEmptyState() {
372629
372629
  import { mkdir as mkdir27, readdir as readdir21, readFile as readFile36, stat as stat37, writeFile as writeFile29 } from "fs/promises";
372630
372630
  import { basename as basename34, join as join105, resolve as resolve36 } from "path";
372631
372631
  import { homedir as homedir26 } from "os";
372632
+ function setDirectorProjectRoot(projectPath) {
372633
+ _projectStateDir = join105(projectPath, ".claude");
372634
+ }
372635
+ function getStatePath() {
372636
+ if (_projectStateDir)
372637
+ return join105(_projectStateDir, "director-memory.json");
372638
+ return join105(GLOBAL_DIRECTOR_DIR, "state.json");
372639
+ }
372632
372640
  async function loadDirectorState() {
372633
372641
  try {
372634
- const raw = await readFile36(STATE_FILE, "utf-8");
372642
+ const raw = await readFile36(getStatePath(), "utf-8");
372635
372643
  const parsed = JSON.parse(raw);
372636
372644
  if (parsed.version !== 1)
372637
372645
  return createEmptyState();
@@ -372641,8 +372649,9 @@ async function loadDirectorState() {
372641
372649
  }
372642
372650
  }
372643
372651
  async function saveDirectorState(state) {
372644
- await mkdir27(DIRECTOR_DIR, { recursive: true });
372645
- await writeFile29(STATE_FILE, JSON.stringify(state, null, 2), "utf-8");
372652
+ const dir = _projectStateDir || GLOBAL_DIRECTOR_DIR;
372653
+ await mkdir27(dir, { recursive: true });
372654
+ await writeFile29(getStatePath(), JSON.stringify(state, null, 2), "utf-8");
372646
372655
  }
372647
372656
  function slugify(path12) {
372648
372657
  return basename34(resolve36(path12)).toLowerCase().replace(/[^a-z0-9]+/g, "-").replace(/^-|-$/g, "");
@@ -372818,12 +372827,11 @@ function getProjectContext(state, projectId) {
372818
372827
  return lines.join(`
372819
372828
  `);
372820
372829
  }
372821
- var DIRECTOR_DIR, STATE_FILE, DIRECTOR_MEMORY_DIR, KEY_FILES, MAX_FILE_ENTRIES = 100, MAX_TASKS = 200, PRUNE_INTERVAL_MS, PROJECT_STALE_MS, IMPORTANCE_DECAY = 0.95;
372830
+ var GLOBAL_DIRECTOR_DIR, DIRECTOR_MEMORY_DIR, _projectStateDir = "", KEY_FILES, MAX_FILE_ENTRIES = 100, MAX_TASKS = 200, PRUNE_INTERVAL_MS, PROJECT_STALE_MS, IMPORTANCE_DECAY = 0.95;
372822
372831
  var init_directorMemoryOps = __esm(() => {
372823
372832
  init_debug();
372824
- DIRECTOR_DIR = join105(homedir26(), ".claude", "director");
372825
- STATE_FILE = join105(DIRECTOR_DIR, "state.json");
372826
- DIRECTOR_MEMORY_DIR = join105(DIRECTOR_DIR, "memory");
372833
+ GLOBAL_DIRECTOR_DIR = join105(homedir26(), ".claude", "director");
372834
+ DIRECTOR_MEMORY_DIR = join105(GLOBAL_DIRECTOR_DIR, "memory");
372827
372835
  KEY_FILES = [
372828
372836
  "package.json",
372829
372837
  "README.md",
@@ -372840,15 +372848,18 @@ var init_directorMemoryOps = __esm(() => {
372840
372848
  });
372841
372849
 
372842
372850
  // src/services/director/directorPrompts.ts
372843
- function buildDirectorTaskPrompt(task, projectContext, round, maxRounds) {
372851
+ function buildDirectorTaskPrompt(task, projectContext, round, maxRounds, medium) {
372844
372852
  const roundInfo = isFinite(maxRounds) ? `Round ${round} of ${maxRounds}` : `Round ${round} (unlimited)`;
372853
+ const mediumNote = medium === "telegram" ? `
372854
+ - The user is connected via Telegram — progress updates and the final report are sent there automatically` : `
372855
+ - The user is connected via CLI — progress updates are sent as desktop notifications`;
372845
372856
  return `[DIRECTOR MODE — Supervised Autonomous Operation — ${roundInfo}]
372846
372857
 
372847
372858
  You are operating under director supervision. The director:
372848
372859
  - Assigned you a specific task
372849
372860
  - Will review your work after each step
372850
372861
  - May re-prompt if work is incomplete
372851
- - Has persistent memory of this project and past tasks
372862
+ - Has persistent memory of this project and past tasks${mediumNote}
372852
372863
 
372853
372864
  ${projectContext}
372854
372865
 
@@ -372879,17 +372890,20 @@ function buildDirectorReviewPrompt(round, maxRounds, reviewNotes, telegramMsg) {
372879
372890
  const telegramSection = telegramMsg ? `
372880
372891
  ━━━ MESSAGE FROM USER ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
372881
372892
  ${telegramMsg}
372882
- ━━━ (respond to this, then continue) ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
372893
+ ━━━ Respond to this message, then continue your work. ━━━━━━━━━━━━━━
372883
372894
  ` : "";
372884
372895
  return `[DIRECTOR REVIEW — ${roundInfo}]
372885
372896
 
372886
372897
  The director reviewed your last response:
372887
372898
  ${reviewNotes}
372888
372899
  ${telegramSection}
372889
- Continue working. Do not re-explain previous work.
372890
- Pick up exactly where you left off and proceed with the next action.
372891
-
372892
- When ALL work is done, emit: TASK COMPLETE: <summary>`;
372900
+ ━━━ INSTRUCTIONS ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
372901
+ 1. Continue working do not re-explain what was already done
372902
+ 2. Use the Agent tool to spawn subagents for independent parallel work
372903
+ 3. Run builds/tests after significant changes to verify correctness
372904
+ 4. Assess whether the task is complete:
372905
+ - If YES → emit: TASK COMPLETE: <summary of all work done>
372906
+ - If NO → proceed with the next action immediately`;
372893
372907
  }
372894
372908
  function buildDirectorStatusText(projects, recentTasks) {
372895
372909
  const lines = [];
@@ -372969,19 +372983,6 @@ var init_telegramKill = __esm(() => {
372969
372983
  });
372970
372984
 
372971
372985
  // src/services/telegram/telegramBot.ts
372972
- var exports_telegramBot = {};
372973
- __export(exports_telegramBot, {
372974
- validateTelegramToken: () => validateTelegramToken,
372975
- stopTelegram: () => stopTelegram,
372976
- sendTelegramMessage: () => sendTelegramMessage,
372977
- onTelegramMessage: () => onTelegramMessage,
372978
- isTelegramConfigured: () => isTelegramConfigured,
372979
- isTelegramActive: () => isTelegramActive,
372980
- initTelegramWithCredentials: () => initTelegramWithCredentials,
372981
- initTelegram: () => initTelegram,
372982
- getTelegramChatId: () => getTelegramChatId,
372983
- getPendingTelegramMessage: () => getPendingTelegramMessage
372984
- });
372985
372986
  async function api(method, body = {}) {
372986
372987
  const url3 = `https://api.telegram.org/bot${_token}/${method}`;
372987
372988
  const res = await fetch(url3, {
@@ -373018,17 +373019,28 @@ async function sendTelegramMessage(text) {
373018
373019
  }
373019
373020
  }
373020
373021
  }
373022
+ async function sendTypingIndicator() {
373023
+ if (!_polling || !_chatId)
373024
+ return;
373025
+ try {
373026
+ await api("sendChatAction", { chat_id: _chatId, action: "typing" });
373027
+ } catch {}
373028
+ }
373029
+ function startTypingIndicator() {
373030
+ if (_typingInterval)
373031
+ return;
373032
+ sendTypingIndicator();
373033
+ _typingInterval = setInterval(() => void sendTypingIndicator(), 4000);
373034
+ }
373035
+ function stopTypingIndicator() {
373036
+ if (_typingInterval) {
373037
+ clearInterval(_typingInterval);
373038
+ _typingInterval = null;
373039
+ }
373040
+ }
373021
373041
  function getPendingTelegramMessage() {
373022
373042
  return _queue.shift() ?? null;
373023
373043
  }
373024
- function onTelegramMessage(cb) {
373025
- _listeners.push(cb);
373026
- return () => {
373027
- const i2 = _listeners.indexOf(cb);
373028
- if (i2 !== -1)
373029
- _listeners.splice(i2, 1);
373030
- };
373031
- }
373032
373044
  function getTelegramChatId() {
373033
373045
  return _chatId;
373034
373046
  }
@@ -373112,9 +373124,6 @@ Ready to receive commands.`);
373112
373124
  logForDebugging(`[telegram] Init failed: ${e}`, { level: "warn" });
373113
373125
  }
373114
373126
  }
373115
- function stopTelegram() {
373116
- _polling = false;
373117
- }
373118
373127
  async function pollLoop() {
373119
373128
  while (_polling) {
373120
373129
  try {
@@ -373152,22 +373161,46 @@ async function handleUpdate(update) {
373152
373161
  if (!text)
373153
373162
  return;
373154
373163
  logForDebugging(`[telegram] Message from ${sender}: ${text.slice(0, 80)}`);
373155
- if (text === "/stop") {
373156
- globalStopSignal.set(true);
373157
- sendTelegramMessage("Stopping current task...");
373158
- return;
373159
- }
373160
- if (text === "/kill") {
373161
- sendTelegramMessage("Killing ALL localclawd instances...").then(async () => {
373162
- const killed = await killAllIncludingSelf();
373163
- sendTelegramMessage(`Killed ${killed} instance(s). Self-terminating.`);
373164
- });
373164
+ if (text.startsWith("/")) {
373165
+ if (text === "/stop") {
373166
+ globalStopSignal.set(true);
373167
+ sendTelegramMessage("Stopping current task...");
373168
+ return;
373169
+ }
373170
+ if (text === "/kill") {
373171
+ sendTelegramMessage("Killing ALL localclawd instances...").then(async () => {
373172
+ const killed = await killAllIncludingSelf();
373173
+ sendTelegramMessage(`Killed ${killed} instance(s). Self-terminating.`);
373174
+ });
373175
+ return;
373176
+ }
373177
+ if (text === "/start") {
373178
+ sendTelegramMessage(`*localclawd ready*
373179
+ Send me a task and I'll start working on it.
373180
+
373181
+ Commands:
373182
+ /stop — stop current task
373183
+ /kill — kill all instances
373184
+ /status — show current status`);
373185
+ return;
373186
+ }
373187
+ if (text === "/status") {
373188
+ const { getDirectorStatus } = await Promise.resolve().then(() => (init_directorEngine(), exports_directorEngine));
373189
+ const status = await getDirectorStatus();
373190
+ sendTelegramMessage(`*Status*
373191
+ ${status}`);
373192
+ return;
373193
+ }
373194
+ sendTelegramMessage(`Unknown command: ${text}
373195
+
373196
+ Available: /stop /kill /status`);
373165
373197
  return;
373166
373198
  }
373167
373199
  if (isDirectorActive()) {
373168
373200
  _queue.push(text);
373169
373201
  } else {
373170
- sendTelegramMessage(`Starting director mode: ${text.slice(0, 100)}...`);
373202
+ sendTelegramMessage(`Starting director mode...`);
373203
+ sendTypingIndicator();
373171
373204
  try {
373172
373205
  const { enqueue: enqueue2 } = await Promise.resolve().then(() => (init_messageQueueManager(), exports_messageQueueManager));
373173
373206
  enqueue2({ value: `/director ${text}`, mode: "prompt", priority: "now" });
@@ -373203,7 +373236,7 @@ function chunkText(text, maxLen) {
373203
373236
  function sleep5(ms) {
373204
373237
  return new Promise((resolve37) => setTimeout(resolve37, ms));
373205
373238
  }
373206
- var _token = "", _chatId = 0, _polling = false, _lastUpdateId = 0, _queue, _listeners;
373239
+ var _token = "", _chatId = 0, _polling = false, _lastUpdateId = 0, _queue, _listeners, _typingInterval = null;
373207
373240
  var init_telegramBot = __esm(() => {
373208
373241
  init_debug();
373209
373242
  init_telegramSignals();
@@ -373214,6 +373247,21 @@ var init_telegramBot = __esm(() => {
373214
373247
  });
373215
373248
 
373216
373249
  // src/services/director/directorEngine.ts
373250
+ var exports_directorEngine = {};
373251
+ __export(exports_directorEngine, {
373252
+ startDirectorTask: () => startDirectorTask,
373253
+ sendTurnStatus: () => sendTurnStatus,
373254
+ sendDirectorNotification: () => sendDirectorNotification,
373255
+ reviewAndContinue: () => reviewAndContinue,
373256
+ resetDirector: () => resetDirector,
373257
+ isDirectorActive: () => isDirectorActive,
373258
+ getNotifyMedium: () => getNotifyMedium,
373259
+ getDirectorTask: () => getDirectorTask,
373260
+ getDirectorStatus: () => getDirectorStatus,
373261
+ getDirectorRound: () => getDirectorRound,
373262
+ getChangeSummary: () => getChangeSummary,
373263
+ detectStopSignal: () => detectStopSignal
373264
+ });
373217
373265
  function getDirectorRound() {
373218
373266
  return _round;
373219
373267
  }
@@ -373251,6 +373299,7 @@ async function startDirectorTask(task, projectPath, maxRounds, medium) {
373251
373299
  boostProject(state, project.id);
373252
373300
  await indexProjectFiles(state, project.id, projectPath);
373253
373301
  await saveDirectorState(state);
373302
+ setDirectorProjectRoot(projectPath);
373254
373303
  _round = 1;
373255
373304
  _task = task;
373256
373305
  _projectId = project.id;
@@ -373258,9 +373307,8 @@ async function startDirectorTask(task, projectPath, maxRounds, medium) {
373258
373307
  _projectPath = projectPath;
373259
373308
  _notifyMedium = medium ?? (isTelegramActive() ? "telegram" : "desktop");
373260
373309
  _startGitRef = await captureGitRef(projectPath);
373261
- startHeartbeat();
373262
373310
  const context7 = getProjectContext(state, project.id);
373263
- const prompt = buildDirectorTaskPrompt(task, context7, _round, _maxRounds);
373311
+ const prompt = buildDirectorTaskPrompt(task, context7, _round, _maxRounds, _notifyMedium);
373264
373312
  logForDebugging(`[director] Starting task in ${project.id}: ${task.slice(0, 80)}`);
373265
373313
  return { prompt, projectId: project.id };
373266
373314
  }
@@ -373305,12 +373353,16 @@ async function recordTaskOutcome(outcome, summary) {
373305
373353
  logForDebugging(`[director] Failed to record task: ${e}`);
373306
373354
  }
373307
373355
  }
373308
- function startHeartbeat() {
373309
- stopHeartbeat();
373310
- _taskStartTime = Date.now();
373311
- _heartbeatTimer = setInterval(() => {
373312
- sendHeartbeatUpdate();
373313
- }, HEARTBEAT_INTERVAL_MS2);
373356
+ async function sendTurnStatus(lastText) {
373357
+ const elapsed = Math.round((Date.now() - _taskStartTime) / (1000 * 60));
373358
+ const completedLines = lastText.split(`
373359
+ `).filter((l) => /^Completed:/i.test(l.trim())).map((l) => l.trim().slice(0, 120));
373360
+ const progress = completedLines.length > 0 ? completedLines.join(`
373361
+ `) : lastText.slice(0, 200).replace(/\n/g, " ");
373362
+ const msg = `Round ${_round}/${isFinite(_maxRounds) ? _maxRounds : "∞"} · ${elapsed}m elapsed
373363
+ ${progress}`;
373364
+ await sendDirectorNotification("Director", msg);
373365
+ logForDebugging(`[director] Turn status sent: round ${_round}`);
373314
373366
  }
373315
373367
  function stopHeartbeat() {
373316
373368
  if (_heartbeatTimer) {
@@ -373318,15 +373370,6 @@ function stopHeartbeat() {
373318
373370
  _heartbeatTimer = null;
373319
373371
  }
373320
373372
  }
373321
- async function sendHeartbeatUpdate() {
373322
- const elapsed = Math.round((Date.now() - _taskStartTime) / (1000 * 60));
373323
- const msg = `Director heartbeat — still working
373324
- Task: ${_task.slice(0, 100)}
373325
- Round: ${_round}/${isFinite(_maxRounds) ? _maxRounds : "∞"}
373326
- Elapsed: ${elapsed} min`;
373327
- await sendDirectorNotification("localclawd Director — Heartbeat", msg);
373328
- logForDebugging(`[director] Heartbeat sent at ${elapsed}min`);
373329
- }
373330
373373
  async function sendDirectorNotification(title, message) {
373331
373374
  if (_notifyMedium === "telegram" && isTelegramActive()) {
373332
373375
  sendTelegramMessage(`*${title}*
@@ -373438,7 +373481,7 @@ ${status}`;
373438
373481
  return "Unable to generate change summary.";
373439
373482
  }
373440
373483
  }
373441
- var _round = 0, _task = "", _projectId = "", _maxRounds = 20, _startGitRef = "", _projectPath = "", _heartbeatTimer = null, _taskStartTime = 0, _notifyMedium = "desktop", STOP_PATTERNS, HEARTBEAT_INTERVAL_MS2;
373484
+ var _round = 0, _task = "", _projectId = "", _maxRounds = 20, _startGitRef = "", _projectPath = "", _heartbeatTimer = null, _taskStartTime = 0, _notifyMedium = "desktop", STOP_PATTERNS;
373442
373485
  var init_directorEngine = __esm(() => {
373443
373486
  init_directorMemoryOps();
373444
373487
  init_debug();
@@ -373450,7 +373493,6 @@ var init_directorEngine = __esm(() => {
373450
373493
  { pattern: /ALL[_ ]DONE\b/i, label: "all done" },
373451
373494
  { pattern: /WORK[_ ]COMPLETE:/i, label: "work complete" }
373452
373495
  ];
373453
- HEARTBEAT_INTERVAL_MS2 = 30 * 60 * 1000;
373454
373496
  });
373455
373497
 
373456
373498
  // src/commands/director/director.tsx
@@ -373588,20 +373630,25 @@ var React58, jsx_dev_runtime195, DEFAULT_MAX_ROUNDS = 20, call19 = async (onDone
373588
373630
  const { prompt } = await startDirectorTask(task, cwd2, DEFAULT_MAX_ROUNDS, medium);
373589
373631
  sendDirectorNotification("Director", `Starting task:
373590
373632
  ${task.slice(0, 200)}`);
373633
+ if (isTelegramActive())
373634
+ startTypingIndicator();
373591
373635
  return /* @__PURE__ */ jsx_dev_runtime195.jsxDEV(DirectorBanner, {
373592
373636
  round: 1,
373593
373637
  maxRounds: DEFAULT_MAX_ROUNDS,
373594
373638
  task,
373595
373639
  telegram: isTelegramActive(),
373596
- onReady: () => onDone(undefined, {
373597
- display: "system",
373598
- shouldQuery: true,
373599
- metaMessages: [prompt],
373600
- nextInput: "/director",
373601
- submitNextInput: true
373602
- })
373640
+ onReady: () => {
373641
+ enqueue({ value: "/director", mode: "prompt", isMeta: true });
373642
+ onDone(undefined, {
373643
+ display: "system",
373644
+ shouldQuery: true,
373645
+ metaMessages: [prompt]
373646
+ });
373647
+ }
373603
373648
  }, undefined, false, undefined, this);
373604
373649
  }
373650
+ if (isTelegramActive())
373651
+ stopTypingIndicator();
373605
373652
  if (globalStopSignal.get()) {
373606
373653
  globalStopSignal.reset();
373607
373654
  const round2 = getDirectorRound();
@@ -373625,19 +373672,13 @@ ${changeSummary}` : "";
373625
373672
  return prev;
373626
373673
  });
373627
373674
  if (lastText.trim()) {
373628
- const round2 = getDirectorRound();
373629
- const preview = lastText.slice(0, 1200);
373630
- const suffix = lastText.length > 1200 ? `
373631
- ...(truncated)` : "";
373632
- if (getNotifyMedium() === "telegram" && isTelegramActive()) {
373633
- const { sendTelegramMessage: sendTelegramMessage2 } = await Promise.resolve().then(() => (init_telegramBot(), exports_telegramBot));
373634
- sendTelegramMessage2(`Director round ${round2}:
373635
- ${preview}${suffix}`);
373636
- }
373675
+ sendTurnStatus(lastText);
373637
373676
  }
373638
373677
  const telegramMsg = getPendingTelegramMessage();
373639
373678
  const result = await reviewAndContinue(lastText, telegramMsg);
373640
373679
  if (result.done) {
373680
+ if (isTelegramActive())
373681
+ stopTypingIndicator();
373641
373682
  const round2 = getDirectorRound();
373642
373683
  const reason = result.reason ?? "completed";
373643
373684
  const changeSummary = await getChangeSummary();
@@ -373656,18 +373697,21 @@ ${changeSummary}` : "";
373656
373697
  }
373657
373698
  const round = getDirectorRound();
373658
373699
  const currentTask = getDirectorTask();
373700
+ if (isTelegramActive())
373701
+ startTypingIndicator();
373659
373702
  return /* @__PURE__ */ jsx_dev_runtime195.jsxDEV(DirectorBanner, {
373660
373703
  round,
373661
373704
  maxRounds: DEFAULT_MAX_ROUNDS,
373662
373705
  task: currentTask,
373663
373706
  telegram: isTelegramActive(),
373664
- onReady: () => onDone(undefined, {
373665
- display: "system",
373666
- shouldQuery: true,
373667
- metaMessages: [result.prompt],
373668
- nextInput: "/director",
373669
- submitNextInput: true
373670
- })
373707
+ onReady: () => {
373708
+ enqueue({ value: "/director", mode: "prompt", isMeta: true });
373709
+ onDone(undefined, {
373710
+ display: "system",
373711
+ shouldQuery: true,
373712
+ metaMessages: [result.prompt]
373713
+ });
373714
+ }
373671
373715
  }, undefined, false, undefined, this);
373672
373716
  };
373673
373717
  var init_director = __esm(() => {
@@ -373676,6 +373720,7 @@ var init_director = __esm(() => {
373676
373720
  init_telegramBot();
373677
373721
  init_telegramSignals();
373678
373722
  init_state();
373723
+ init_messageQueueManager();
373679
373724
  React58 = __toESM(require_react(), 1);
373680
373725
  jsx_dev_runtime195 = __toESM(require_jsx_dev_runtime(), 1);
373681
373726
  });
@@ -373687,9 +373732,7 @@ var init_director2 = __esm(() => {
373687
373732
  type: "local-jsx",
373688
373733
  name: "director",
373689
373734
  aliases: ["dir"],
373690
- description: "Director mode persistent memory, supervised autonomous operation",
373691
- isEnabled: true,
373692
- isHidden: false,
373735
+ description: "Supervised autonomous mode with persistent project memory. Usage: /director <task>",
373693
373736
  source: "builtin",
373694
373737
  load: () => Promise.resolve().then(() => (init_director(), exports_director))
373695
373738
  };
@@ -373945,12 +373988,11 @@ Round cap ${finalRound}/${maxRounds} reached.`);
373945
373988
  const nextCmd = `/keepgoing${nextArgs.length ? " " + nextArgs.join(" ") : ""}`;
373946
373989
  const metaMessages = [prompt];
373947
373990
  const handleReady = () => {
373991
+ enqueue({ value: nextCmd, mode: "prompt", isMeta: true });
373948
373992
  onDone(undefined, {
373949
373993
  display: "system",
373950
373994
  shouldQuery: true,
373951
- metaMessages,
373952
- nextInput: nextCmd,
373953
- submitNextInput: true
373995
+ metaMessages
373954
373996
  });
373955
373997
  };
373956
373998
  return /* @__PURE__ */ jsx_dev_runtime196.jsxDEV(KeepGoingBanner, {
@@ -373967,6 +374009,7 @@ var init_keepgoing = __esm(() => {
373967
374009
  init_thinkharder();
373968
374010
  init_telegramBot();
373969
374011
  init_telegramSignals();
374012
+ init_messageQueueManager();
373970
374013
  React59 = __toESM(require_react(), 1);
373971
374014
  jsx_dev_runtime196 = __toESM(require_jsx_dev_runtime(), 1);
373972
374015
  STOP_PATTERNS2 = [
@@ -374279,36 +374322,37 @@ async function saveTelegramConfig(token, chatId) {
374279
374322
  const configPath = join107(configDir, "telegram.json");
374280
374323
  await writeFile30(configPath, JSON.stringify({ token, chatId }, null, 2), "utf-8");
374281
374324
  }
374282
- function TelegramStatus({ onReady }) {
374325
+ function TelegramStatus({
374326
+ onDone
374327
+ }) {
374283
374328
  const active = isTelegramActive();
374284
374329
  const configured = isTelegramConfigured();
374285
- React60.useEffect(() => {
374286
- const id = setTimeout(onReady, 100);
374287
- return () => clearTimeout(id);
374288
- }, [onReady]);
374330
+ const [showSetup, setShowSetup] = React60.useState(false);
374331
+ if (showSetup) {
374332
+ return /* @__PURE__ */ jsx_dev_runtime197.jsxDEV(TelegramSetup, {
374333
+ onDone
374334
+ }, undefined, false, undefined, this);
374335
+ }
374289
374336
  if (active) {
374290
- return /* @__PURE__ */ jsx_dev_runtime197.jsxDEV(ThemedBox_default, {
374291
- flexDirection: "column",
374292
- marginTop: 1,
374337
+ return /* @__PURE__ */ jsx_dev_runtime197.jsxDEV(Dialog, {
374338
+ title: "Telegram Bridge",
374339
+ onCancel: () => onDone(),
374340
+ hideInputGuide: true,
374293
374341
  children: [
374294
- /* @__PURE__ */ jsx_dev_runtime197.jsxDEV(ThemedText, {
374295
- bold: true,
374296
- color: "#6366f1",
374297
- children: "◆ Telegram Bridge"
374298
- }, undefined, false, undefined, this),
374299
- /* @__PURE__ */ jsx_dev_runtime197.jsxDEV(ThemedText, {
374300
- color: "green",
374301
- children: " ● Active — bot is polling"
374302
- }, undefined, false, undefined, this),
374303
- /* @__PURE__ */ jsx_dev_runtime197.jsxDEV(ThemedText, {
374304
- dimColor: true,
374305
- children: ` Chat ID: ${getTelegramChatId()}`
374306
- }, undefined, false, undefined, this),
374307
374342
  /* @__PURE__ */ jsx_dev_runtime197.jsxDEV(ThemedBox_default, {
374308
374343
  flexDirection: "column",
374309
- marginLeft: 2,
374310
- marginTop: 1,
374311
374344
  children: [
374345
+ /* @__PURE__ */ jsx_dev_runtime197.jsxDEV(ThemedText, {
374346
+ color: "green",
374347
+ children: "● Active — bot is polling"
374348
+ }, undefined, false, undefined, this),
374349
+ /* @__PURE__ */ jsx_dev_runtime197.jsxDEV(ThemedText, {
374350
+ dimColor: true,
374351
+ children: `Chat ID: ${getTelegramChatId()}`
374352
+ }, undefined, false, undefined, this),
374353
+ /* @__PURE__ */ jsx_dev_runtime197.jsxDEV(ThemedText, {
374354
+ children: ""
374355
+ }, undefined, false, undefined, this),
374312
374356
  /* @__PURE__ */ jsx_dev_runtime197.jsxDEV(ThemedText, {
374313
374357
  dimColor: true,
374314
374358
  children: "Messages from Telegram are injected into /keepgoing and /director rounds."
@@ -374322,23 +374366,55 @@ function TelegramStatus({ onReady }) {
374322
374366
  children: "Send /stop to stop current task, /kill to stop all instances."
374323
374367
  }, undefined, false, undefined, this)
374324
374368
  ]
374325
- }, undefined, true, undefined, this)
374369
+ }, undefined, true, undefined, this),
374370
+ /* @__PURE__ */ jsx_dev_runtime197.jsxDEV(Select, {
374371
+ options: [
374372
+ { label: "OK", value: "ok" },
374373
+ { label: "Reconfigure — run setup again", value: "setup" }
374374
+ ],
374375
+ onChange: (v2) => {
374376
+ if (v2 === "setup")
374377
+ setShowSetup(true);
374378
+ else
374379
+ onDone(undefined);
374380
+ }
374381
+ }, undefined, false, undefined, this)
374326
374382
  ]
374327
374383
  }, undefined, true, undefined, this);
374328
374384
  }
374329
374385
  if (configured) {
374330
- return /* @__PURE__ */ jsx_dev_runtime197.jsxDEV(ThemedBox_default, {
374331
- flexDirection: "column",
374332
- marginTop: 1,
374386
+ return /* @__PURE__ */ jsx_dev_runtime197.jsxDEV(Dialog, {
374387
+ title: "Telegram Bridge",
374388
+ onCancel: () => onDone(),
374389
+ hideInputGuide: true,
374333
374390
  children: [
374334
- /* @__PURE__ */ jsx_dev_runtime197.jsxDEV(ThemedText, {
374335
- bold: true,
374336
- color: "#6366f1",
374337
- children: "◆ Telegram Bridge"
374338
- }, undefined, false, undefined, this),
374339
- /* @__PURE__ */ jsx_dev_runtime197.jsxDEV(ThemedText, {
374340
- color: "yellow",
374341
- children: " ◌ Configured but not active (init failed — check logs)"
374391
+ /* @__PURE__ */ jsx_dev_runtime197.jsxDEV(ThemedBox_default, {
374392
+ flexDirection: "column",
374393
+ children: [
374394
+ /* @__PURE__ */ jsx_dev_runtime197.jsxDEV(ThemedText, {
374395
+ color: "yellow",
374396
+ children: "◌ Configured but not active (init failed — check token/chat ID)"
374397
+ }, undefined, false, undefined, this),
374398
+ /* @__PURE__ */ jsx_dev_runtime197.jsxDEV(ThemedText, {
374399
+ children: ""
374400
+ }, undefined, false, undefined, this),
374401
+ /* @__PURE__ */ jsx_dev_runtime197.jsxDEV(ThemedText, {
374402
+ dimColor: true,
374403
+ children: "The saved credentials may be invalid or expired."
374404
+ }, undefined, false, undefined, this)
374405
+ ]
374406
+ }, undefined, true, undefined, this),
374407
+ /* @__PURE__ */ jsx_dev_runtime197.jsxDEV(Select, {
374408
+ options: [
374409
+ { label: "Reconfigure — run setup again", value: "setup" },
374410
+ { label: "Cancel", value: "cancel" }
374411
+ ],
374412
+ onChange: (v2) => {
374413
+ if (v2 === "setup")
374414
+ setShowSetup(true);
374415
+ else
374416
+ onDone(undefined);
374417
+ }
374342
374418
  }, undefined, false, undefined, this)
374343
374419
  ]
374344
374420
  }, undefined, true, undefined, this);
@@ -374399,7 +374475,7 @@ var React60, jsx_dev_runtime197, call21 = async (onDone, _context, args) => {
374399
374475
  }, undefined, false, undefined, this);
374400
374476
  }
374401
374477
  return /* @__PURE__ */ jsx_dev_runtime197.jsxDEV(TelegramStatus, {
374402
- onReady: () => onDone(undefined)
374478
+ onDone: (msg) => onDone(msg)
374403
374479
  }, undefined, false, undefined, this);
374404
374480
  }
374405
374481
  if (!isTelegramActive()) {
@@ -374653,7 +374729,7 @@ var init_heartbeat2 = __esm(() => {
374653
374729
  type: "local-jsx",
374654
374730
  name: "heartbeat",
374655
374731
  aliases: ["hb"],
374656
- description: "Activate recurring autonomous mode: agent wakes every N minutes without stopping. " + "Only you can stop it (Ctrl+C). /thinkharder is auto-enabled. " + "Usage: /heartbeat <minutes> e.g. /heartbeat 5",
374732
+ description: "Periodic autonomous mode agent re-prompts every N minutes. Usage: /heartbeat 5",
374657
374733
  load: () => Promise.resolve().then(() => (init_heartbeat(), exports_heartbeat))
374658
374734
  };
374659
374735
  heartbeat_default = heartbeat;
@@ -374925,10 +375001,37 @@ var init_ctx2 = __esm(() => {
374925
375001
  ctx_default = ctx;
374926
375002
  });
374927
375003
 
375004
+ // src/commands/ctx/contextsize.tsx
375005
+ var exports_contextsize = {};
375006
+ __export(exports_contextsize, {
375007
+ call: () => call25
375008
+ });
375009
+ var call25 = async (onDone, context7, args) => {
375010
+ const value = (args ?? "").trim();
375011
+ const { call: ctxCall } = await Promise.resolve().then(() => (init_ctx(), exports_ctx));
375012
+ if (value) {
375013
+ return ctxCall(onDone, context7, `set ${value}`);
375014
+ }
375015
+ return ctxCall(onDone, context7, "");
375016
+ };
375017
+
375018
+ // src/commands/ctx/contextsize-index.ts
375019
+ var contextsize, contextsize_index_default;
375020
+ var init_contextsize_index = __esm(() => {
375021
+ contextsize = {
375022
+ type: "local-jsx",
375023
+ name: "contextsize",
375024
+ aliases: ["ctxsize"],
375025
+ description: "Set context window size. Usage: /contextsize 200k | /contextsize auto",
375026
+ load: () => Promise.resolve().then(() => exports_contextsize)
375027
+ };
375028
+ contextsize_index_default = contextsize;
375029
+ });
375030
+
374928
375031
  // src/commands/research/research.tsx
374929
375032
  var exports_research = {};
374930
375033
  __export(exports_research, {
374931
- call: () => call25
375034
+ call: () => call26
374932
375035
  });
374933
375036
  function buildResearchPrompt(topic, thinkHarder) {
374934
375037
  const thinkHarderSection = thinkHarder ? `
@@ -375037,7 +375140,7 @@ function ResearchWarning({
375037
375140
  }, undefined, false, undefined, this)
375038
375141
  }, undefined, false, undefined, this);
375039
375142
  }
375040
- var React64, jsx_dev_runtime201, call25 = async (onDone, _context, args) => {
375143
+ var React64, jsx_dev_runtime201, call26 = async (onDone, _context, args) => {
375041
375144
  const rawArgs = args?.trim() ?? "";
375042
375145
  const { ownArgs: topic, nextCmd } = extractChain(rawArgs);
375043
375146
  if (!topic) {
@@ -375844,7 +375947,7 @@ var init_promptEditor = __esm(() => {
375844
375947
  // src/commands/memory/memory.tsx
375845
375948
  var exports_memory = {};
375846
375949
  __export(exports_memory, {
375847
- call: () => call26
375950
+ call: () => call27
375848
375951
  });
375849
375952
  import { mkdir as mkdir30, writeFile as writeFile31 } from "fs/promises";
375850
375953
  function MemoryCommand({
@@ -375924,7 +376027,7 @@ ${editorHint}`, {
375924
376027
  }, undefined, true, undefined, this)
375925
376028
  }, undefined, false, undefined, this);
375926
376029
  }
375927
- var React65, jsx_dev_runtime204, call26 = async (onDone) => {
376030
+ var React65, jsx_dev_runtime204, call27 = async (onDone) => {
375928
376031
  clearMemoryFileCaches();
375929
376032
  await getMemoryFiles();
375930
376033
  return /* @__PURE__ */ jsx_dev_runtime204.jsxDEV(MemoryCommand, {
@@ -376780,7 +376883,7 @@ function Help(t0) {
376780
376883
  let t6;
376781
376884
  if ($2[31] !== tabs) {
376782
376885
  t6 = /* @__PURE__ */ jsx_dev_runtime208.jsxDEV(Tabs, {
376783
- title: `localclawd v${"1.2.1"}`,
376886
+ title: `localclawd v${"1.2.3"}`,
376784
376887
  color: "professionalBlue",
376785
376888
  defaultTab: "general",
376786
376889
  children: tabs
@@ -376886,9 +376989,9 @@ var init_Help = __esm(() => {
376886
376989
  // src/commands/help/help.tsx
376887
376990
  var exports_help = {};
376888
376991
  __export(exports_help, {
376889
- call: () => call27
376992
+ call: () => call28
376890
376993
  });
376891
- var jsx_dev_runtime209, call27 = async (onDone, {
376994
+ var jsx_dev_runtime209, call28 = async (onDone, {
376892
376995
  options: {
376893
376996
  commands
376894
376997
  }
@@ -377095,7 +377198,7 @@ var init_IdeAutoConnectDialog = __esm(() => {
377095
377198
  var exports_ide = {};
377096
377199
  __export(exports_ide, {
377097
377200
  formatWorkspaceFolders: () => formatWorkspaceFolders,
377098
- call: () => call28
377201
+ call: () => call29
377099
377202
  });
377100
377203
  import * as path12 from "path";
377101
377204
  function IDEScreen(t0) {
@@ -377573,7 +377676,7 @@ function InstallOnMount(t0) {
377573
377676
  import_react113.useEffect(t1, t2);
377574
377677
  return null;
377575
377678
  }
377576
- async function call28(onDone, context7, args) {
377679
+ async function call29(onDone, context7, args) {
377577
377680
  logEvent("tengu_ext_ide_command", {});
377578
377681
  const {
377579
377682
  options: {
@@ -378156,11 +378259,11 @@ var init_template = __esm(() => {
378156
378259
  // src/commands/keybindings/keybindings.ts
378157
378260
  var exports_keybindings = {};
378158
378261
  __export(exports_keybindings, {
378159
- call: () => call29
378262
+ call: () => call30
378160
378263
  });
378161
378264
  import { mkdir as mkdir31, writeFile as writeFile32 } from "fs/promises";
378162
378265
  import { dirname as dirname47 } from "path";
378163
- async function call29() {
378266
+ async function call30() {
378164
378267
  if (!isKeybindingCustomizationEnabled()) {
378165
378268
  return {
378166
378269
  type: "text",
@@ -392691,7 +392794,7 @@ var init_PluginSettings = __esm(() => {
392691
392794
  // src/commands/mcp/mcp.tsx
392692
392795
  var exports_mcp = {};
392693
392796
  __export(exports_mcp, {
392694
- call: () => call30
392797
+ call: () => call31
392695
392798
  });
392696
392799
  function MCPToggle(t0) {
392697
392800
  const $2 = c3(7);
@@ -392744,7 +392847,7 @@ function _temp239(c5) {
392744
392847
  function _temp100(s) {
392745
392848
  return s.mcp.clients;
392746
392849
  }
392747
- async function call30(onDone, _context, args) {
392850
+ async function call31(onDone, _context, args) {
392748
392851
  if (args) {
392749
392852
  const parts = args.trim().split(/\s+/);
392750
392853
  if (parts[0] === "no-redirect") {
@@ -393013,7 +393116,7 @@ function getAllReleaseNotes(changelogContent = getStoredChangelogFromMemory()) {
393013
393116
  return [];
393014
393117
  }
393015
393118
  }
393016
- async function checkForReleaseNotes(lastSeenVersion, currentVersion = "1.2.1") {
393119
+ async function checkForReleaseNotes(lastSeenVersion, currentVersion = "1.2.3") {
393017
393120
  if (process.env.USER_TYPE === "ant") {
393018
393121
  const changelog = MACRO.VERSION_CHANGELOG;
393019
393122
  if (changelog) {
@@ -393040,7 +393143,7 @@ async function checkForReleaseNotes(lastSeenVersion, currentVersion = "1.2.1") {
393040
393143
  releaseNotes
393041
393144
  };
393042
393145
  }
393043
- function checkForReleaseNotesSync(lastSeenVersion, currentVersion = "1.2.1") {
393146
+ function checkForReleaseNotesSync(lastSeenVersion, currentVersion = "1.2.3") {
393044
393147
  if (process.env.USER_TYPE === "ant") {
393045
393148
  const changelog = MACRO.VERSION_CHANGELOG;
393046
393149
  if (changelog) {
@@ -393076,7 +393179,7 @@ var init_releaseNotes = __esm(() => {
393076
393179
  // src/commands/release-notes/release-notes.ts
393077
393180
  var exports_release_notes = {};
393078
393181
  __export(exports_release_notes, {
393079
- call: () => call31
393182
+ call: () => call32
393080
393183
  });
393081
393184
  function formatReleaseNotes(notes) {
393082
393185
  return notes.map(([version, notes2]) => {
@@ -393089,7 +393192,7 @@ ${bulletPoints}`;
393089
393192
 
393090
393193
  `);
393091
393194
  }
393092
- async function call31() {
393195
+ async function call32() {
393093
393196
  let freshNotes = [];
393094
393197
  try {
393095
393198
  const timeoutPromise = new Promise((_2, reject2) => {
@@ -393601,9 +393704,9 @@ var init_createSession = __esm(() => {
393601
393704
  // src/commands/rename/rename.ts
393602
393705
  var exports_rename = {};
393603
393706
  __export(exports_rename, {
393604
- call: () => call32
393707
+ call: () => call33
393605
393708
  });
393606
- async function call32(onDone, context7, args) {
393709
+ async function call33(onDone, context7, args) {
393607
393710
  if (isTeammate()) {
393608
393711
  onDone("Cannot rename: This session is a swarm teammate. Teammate names are set by the team leader.", { display: "system" });
393609
393712
  return null;
@@ -394298,7 +394401,7 @@ function getRecentActivitySync() {
394298
394401
  return cachedActivity;
394299
394402
  }
394300
394403
  function getLogoDisplayData() {
394301
- const version = process.env.DEMO_VERSION ?? "1.2.1";
394404
+ const version = process.env.DEMO_VERSION ?? "1.2.3";
394302
394405
  const serverUrl = getDirectConnectServerUrl();
394303
394406
  const displayPath = process.env.DEMO_VERSION ? "/code/claude" : getDisplayPath(getCwd());
394304
394407
  const cwd2 = serverUrl ? `${displayPath} in ${serverUrl.replace(/^https?:\/\//, "")}` : displayPath;
@@ -395405,7 +395508,7 @@ function Logo() {
395405
395508
  if ($2[2] === Symbol.for("react.memo_cache_sentinel")) {
395406
395509
  t2 = () => {
395407
395510
  const currentConfig = getGlobalConfig();
395408
- if (currentConfig.lastReleaseNotesSeen === "1.2.1") {
395511
+ if (currentConfig.lastReleaseNotesSeen === "1.2.3") {
395409
395512
  return;
395410
395513
  }
395411
395514
  saveGlobalConfig(_temp326);
@@ -396064,12 +396167,12 @@ function Logo() {
396064
396167
  return t41;
396065
396168
  }
396066
396169
  function _temp326(current) {
396067
- if (current.lastReleaseNotesSeen === "1.2.1") {
396170
+ if (current.lastReleaseNotesSeen === "1.2.3") {
396068
396171
  return current;
396069
396172
  }
396070
396173
  return {
396071
396174
  ...current,
396072
- lastReleaseNotesSeen: "1.2.1"
396175
+ lastReleaseNotesSeen: "1.2.3"
396073
396176
  };
396074
396177
  }
396075
396178
  function _temp241(s_0) {
@@ -401962,7 +402065,7 @@ var init_crossProjectResume = __esm(() => {
401962
402065
  var exports_resume = {};
401963
402066
  __export(exports_resume, {
401964
402067
  filterResumableSessions: () => filterResumableSessions,
401965
- call: () => call33
402068
+ call: () => call34
401966
402069
  });
401967
402070
  function resumeHelpMessage(result) {
401968
402071
  switch (result.resultType) {
@@ -402147,7 +402250,7 @@ function ResumeCommand({
402147
402250
  function filterResumableSessions(logs2, currentSessionId) {
402148
402251
  return logs2.filter((l) => !l.isSidechain && getSessionIdFromLog(l) !== currentSessionId);
402149
402252
  }
402150
- var React90, jsx_dev_runtime260, call33 = async (onDone, context7, args) => {
402253
+ var React90, jsx_dev_runtime260, call34 = async (onDone, context7, args) => {
402151
402254
  const onResume = async (sessionId, log2, entrypoint) => {
402152
402255
  try {
402153
402256
  await context7.resume?.(sessionId, log2, entrypoint);
@@ -402637,7 +402740,7 @@ var init_UltrareviewOverageDialog = __esm(() => {
402637
402740
  // src/commands/review/ultrareviewCommand.tsx
402638
402741
  var exports_ultrareviewCommand = {};
402639
402742
  __export(exports_ultrareviewCommand, {
402640
- call: () => call34
402743
+ call: () => call35
402641
402744
  });
402642
402745
  function contentBlocksToString(blocks) {
402643
402746
  return blocks.map((b3) => b3.type === "text" ? b3.text : "").filter(Boolean).join(`
@@ -402657,7 +402760,7 @@ async function launchAndDone(args, context7, onDone, billingNote, signal) {
402657
402760
  });
402658
402761
  }
402659
402762
  }
402660
- var jsx_dev_runtime262, call34 = async (onDone, context7, args) => {
402763
+ var jsx_dev_runtime262, call35 = async (onDone, context7, args) => {
402661
402764
  const gate = await checkOverageGate();
402662
402765
  if (gate.kind === "not-enabled") {
402663
402766
  onDone("Free ultrareviews used. This feature requires a cloud subscription.", {
@@ -406983,7 +407086,7 @@ var init_server = __esm(() => {
406983
407086
  // src/commands/session/session.tsx
406984
407087
  var exports_session = {};
406985
407088
  __export(exports_session, {
406986
- call: () => call35
407089
+ call: () => call36
406987
407090
  });
406988
407091
  function SessionInfo(t0) {
406989
407092
  const $2 = c3(19);
@@ -407156,7 +407259,7 @@ function _temp247(e) {
407156
407259
  function _temp119(s) {
407157
407260
  return s.remoteSessionUrl;
407158
407261
  }
407159
- var import_react150, jsx_dev_runtime263, call35 = async (onDone) => {
407262
+ var import_react150, jsx_dev_runtime263, call36 = async (onDone) => {
407160
407263
  return /* @__PURE__ */ jsx_dev_runtime263.jsxDEV(SessionInfo, {
407161
407264
  onDone
407162
407265
  }, undefined, false, undefined, this);
@@ -407512,9 +407615,9 @@ var init_SkillsMenu = __esm(() => {
407512
407615
  // src/commands/skills/skills.tsx
407513
407616
  var exports_skills2 = {};
407514
407617
  __export(exports_skills2, {
407515
- call: () => call36
407618
+ call: () => call37
407516
407619
  });
407517
- async function call36(onDone, context7) {
407620
+ async function call37(onDone, context7) {
407518
407621
  return /* @__PURE__ */ jsx_dev_runtime265.jsxDEV(SkillsMenu, {
407519
407622
  onExit: onDone,
407520
407623
  commands: context7.options.commands
@@ -407541,9 +407644,9 @@ var init_skills3 = __esm(() => {
407541
407644
  // src/commands/status/status.tsx
407542
407645
  var exports_status = {};
407543
407646
  __export(exports_status, {
407544
- call: () => call37
407647
+ call: () => call38
407545
407648
  });
407546
- async function call37(onDone, context7) {
407649
+ async function call38(onDone, context7) {
407547
407650
  return /* @__PURE__ */ jsx_dev_runtime266.jsxDEV(Settings, {
407548
407651
  onClose: onDone,
407549
407652
  context: context7,
@@ -408154,7 +408257,7 @@ ${reasons}`,
408154
408257
  } : prev);
408155
408258
  }
408156
408259
  }
408157
- var ULTRAPLAN_TIMEOUT_MS, CCR_TERMS_URL2 = "https://github.com/chromebookwiz/localclawd", _rawPrompt, DEFAULT_INSTRUCTIONS, ULTRAPLAN_INSTRUCTIONS, call38 = async (onDone, context7, args) => {
408260
+ var ULTRAPLAN_TIMEOUT_MS, CCR_TERMS_URL2 = "https://github.com/chromebookwiz/localclawd", _rawPrompt, DEFAULT_INSTRUCTIONS, ULTRAPLAN_INSTRUCTIONS, call39 = async (onDone, context7, args) => {
408158
408261
  const blurb = args.trim();
408159
408262
  if (!blurb) {
408160
408263
  const msg = await launchUltraplan2({
@@ -408215,7 +408318,7 @@ var init_ultraplan = __esm(() => {
408215
408318
  argumentHint: "<prompt>",
408216
408319
  isEnabled: () => false,
408217
408320
  load: () => Promise.resolve({
408218
- call: call38
408321
+ call: call39
408219
408322
  })
408220
408323
  };
408221
408324
  });
@@ -412977,9 +413080,9 @@ var init_BackgroundTasksDialog = __esm(() => {
412977
413080
  // src/commands/tasks/tasks.tsx
412978
413081
  var exports_tasks = {};
412979
413082
  __export(exports_tasks, {
412980
- call: () => call39
413083
+ call: () => call40
412981
413084
  });
412982
- async function call39(onDone, context7) {
413085
+ async function call40(onDone, context7) {
412983
413086
  return /* @__PURE__ */ jsx_dev_runtime277.jsxDEV(BackgroundTasksDialog, {
412984
413087
  toolUseContext: context7,
412985
413088
  onDone
@@ -413270,9 +413373,9 @@ var init_terminalSetup2 = __esm(() => {
413270
413373
  // src/commands/usage/usage.tsx
413271
413374
  var exports_usage = {};
413272
413375
  __export(exports_usage, {
413273
- call: () => call40
413376
+ call: () => call41
413274
413377
  });
413275
- var jsx_dev_runtime278, call40 = async (onDone, context7) => {
413378
+ var jsx_dev_runtime278, call41 = async (onDone, context7) => {
413276
413379
  return /* @__PURE__ */ jsx_dev_runtime278.jsxDEV(Settings, {
413277
413380
  onClose: onDone,
413278
413381
  context: context7,
@@ -413303,7 +413406,7 @@ var init_usage3 = __esm(() => {
413303
413406
  // src/commands/theme/theme.tsx
413304
413407
  var exports_theme = {};
413305
413408
  __export(exports_theme, {
413306
- call: () => call41
413409
+ call: () => call42
413307
413410
  });
413308
413411
  function ThemePickerCommand(t0) {
413309
413412
  const $2 = c3(8);
@@ -413353,7 +413456,7 @@ function ThemePickerCommand(t0) {
413353
413456
  }
413354
413457
  return t3;
413355
413458
  }
413356
- var jsx_dev_runtime279, call41 = async (onDone, _context) => {
413459
+ var jsx_dev_runtime279, call42 = async (onDone, _context) => {
413357
413460
  return /* @__PURE__ */ jsx_dev_runtime279.jsxDEV(ThemePickerCommand, {
413358
413461
  onDone
413359
413462
  }, undefined, false, undefined, this);
@@ -413380,9 +413483,9 @@ var init_theme3 = __esm(() => {
413380
413483
  // src/commands/vim/vim.ts
413381
413484
  var exports_vim = {};
413382
413485
  __export(exports_vim, {
413383
- call: () => call42
413486
+ call: () => call43
413384
413487
  });
413385
- var call42 = async () => {
413488
+ var call43 = async () => {
413386
413489
  const config2 = getGlobalConfig();
413387
413490
  let currentMode = config2.editorMode || "normal";
413388
413491
  if (currentMode === "emacs") {
@@ -413423,7 +413526,7 @@ var init_vim2 = __esm(() => {
413423
413526
  var exports_thinkback = {};
413424
413527
  __export(exports_thinkback, {
413425
413528
  playAnimation: () => playAnimation,
413426
- call: () => call43
413529
+ call: () => call44
413427
413530
  });
413428
413531
  import { execa as execa11 } from "execa";
413429
413532
  import { readFile as readFile43 } from "fs/promises";
@@ -413961,7 +414064,7 @@ function ThinkbackFlow(t0) {
413961
414064
  }
413962
414065
  return t8;
413963
414066
  }
413964
- async function call43(onDone) {
414067
+ async function call44(onDone) {
413965
414068
  return /* @__PURE__ */ jsx_dev_runtime280.jsxDEV(ThinkbackFlow, {
413966
414069
  onDone
413967
414070
  }, undefined, false, undefined, this);
@@ -414006,14 +414109,14 @@ var init_thinkback2 = __esm(() => {
414006
414109
  // src/commands/thinkback-play/thinkback-play.ts
414007
414110
  var exports_thinkback_play = {};
414008
414111
  __export(exports_thinkback_play, {
414009
- call: () => call44
414112
+ call: () => call45
414010
414113
  });
414011
414114
  import { join as join117 } from "path";
414012
414115
  function getPluginId2() {
414013
414116
  const marketplaceName = process.env.USER_TYPE === "ant" ? INTERNAL_MARKETPLACE_NAME : OFFICIAL_MARKETPLACE_NAME;
414014
414117
  return `thinkback@${marketplaceName}`;
414015
414118
  }
414016
- async function call44() {
414119
+ async function call45() {
414017
414120
  const v2Data = loadInstalledPluginsV2();
414018
414121
  const pluginId = getPluginId2();
414019
414122
  const installations = v2Data.plugins[pluginId];
@@ -416501,9 +416604,9 @@ var init_PermissionRuleList = __esm(() => {
416501
416604
  // src/commands/permissions/permissions.tsx
416502
416605
  var exports_permissions = {};
416503
416606
  __export(exports_permissions, {
416504
- call: () => call45
416607
+ call: () => call46
416505
416608
  });
416506
- var jsx_dev_runtime288, call45 = async (onDone, context7) => {
416609
+ var jsx_dev_runtime288, call46 = async (onDone, context7) => {
416507
416610
  return /* @__PURE__ */ jsx_dev_runtime288.jsxDEV(PermissionRuleList, {
416508
416611
  onExit: onDone,
416509
416612
  onRetryDenials: (commands) => {
@@ -416533,7 +416636,7 @@ var init_permissions4 = __esm(() => {
416533
416636
  // src/commands/plan/plan.tsx
416534
416637
  var exports_plan = {};
416535
416638
  __export(exports_plan, {
416536
- call: () => call46
416639
+ call: () => call47
416537
416640
  });
416538
416641
  function PlanDisplay(t0) {
416539
416642
  const $2 = c3(11);
@@ -416621,7 +416724,7 @@ function PlanDisplay(t0) {
416621
416724
  }
416622
416725
  return t5;
416623
416726
  }
416624
- async function call46(onDone, context7, args) {
416727
+ async function call47(onDone, context7, args) {
416625
416728
  const {
416626
416729
  getAppState,
416627
416730
  setAppState
@@ -416763,7 +416866,7 @@ var init_FastIcon = __esm(() => {
416763
416866
  // src/commands/fast/fast.tsx
416764
416867
  var exports_fast = {};
416765
416868
  __export(exports_fast, {
416766
- call: () => call47,
416869
+ call: () => call48,
416767
416870
  FastModePicker: () => FastModePicker
416768
416871
  });
416769
416872
  function applyFastMode(enable, setAppState) {
@@ -417078,7 +417181,7 @@ async function handleFastModeShortcut(enable, getAppState, setAppState) {
417078
417181
  return `Fast mode OFF`;
417079
417182
  }
417080
417183
  }
417081
- async function call47(onDone, context7, args) {
417184
+ async function call48(onDone, context7, args) {
417082
417185
  if (!isFastModeEnabled()) {
417083
417186
  return null;
417084
417187
  }
@@ -417386,9 +417489,9 @@ var init_Passes = __esm(() => {
417386
417489
  // src/commands/passes/passes.tsx
417387
417490
  var exports_passes = {};
417388
417491
  __export(exports_passes, {
417389
- call: () => call48
417492
+ call: () => call49
417390
417493
  });
417391
- async function call48(onDone) {
417494
+ async function call49(onDone) {
417392
417495
  const config2 = getGlobalConfig();
417393
417496
  const isFirstVisit = !config2.hasVisitedPasses;
417394
417497
  if (isFirstVisit) {
@@ -418150,9 +418253,9 @@ var init_Grove = __esm(() => {
418150
418253
  // src/commands/privacy-settings/privacy-settings.tsx
418151
418254
  var exports_privacy_settings = {};
418152
418255
  __export(exports_privacy_settings, {
418153
- call: () => call49
418256
+ call: () => call50
418154
418257
  });
418155
- async function call49(onDone) {
418258
+ async function call50(onDone) {
418156
418259
  const qualified = await isQualifiedForGrove();
418157
418260
  if (!qualified) {
418158
418261
  onDone(FALLBACK_MESSAGE);
@@ -419992,9 +420095,9 @@ var init_HooksConfigMenu = __esm(() => {
419992
420095
  // src/commands/hooks/hooks.tsx
419993
420096
  var exports_hooks = {};
419994
420097
  __export(exports_hooks, {
419995
- call: () => call50
420098
+ call: () => call51
419996
420099
  });
419997
- var jsx_dev_runtime301, call50 = async (onDone, context7) => {
420100
+ var jsx_dev_runtime301, call51 = async (onDone, context7) => {
419998
420101
  logEvent("tengu_hooks_command", {});
419999
420102
  const appState = context7.getAppState();
420000
420103
  const permissionContext = appState.toolPermissionContext;
@@ -420026,10 +420129,10 @@ var init_hooks3 = __esm(() => {
420026
420129
  // src/commands/files/files.ts
420027
420130
  var exports_files2 = {};
420028
420131
  __export(exports_files2, {
420029
- call: () => call51
420132
+ call: () => call52
420030
420133
  });
420031
420134
  import { relative as relative26 } from "path";
420032
- async function call51(_args, context7) {
420135
+ async function call52(_args, context7) {
420033
420136
  const files = context7.readFileState ? cacheKeys(context7.readFileState) : [];
420034
420137
  if (files.length === 0) {
420035
420138
  return { type: "text", value: "No files in context" };
@@ -420062,7 +420165,7 @@ var init_files4 = __esm(() => {
420062
420165
  var exports_branch = {};
420063
420166
  __export(exports_branch, {
420064
420167
  deriveFirstPrompt: () => deriveFirstPrompt,
420065
- call: () => call52
420168
+ call: () => call53
420066
420169
  });
420067
420170
  import { randomUUID as randomUUID27 } from "crypto";
420068
420171
  import { mkdir as mkdir33, readFile as readFile44, writeFile as writeFile36 } from "fs/promises";
@@ -420168,7 +420271,7 @@ async function getUniqueForkName(baseName) {
420168
420271
  }
420169
420272
  return `${baseName} (Branch ${nextNumber})`;
420170
420273
  }
420171
- async function call52(onDone, context7, args) {
420274
+ async function call53(onDone, context7, args) {
420172
420275
  const customTitle = args?.trim() || undefined;
420173
420276
  const originalSessionId = getSessionId();
420174
420277
  try {
@@ -426183,9 +426286,9 @@ var init_AgentsMenu = __esm(() => {
426183
426286
  // src/commands/agents/agents.tsx
426184
426287
  var exports_agents = {};
426185
426288
  __export(exports_agents, {
426186
- call: () => call53
426289
+ call: () => call54
426187
426290
  });
426188
- async function call53(onDone, context7) {
426291
+ async function call54(onDone, context7) {
426189
426292
  const appState = context7.getAppState();
426190
426293
  const permissionContext = appState.toolPermissionContext;
426191
426294
  const tools = getTools(permissionContext);
@@ -426216,9 +426319,9 @@ var init_agents2 = __esm(() => {
426216
426319
  // src/commands/plugin/plugin.tsx
426217
426320
  var exports_plugin = {};
426218
426321
  __export(exports_plugin, {
426219
- call: () => call54
426322
+ call: () => call55
426220
426323
  });
426221
- async function call54(onDone, _context, args) {
426324
+ async function call55(onDone, _context, args) {
426222
426325
  return /* @__PURE__ */ jsx_dev_runtime327.jsxDEV(PluginSettings, {
426223
426326
  onComplete: onDone,
426224
426327
  args
@@ -426383,12 +426486,12 @@ var init_refresh = __esm(() => {
426383
426486
  // src/commands/reload-plugins/reload-plugins.ts
426384
426487
  var exports_reload_plugins = {};
426385
426488
  __export(exports_reload_plugins, {
426386
- call: () => call55
426489
+ call: () => call56
426387
426490
  });
426388
426491
  function n(count3, noun) {
426389
426492
  return `${count3} ${plural(count3, noun)}`;
426390
426493
  }
426391
- var call55 = async (_args, context7) => {
426494
+ var call56 = async (_args, context7) => {
426392
426495
  if (false) {}
426393
426496
  const r = await refreshActivePlugins(context7.setAppState);
426394
426497
  const parts = [
@@ -426431,9 +426534,9 @@ var init_reload_plugins2 = __esm(() => {
426431
426534
  // src/commands/rewind/rewind.ts
426432
426535
  var exports_rewind = {};
426433
426536
  __export(exports_rewind, {
426434
- call: () => call56
426537
+ call: () => call57
426435
426538
  });
426436
- async function call56(_args, context7) {
426539
+ async function call57(_args, context7) {
426437
426540
  if (context7.openMessageSelector) {
426438
426541
  context7.openMessageSelector();
426439
426542
  }
@@ -426548,7 +426651,7 @@ async function captureMemoryDiagnostics(trigger, dumpNumber = 0) {
426548
426651
  smapsRollup,
426549
426652
  platform: process.platform,
426550
426653
  nodeVersion: process.version,
426551
- ccVersion: "1.2.1"
426654
+ ccVersion: "1.2.3"
426552
426655
  };
426553
426656
  }
426554
426657
  async function performHeapDump(trigger = "manual", dumpNumber = 0) {
@@ -426618,9 +426721,9 @@ var init_heapDumpService = __esm(() => {
426618
426721
  // src/commands/heapdump/heapdump.ts
426619
426722
  var exports_heapdump = {};
426620
426723
  __export(exports_heapdump, {
426621
- call: () => call57
426724
+ call: () => call58
426622
426725
  });
426623
- async function call57() {
426726
+ async function call58() {
426624
426727
  const result = await performHeapDump();
426625
426728
  if (!result.success) {
426626
426729
  return {
@@ -426991,7 +427094,7 @@ var USAGE = `/bridge-kick <subcommand>
426991
427094
  reconnect-session fail next POST /bridge/reconnect fails
426992
427095
  heartbeat <status> next heartbeat throws BridgeFatalError(status)
426993
427096
  reconnect call reconnectEnvironmentWithSession directly
426994
- status print bridge state`, call58 = async (args) => {
427097
+ status print bridge state`, call59 = async (args) => {
426995
427098
  const h = getBridgeDebugHandle();
426996
427099
  if (!h) {
426997
427100
  return {
@@ -427124,16 +427227,16 @@ var init_bridge_kick = __esm(() => {
427124
427227
  description: "Inject bridge failure states for manual recovery testing",
427125
427228
  isEnabled: () => process.env.USER_TYPE === "ant",
427126
427229
  supportsNonInteractive: false,
427127
- load: () => Promise.resolve({ call: call58 })
427230
+ load: () => Promise.resolve({ call: call59 })
427128
427231
  };
427129
427232
  bridge_kick_default = bridgeKick;
427130
427233
  });
427131
427234
 
427132
427235
  // src/commands/version.ts
427133
- var call59 = async () => {
427236
+ var call60 = async () => {
427134
427237
  return {
427135
427238
  type: "text",
427136
- value: `${"1.2.1"} (built ${"2026-04-15T02:12:12.680Z"})`
427239
+ value: `${"1.2.3"} (built ${"2026-04-18T19:07:42.573Z"})`
427137
427240
  };
427138
427241
  }, version, version_default;
427139
427242
  var init_version = __esm(() => {
@@ -427143,7 +427246,7 @@ var init_version = __esm(() => {
427143
427246
  description: "Print the version this session is running (not what autoupdate downloaded)",
427144
427247
  isEnabled: () => process.env.USER_TYPE === "ant",
427145
427248
  supportsNonInteractive: true,
427146
- load: () => Promise.resolve({ call: call59 })
427249
+ load: () => Promise.resolve({ call: call60 })
427147
427250
  };
427148
427251
  version_default = version;
427149
427252
  });
@@ -428299,10 +428402,10 @@ var init_SandboxSettings = __esm(() => {
428299
428402
  // src/commands/sandbox-toggle/sandbox-toggle.tsx
428300
428403
  var exports_sandbox_toggle = {};
428301
428404
  __export(exports_sandbox_toggle, {
428302
- call: () => call60
428405
+ call: () => call61
428303
428406
  });
428304
428407
  import { relative as relative27 } from "path";
428305
- async function call60(onDone, _context, args) {
428408
+ async function call61(onDone, _context, args) {
428306
428409
  const settings = getSettings_DEPRECATED();
428307
428410
  const themeName = settings.theme || "light";
428308
428411
  const platform3 = getPlatform();
@@ -428407,7 +428510,7 @@ var init_sandbox_toggle2 = __esm(() => {
428407
428510
  });
428408
428511
 
428409
428512
  // src/commands/advisor.ts
428410
- var call61 = async (args, context7) => {
428513
+ var call62 = async (args, context7) => {
428411
428514
  const arg = args.trim().toLowerCase();
428412
428515
  const baseModel = parseUserSpecifiedModel(context7.getAppState().mainLoopModel ?? getDefaultMainLoopModelSetting());
428413
428516
  if (!arg) {
@@ -428493,7 +428596,7 @@ var init_advisor2 = __esm(() => {
428493
428596
  return !canUserConfigureAdvisor();
428494
428597
  },
428495
428598
  supportsNonInteractive: true,
428496
- load: () => Promise.resolve({ call: call61 })
428599
+ load: () => Promise.resolve({ call: call62 })
428497
428600
  };
428498
428601
  advisor_default = advisor;
428499
428602
  });
@@ -428905,12 +429008,12 @@ var init_ExitFlow = __esm(() => {
428905
429008
  // src/commands/exit/exit.tsx
428906
429009
  var exports_exit = {};
428907
429010
  __export(exports_exit, {
428908
- call: () => call62
429011
+ call: () => call63
428909
429012
  });
428910
429013
  function getRandomGoodbyeMessage2() {
428911
429014
  return sample_default(GOODBYE_MESSAGES2) ?? "Goodbye!";
428912
429015
  }
428913
- async function call62(onDone) {
429016
+ async function call63(onDone) {
428914
429017
  if (false) {}
428915
429018
  const showWorktree = getCurrentWorktreeSession() !== null;
428916
429019
  if (showWorktree) {
@@ -429204,7 +429307,7 @@ var exports_export = {};
429204
429307
  __export(exports_export, {
429205
429308
  sanitizeFilename: () => sanitizeFilename,
429206
429309
  extractFirstPrompt: () => extractFirstPrompt,
429207
- call: () => call63
429310
+ call: () => call64
429208
429311
  });
429209
429312
  import { join as join122 } from "path";
429210
429313
  function formatTimestamp(date2) {
@@ -429245,7 +429348,7 @@ async function exportWithReactRenderer(context7) {
429245
429348
  const tools = context7.options.tools || [];
429246
429349
  return renderMessagesToPlainText(context7.messages, tools);
429247
429350
  }
429248
- async function call63(onDone, context7, args) {
429351
+ async function call64(onDone, context7, args) {
429249
429352
  const content = await exportWithReactRenderer(context7);
429250
429353
  const filename = args.trim();
429251
429354
  if (filename) {
@@ -429305,7 +429408,7 @@ var init_export2 = __esm(() => {
429305
429408
  // src/commands/model/model.tsx
429306
429409
  var exports_model2 = {};
429307
429410
  __export(exports_model2, {
429308
- call: () => call64
429411
+ call: () => call65
429309
429412
  });
429310
429413
  function ModelPickerWrapper(t0) {
429311
429414
  const $2 = c3(17);
@@ -429553,7 +429656,7 @@ function renderModelLabel(model) {
429553
429656
  const rendered = renderDefaultModelSetting(model ?? getDefaultMainLoopModelSetting());
429554
429657
  return model === null ? `${rendered} (default)` : rendered;
429555
429658
  }
429556
- var React109, jsx_dev_runtime339, call64 = async (onDone, _context, args) => {
429659
+ var React109, jsx_dev_runtime339, call65 = async (onDone, _context, args) => {
429557
429660
  args = args?.trim() || "";
429558
429661
  if (COMMON_INFO_ARGS.includes(args)) {
429559
429662
  logEvent("tengu_model_command_inline_help", {
@@ -429620,7 +429723,7 @@ var init_model3 = __esm(() => {
429620
429723
  // src/commands/tag/tag.tsx
429621
429724
  var exports_tag = {};
429622
429725
  __export(exports_tag, {
429623
- call: () => call65
429726
+ call: () => call66
429624
429727
  });
429625
429728
  function ConfirmRemoveTag(t0) {
429626
429729
  const $2 = c3(11);
@@ -429844,7 +429947,7 @@ Examples:
429844
429947
  React110.useEffect(t1, t2);
429845
429948
  return null;
429846
429949
  }
429847
- async function call65(onDone, _context, args) {
429950
+ async function call66(onDone, _context, args) {
429848
429951
  args = args?.trim() || "";
429849
429952
  if (COMMON_INFO_ARGS.includes(args) || COMMON_HELP_ARGS.includes(args)) {
429850
429953
  return /* @__PURE__ */ jsx_dev_runtime340.jsxDEV(ShowHelp, {
@@ -429891,9 +429994,9 @@ var init_tag2 = __esm(() => {
429891
429994
  // src/commands/output-style/output-style.tsx
429892
429995
  var exports_output_style = {};
429893
429996
  __export(exports_output_style, {
429894
- call: () => call66
429997
+ call: () => call67
429895
429998
  });
429896
- async function call66(onDone) {
429999
+ async function call67(onDone) {
429897
430000
  onDone("/output-style has been deprecated. Use /config to change your output style, or set it in your settings file. Changes take effect on the next session.", {
429898
430001
  display: "system"
429899
430002
  });
@@ -429915,7 +430018,7 @@ var init_output_style = __esm(() => {
429915
430018
  // src/commands/provider/provider.tsx
429916
430019
  var exports_provider = {};
429917
430020
  __export(exports_provider, {
429918
- call: () => call67
430021
+ call: () => call68
429919
430022
  });
429920
430023
  function formatProviderSavedMessage(config2) {
429921
430024
  const providerLabel = getLocalLLMProviderLabel(config2.provider);
@@ -429929,7 +430032,7 @@ function formatProviderSavedMessage(config2) {
429929
430032
  ].join(`
429930
430033
  `);
429931
430034
  }
429932
- var jsx_dev_runtime341, call67 = async (onDone) => {
430035
+ var jsx_dev_runtime341, call68 = async (onDone) => {
429933
430036
  const config2 = getGlobalConfig();
429934
430037
  function handleComplete(nextConfig) {
429935
430038
  saveGlobalConfig((current) => ({
@@ -430485,9 +430588,9 @@ var init_RemoteEnvironmentDialog = __esm(() => {
430485
430588
  // src/commands/remote-env/remote-env.tsx
430486
430589
  var exports_remote_env = {};
430487
430590
  __export(exports_remote_env, {
430488
- call: () => call68
430591
+ call: () => call69
430489
430592
  });
430490
- async function call68(onDone) {
430593
+ async function call69(onDone) {
430491
430594
  return /* @__PURE__ */ jsx_dev_runtime343.jsxDEV(RemoteEnvironmentDialog, {
430492
430595
  onDone
430493
430596
  }, undefined, false, undefined, this);
@@ -430567,7 +430670,7 @@ var exports_effort = {};
430567
430670
  __export(exports_effort, {
430568
430671
  showCurrentEffort: () => showCurrentEffort,
430569
430672
  executeEffort: () => executeEffort,
430570
- call: () => call69
430673
+ call: () => call70
430571
430674
  });
430572
430675
  function setEffortValue(effortValue) {
430573
430676
  const persistable = toPersistableEffort(effortValue);
@@ -430718,7 +430821,7 @@ function ApplyEffortAndClose(t0) {
430718
430821
  React111.useEffect(t1, t2);
430719
430822
  return null;
430720
430823
  }
430721
- async function call69(onDone, _context, args) {
430824
+ async function call70(onDone, _context, args) {
430722
430825
  args = args?.trim() || "";
430723
430826
  if (COMMON_HELP_ARGS2.includes(args)) {
430724
430827
  onDone(`Usage: /effort [low|medium|high|max|auto]
@@ -433550,9 +433653,9 @@ var init_Stats = __esm(() => {
433550
433653
  // src/commands/stats/stats.tsx
433551
433654
  var exports_stats = {};
433552
433655
  __export(exports_stats, {
433553
- call: () => call70
433656
+ call: () => call71
433554
433657
  });
433555
- var jsx_dev_runtime346, call70 = async (onDone) => {
433658
+ var jsx_dev_runtime346, call71 = async (onDone) => {
433556
433659
  return /* @__PURE__ */ jsx_dev_runtime346.jsxDEV(Stats2, {
433557
433660
  onClose: onDone
433558
433661
  }, undefined, false, undefined, this);
@@ -435077,7 +435180,7 @@ function generateHtmlReport(data, insights) {
435077
435180
  </html>`;
435078
435181
  }
435079
435182
  function buildExportData(data, insights, facets, remoteStats) {
435080
- const version2 = typeof MACRO !== "undefined" ? "1.2.1" : "unknown";
435183
+ const version2 = typeof MACRO !== "undefined" ? "1.2.3" : "unknown";
435081
435184
  const remote_hosts_collected = remoteStats?.hosts.filter((h) => h.sessionCount > 0).map((h) => h.name);
435082
435185
  const facets_summary = {
435083
435186
  total: facets.size,
@@ -436024,6 +436127,7 @@ var init_commands2 = __esm(() => {
436024
436127
  init_heartbeat2();
436025
436128
  init_sysprompt2();
436026
436129
  init_ctx2();
436130
+ init_contextsize_index();
436027
436131
  init_research2();
436028
436132
  init_thinkharder2();
436029
436133
  init_thinknormal_index();
@@ -436159,6 +436263,7 @@ var init_commands2 = __esm(() => {
436159
436263
  copy_default,
436160
436264
  context6,
436161
436265
  contextNonInteractive,
436266
+ contextsize_index_default,
436162
436267
  cost_default,
436163
436268
  diff_default,
436164
436269
  director_default,
@@ -439223,7 +439328,7 @@ var init_sessionStorage = __esm(() => {
439223
439328
  init_settings2();
439224
439329
  init_slowOperations();
439225
439330
  init_uuid();
439226
- VERSION6 = typeof MACRO !== "undefined" ? "1.2.1" : "unknown";
439331
+ VERSION6 = typeof MACRO !== "undefined" ? "1.2.3" : "unknown";
439227
439332
  MAX_TOMBSTONE_REWRITE_BYTES = 50 * 1024 * 1024;
439228
439333
  SKIP_FIRST_PROMPT_PATTERN = /^(?:\s*<[a-z][\w-]*[\s>]|\[Request interrupted by user[^\]]*\])/;
439229
439334
  EPHEMERAL_PROGRESS_TYPES = new Set([
@@ -440425,7 +440530,7 @@ var init_filesystem = __esm(() => {
440425
440530
  });
440426
440531
  getBundledSkillsRoot = memoize_default(function getBundledSkillsRoot2() {
440427
440532
  const nonce = randomBytes19(16).toString("hex");
440428
- return join129(getClaudeTempDir(), "bundled-skills", "1.2.1", nonce);
440533
+ return join129(getClaudeTempDir(), "bundled-skills", "1.2.3", nonce);
440429
440534
  });
440430
440535
  getResolvedWorkingDirPaths = memoize_default(getPathsForPermissionCheck);
440431
440536
  });
@@ -447641,9 +447746,9 @@ var require_extra_typings = __commonJS((exports, module) => {
447641
447746
  });
447642
447747
 
447643
447748
  // node_modules/@commander-js/extra-typings/esm.mjs
447644
- var import__3, program, createCommand, createArgument, createOption, CommanderError, InvalidArgumentError, InvalidOptionArgumentError, Command, Argument, Option, Help2;
447749
+ var import__2, program, createCommand, createArgument, createOption, CommanderError, InvalidArgumentError, InvalidOptionArgumentError, Command, Argument, Option, Help2;
447645
447750
  var init_esm3 = __esm(() => {
447646
- import__3 = __toESM(require_extra_typings(), 1);
447751
+ import__2 = __toESM(require_extra_typings(), 1);
447647
447752
  ({
447648
447753
  program,
447649
447754
  createCommand,
@@ -447656,7 +447761,7 @@ var init_esm3 = __esm(() => {
447656
447761
  Argument,
447657
447762
  Option,
447658
447763
  Help: Help2
447659
- } = import__3.default);
447764
+ } = import__2.default);
447660
447765
  });
447661
447766
 
447662
447767
  // src/utils/apiPreconnect.ts
@@ -449710,7 +449815,7 @@ function buildSystemInitMessage(inputs) {
449710
449815
  slash_commands: inputs.commands.filter((c5) => c5.userInvocable !== false).map((c5) => c5.name),
449711
449816
  apiKeySource: getAnthropicApiKeyWithSource().source,
449712
449817
  betas: getSdkBetas(),
449713
- claude_code_version: "1.2.1",
449818
+ claude_code_version: "1.2.3",
449714
449819
  output_style: outputStyle2,
449715
449820
  agents: inputs.agents.map((agent) => agent.agentType),
449716
449821
  skills: inputs.skills.filter((s) => s.userInvocable !== false).map((skill) => skill.name),
@@ -464289,7 +464394,7 @@ var init_useVoiceEnabled = __esm(() => {
464289
464394
  function getSemverPart(version2) {
464290
464395
  return `${import_semver10.major(version2, { loose: true })}.${import_semver10.minor(version2, { loose: true })}.${import_semver10.patch(version2, { loose: true })}`;
464291
464396
  }
464292
- function useUpdateNotification(updatedVersion, initialVersion = "1.2.1") {
464397
+ function useUpdateNotification(updatedVersion, initialVersion = "1.2.3") {
464293
464398
  const [lastNotifiedSemver, setLastNotifiedSemver] = import_react214.useState(() => getSemverPart(initialVersion));
464294
464399
  if (!updatedVersion) {
464295
464400
  return null;
@@ -464329,7 +464434,7 @@ function AutoUpdater({
464329
464434
  return;
464330
464435
  }
464331
464436
  if (false) {}
464332
- const currentVersion = "1.2.1";
464437
+ const currentVersion = "1.2.3";
464333
464438
  const channel = getInitialSettings()?.autoUpdatesChannel ?? "latest";
464334
464439
  let latestVersion = await getLatestVersion(channel);
464335
464440
  const isDisabled = isAutoUpdaterDisabled();
@@ -464540,12 +464645,12 @@ function NativeAutoUpdater({
464540
464645
  logEvent("tengu_native_auto_updater_start", {});
464541
464646
  try {
464542
464647
  const maxVersion = await getMaxVersion();
464543
- if (maxVersion && gt("1.2.1", maxVersion)) {
464648
+ if (maxVersion && gt("1.2.3", maxVersion)) {
464544
464649
  const msg = await getMaxVersionMessage();
464545
464650
  setMaxVersionIssue(msg ?? "affects your version");
464546
464651
  }
464547
464652
  const result = await installLatest(channel);
464548
- const currentVersion = "1.2.1";
464653
+ const currentVersion = "1.2.3";
464549
464654
  const latencyMs = Date.now() - startTime;
464550
464655
  if (result.lockFailed) {
464551
464656
  logEvent("tengu_native_auto_updater_lock_contention", {
@@ -464680,17 +464785,17 @@ function PackageManagerAutoUpdater(t0) {
464680
464785
  const maxVersion = await getMaxVersion();
464681
464786
  if (maxVersion && latest && gt(latest, maxVersion)) {
464682
464787
  logForDebugging(`PackageManagerAutoUpdater: maxVersion ${maxVersion} is set, capping update from ${latest} to ${maxVersion}`);
464683
- if (gte("1.2.1", maxVersion)) {
464684
- logForDebugging(`PackageManagerAutoUpdater: current version ${"1.2.1"} is already at or above maxVersion ${maxVersion}, skipping update`);
464788
+ if (gte("1.2.3", maxVersion)) {
464789
+ logForDebugging(`PackageManagerAutoUpdater: current version ${"1.2.3"} is already at or above maxVersion ${maxVersion}, skipping update`);
464685
464790
  setUpdateAvailable(false);
464686
464791
  return;
464687
464792
  }
464688
464793
  latest = maxVersion;
464689
464794
  }
464690
- const hasUpdate = latest && !gte("1.2.1", latest) && !shouldSkipVersion(latest);
464795
+ const hasUpdate = latest && !gte("1.2.3", latest) && !shouldSkipVersion(latest);
464691
464796
  setUpdateAvailable(!!hasUpdate);
464692
464797
  if (hasUpdate) {
464693
- logForDebugging(`PackageManagerAutoUpdater: Update available ${"1.2.1"} -> ${latest}`);
464798
+ logForDebugging(`PackageManagerAutoUpdater: Update available ${"1.2.3"} -> ${latest}`);
464694
464799
  }
464695
464800
  };
464696
464801
  $2[0] = t1;
@@ -464724,7 +464829,7 @@ function PackageManagerAutoUpdater(t0) {
464724
464829
  wrap: "truncate",
464725
464830
  children: [
464726
464831
  "currentVersion: ",
464727
- "1.2.1"
464832
+ "1.2.3"
464728
464833
  ]
464729
464834
  }, undefined, true, undefined, this);
464730
464835
  $2[3] = verbose;
@@ -472282,7 +472387,7 @@ function buildStatusLineCommandInput(permissionMode, exceeds200kTokens, settings
472282
472387
  project_dir: getOriginalCwd(),
472283
472388
  added_dirs: addedDirs
472284
472389
  },
472285
- version: "1.2.1",
472390
+ version: "1.2.3",
472286
472391
  output_style: {
472287
472392
  name: outputStyleName
472288
472393
  },
@@ -479493,15 +479598,15 @@ function CancelRequestHandler(props) {
479493
479598
  setToolUseConfirmQueue(() => []);
479494
479599
  if (hasCommandsInQueue()) {
479495
479600
  globalStopSignal.set(true);
479601
+ clearCommandQueue();
479496
479602
  }
479497
479603
  onCancel();
479498
479604
  return;
479499
479605
  }
479500
479606
  if (hasCommandsInQueue()) {
479501
- if (popCommandFromQueue) {
479502
- popCommandFromQueue();
479503
- return;
479504
- }
479607
+ globalStopSignal.set(true);
479608
+ clearCommandQueue();
479609
+ return;
479505
479610
  }
479506
479611
  logEvent("tengu_cancel", cancelProps);
479507
479612
  setToolUseConfirmQueue(() => []);
@@ -483854,7 +483959,7 @@ async function submitTranscriptShare(messages, trigger, appearanceId) {
483854
483959
  } catch {}
483855
483960
  const data = {
483856
483961
  trigger,
483857
- version: "1.2.1",
483962
+ version: "1.2.3",
483858
483963
  platform: process.platform,
483859
483964
  transcript,
483860
483965
  subagentTranscripts: Object.keys(subagentTranscripts).length > 0 ? subagentTranscripts : undefined,
@@ -486119,7 +486224,7 @@ var init_tipRegistry = __esm(() => {
486119
486224
  },
486120
486225
  {
486121
486226
  id: "git-worktrees",
486122
- content: async () => "Use git worktrees to run multiple Claude sessions in parallel.",
486227
+ content: async () => "Use git worktrees to run multiple localclawd sessions in parallel.",
486123
486228
  cooldownSessions: 10,
486124
486229
  isRelevant: async () => {
486125
486230
  try {
@@ -486133,7 +486238,7 @@ var init_tipRegistry = __esm(() => {
486133
486238
  },
486134
486239
  {
486135
486240
  id: "color-when-multi-clauding",
486136
- content: async () => "Running multiple Claude sessions? Use /color and /rename to tell them apart at a glance.",
486241
+ content: async () => "Running multiple localclawd sessions? Use /color and /rename to tell them apart at a glance.",
486137
486242
  cooldownSessions: 10,
486138
486243
  isRelevant: async () => {
486139
486244
  if (getCurrentSessionAgentColor())
@@ -486177,7 +486282,7 @@ var init_tipRegistry = __esm(() => {
486177
486282
  },
486178
486283
  {
486179
486284
  id: "memory-command",
486180
- content: async () => "Use /memory to view and manage Claude memory",
486285
+ content: async () => "Use /memory to view and manage localclawd memory",
486181
486286
  cooldownSessions: 15,
486182
486287
  async isRelevant() {
486183
486288
  const config2 = getGlobalConfig();
@@ -486254,7 +486359,7 @@ var init_tipRegistry = __esm(() => {
486254
486359
  },
486255
486360
  {
486256
486361
  id: "ide-upsell-external-terminal",
486257
- content: async () => "Connect Claude to your IDE · /ide",
486362
+ content: async () => "Connect localclawd to your IDE · /ide",
486258
486363
  cooldownSessions: 4,
486259
486364
  async isRelevant() {
486260
486365
  if (isSupportedTerminal()) {
@@ -486268,12 +486373,6 @@ var init_tipRegistry = __esm(() => {
486268
486373
  return runningIDEs.length > 0;
486269
486374
  }
486270
486375
  },
486271
- {
486272
- id: "install-slack-app",
486273
- content: async () => "Run /install-slack-app to use Claude in Slack",
486274
- cooldownSessions: 10,
486275
- isRelevant: async () => !getGlobalConfig().slackAppInstallCount
486276
- },
486277
486376
  {
486278
486377
  id: "permissions",
486279
486378
  content: async () => "Use /permissions to pre-approve and pre-deny bash, edit, and MCP tools",
@@ -486309,7 +486408,7 @@ var init_tipRegistry = __esm(() => {
486309
486408
  },
486310
486409
  {
486311
486410
  id: "continue",
486312
- content: async () => "Run claude --continue or claude --resume to resume a conversation",
486411
+ content: async () => "Run localclawd --continue or localclawd --resume to resume a conversation",
486313
486412
  cooldownSessions: 10,
486314
486413
  isRelevant: async () => true
486315
486414
  },
@@ -486391,7 +486490,7 @@ var init_tipRegistry = __esm(() => {
486391
486490
  },
486392
486491
  {
486393
486492
  id: "opusplan-mode-reminder",
486394
- content: async () => `Your default model setting is Opus Plan Mode. Press ${getShortcutDisplay("chat:cycleMode", "Chat", "shift+tab")} twice to activate Plan Mode and plan with Claude Opus.`,
486493
+ content: async () => `Press ${getShortcutDisplay("chat:cycleMode", "Chat", "shift+tab")} twice to activate Plan Mode.`,
486395
486494
  cooldownSessions: 2,
486396
486495
  async isRelevant() {
486397
486496
  if (process.env.USER_TYPE === "ant")
@@ -486434,7 +486533,7 @@ ${blue(`/plugin install vercel@${OFFICIAL_MARKETPLACE_NAME}`)}`;
486434
486533
  const blue = color("suggestion", ctx2.theme);
486435
486534
  const cmd = blue("/effort high");
486436
486535
  const variant = getFeatureValue_CACHED_MAY_BE_STALE("tengu_tide_elm", "off");
486437
- return variant === "copy_b" ? `Use ${cmd} for better one-shot answers. Claude thinks it through first.` : `Working on something tricky? ${cmd} gives better first answers`;
486536
+ return variant === "copy_b" ? `Use ${cmd} for better one-shot answers.` : `Working on something tricky? ${cmd} gives better first answers`;
486438
486537
  },
486439
486538
  cooldownSessions: 3,
486440
486539
  isRelevant: async () => {
@@ -500319,7 +500418,7 @@ function appendToLog(path17, message) {
500319
500418
  cwd: getFsImplementation().cwd(),
500320
500419
  userType: process.env.USER_TYPE,
500321
500420
  sessionId: getSessionId(),
500322
- version: "1.2.1"
500421
+ version: "1.2.3"
500323
500422
  };
500324
500423
  getLogWriter(path17).write(messageWithTimestamp);
500325
500424
  }
@@ -504318,8 +504417,8 @@ async function getEnvLessBridgeConfig() {
504318
504417
  }
504319
504418
  async function checkEnvLessBridgeMinVersion() {
504320
504419
  const cfg = await getEnvLessBridgeConfig();
504321
- if (cfg.min_version && lt("1.2.1", cfg.min_version)) {
504322
- return `Your version of localclawd (${"1.2.1"}) is too old for Remote Control.
504420
+ if (cfg.min_version && lt("1.2.3", cfg.min_version)) {
504421
+ return `Your version of localclawd (${"1.2.3"}) is too old for Remote Control.
504323
504422
  Version ${cfg.min_version} or higher is required. Run \`localclawd update\` to update.`;
504324
504423
  }
504325
504424
  return null;
@@ -504791,7 +504890,7 @@ async function initBridgeCore(params) {
504791
504890
  const rawApi = createBridgeApiClient({
504792
504891
  baseUrl,
504793
504892
  getAccessToken,
504794
- runnerVersion: "1.2.1",
504893
+ runnerVersion: "1.2.3",
504795
504894
  onDebug: logForDebugging,
504796
504895
  onAuth401,
504797
504896
  getTrustedDeviceToken
@@ -510510,7 +510609,7 @@ async function startMCPServer(cwd3, debug4, verbose) {
510510
510609
  setCwd(cwd3);
510511
510610
  const server = new Server({
510512
510611
  name: "claude/tengu",
510513
- version: "1.2.1"
510612
+ version: "1.2.3"
510514
510613
  }, {
510515
510614
  capabilities: {
510516
510615
  tools: {}
@@ -511591,7 +511690,7 @@ function WelcomeLogo() {
511591
511690
  dimColor: true,
511592
511691
  children: [
511593
511692
  "v",
511594
- "1.2.1"
511693
+ "1.2.3"
511595
511694
  ]
511596
511695
  }, undefined, true, undefined, this)
511597
511696
  ]
@@ -511782,7 +511881,7 @@ __export(exports_update, {
511782
511881
  });
511783
511882
  async function update() {
511784
511883
  logEvent("tengu_update_check", {});
511785
- writeToStdout(`Current version: ${"1.2.1"}
511884
+ writeToStdout(`Current version: ${"1.2.3"}
511786
511885
  `);
511787
511886
  const channel = getInitialSettings()?.autoUpdatesChannel ?? "latest";
511788
511887
  writeToStdout(`Checking for updates to ${channel} version...
@@ -511857,8 +511956,8 @@ async function update() {
511857
511956
  writeToStdout(`localclawd is managed by Homebrew.
511858
511957
  `);
511859
511958
  const latest = await getLatestVersion(channel);
511860
- if (latest && !gte("1.2.1", latest)) {
511861
- writeToStdout(`Update available: ${"1.2.1"} → ${latest}
511959
+ if (latest && !gte("1.2.3", latest)) {
511960
+ writeToStdout(`Update available: ${"1.2.3"} → ${latest}
511862
511961
  `);
511863
511962
  writeToStdout(`
511864
511963
  `);
@@ -511874,8 +511973,8 @@ async function update() {
511874
511973
  writeToStdout(`localclawd is managed by winget.
511875
511974
  `);
511876
511975
  const latest = await getLatestVersion(channel);
511877
- if (latest && !gte("1.2.1", latest)) {
511878
- writeToStdout(`Update available: ${"1.2.1"} → ${latest}
511976
+ if (latest && !gte("1.2.3", latest)) {
511977
+ writeToStdout(`Update available: ${"1.2.3"} → ${latest}
511879
511978
  `);
511880
511979
  writeToStdout(`
511881
511980
  `);
@@ -511889,8 +511988,8 @@ async function update() {
511889
511988
  writeToStdout(`localclawd is managed by apk.
511890
511989
  `);
511891
511990
  const latest = await getLatestVersion(channel);
511892
- if (latest && !gte("1.2.1", latest)) {
511893
- writeToStdout(`Update available: ${"1.2.1"} → ${latest}
511991
+ if (latest && !gte("1.2.3", latest)) {
511992
+ writeToStdout(`Update available: ${"1.2.3"} → ${latest}
511894
511993
  `);
511895
511994
  writeToStdout(`
511896
511995
  `);
@@ -511955,11 +512054,11 @@ async function update() {
511955
512054
  `);
511956
512055
  await gracefulShutdown(1);
511957
512056
  }
511958
- if (result.latestVersion === "1.2.1") {
511959
- writeToStdout(source_default.green(`localclawd is up to date (${"1.2.1"})`) + `
512057
+ if (result.latestVersion === "1.2.3") {
512058
+ writeToStdout(source_default.green(`localclawd is up to date (${"1.2.3"})`) + `
511960
512059
  `);
511961
512060
  } else {
511962
- writeToStdout(source_default.green(`Successfully updated from ${"1.2.1"} to version ${result.latestVersion}`) + `
512061
+ writeToStdout(source_default.green(`Successfully updated from ${"1.2.3"} to version ${result.latestVersion}`) + `
511963
512062
  `);
511964
512063
  await regenerateCompletionCache();
511965
512064
  }
@@ -512019,12 +512118,12 @@ async function update() {
512019
512118
  `);
512020
512119
  await gracefulShutdown(1);
512021
512120
  }
512022
- if (latestVersion === "1.2.1") {
512023
- writeToStdout(source_default.green(`localclawd is up to date (${"1.2.1"})`) + `
512121
+ if (latestVersion === "1.2.3") {
512122
+ writeToStdout(source_default.green(`localclawd is up to date (${"1.2.3"})`) + `
512024
512123
  `);
512025
512124
  await gracefulShutdown(0);
512026
512125
  }
512027
- writeToStdout(`New version available: ${latestVersion} (current: ${"1.2.1"})
512126
+ writeToStdout(`New version available: ${latestVersion} (current: ${"1.2.3"})
512028
512127
  `);
512029
512128
  writeToStdout(`Installing update...
512030
512129
  `);
@@ -512069,7 +512168,7 @@ async function update() {
512069
512168
  logForDebugging(`update: Installation status: ${status2}`);
512070
512169
  switch (status2) {
512071
512170
  case "success":
512072
- writeToStdout(source_default.green(`Successfully updated from ${"1.2.1"} to version ${latestVersion}`) + `
512171
+ writeToStdout(source_default.green(`Successfully updated from ${"1.2.3"} to version ${latestVersion}`) + `
512073
512172
  `);
512074
512173
  await regenerateCompletionCache();
512075
512174
  break;
@@ -513311,7 +513410,7 @@ Run with --debug for more details.
513311
513410
  }
513312
513411
  }
513313
513412
  logForDiagnosticsNoPII("info", "started", {
513314
- version: "1.2.1",
513413
+ version: "1.2.3",
513315
513414
  is_native_binary: isInBundledMode()
513316
513415
  });
513317
513416
  registerCleanup(async () => {
@@ -514095,7 +514194,7 @@ Usage: localclawd --remote "your task description"`, () => gracefulShutdown(1));
514095
514194
  pendingHookMessages
514096
514195
  }, renderAndRun);
514097
514196
  }
514098
- }).version("1.2.1 (localclawd)", "-v, --version", "Output the version number");
514197
+ }).version("1.2.3 (localclawd)", "-v, --version", "Output the version number");
514099
514198
  program2.option("-w, --worktree [name]", "Create a new git worktree for this session (optionally specify a name)");
514100
514199
  program2.option("--tmux", "Create a tmux session for the worktree (requires --worktree). Uses iTerm2 native panes when available; use --tmux=classic for traditional tmux.");
514101
514200
  if (canUserConfigureAdvisor()) {
@@ -514595,7 +514694,7 @@ if (false) {}
514595
514694
  async function main2() {
514596
514695
  const args = process.argv.slice(2);
514597
514696
  if (args.length === 1 && (args[0] === "--version" || args[0] === "-v" || args[0] === "-V")) {
514598
- console.log(`${"1.2.1"} (localclawd)`);
514697
+ console.log(`${"1.2.3"} (localclawd)`);
514599
514698
  return;
514600
514699
  }
514601
514700
  const {
@@ -514678,4 +514777,4 @@ localclawd crashed: ${msg}
514678
514777
  process.exit(1);
514679
514778
  });
514680
514779
 
514681
- //# debugId=5E9ABEC662C27B3364756E2164756E21
514780
+ //# debugId=D9814C9770A3639464756E2164756E21