switchroom 0.12.22 → 0.12.24

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.
@@ -47247,8 +47247,8 @@ var {
47247
47247
  } = import__.default;
47248
47248
 
47249
47249
  // src/build-info.ts
47250
- var VERSION = "0.12.22";
47251
- var COMMIT_SHA = "332e23e";
47250
+ var VERSION = "0.12.24";
47251
+ var COMMIT_SHA = "7ab1329";
47252
47252
 
47253
47253
  // src/cli/agent.ts
47254
47254
  init_source();
@@ -48583,11 +48583,32 @@ function installHindsightPlugin(agentName, agentDir, switchroomConfig) {
48583
48583
  rmSync3(destPath, { recursive: true, force: true });
48584
48584
  }
48585
48585
  copyDirRecursive2(sourcePath, destPath);
48586
+ applyHindsightSettingsOverrides(destPath);
48586
48587
  const bankId = agentMemory?.collection ?? agentName;
48587
48588
  const mcpUrl = memory.config?.url ?? "http://127.0.0.1:8888/mcp/";
48588
48589
  const apiBaseUrl = mcpUrl.replace(/\/mcp\/?$/, "").replace(/\/$/, "");
48589
48590
  return { pluginDir: destPath, apiBaseUrl, bankId };
48590
48591
  }
48592
+ function applyHindsightSettingsOverrides(pluginDestPath) {
48593
+ const settingsPath = join8(pluginDestPath, "settings.json");
48594
+ if (!existsSync11(settingsPath))
48595
+ return;
48596
+ let raw;
48597
+ try {
48598
+ raw = readFileSync11(settingsPath, "utf-8");
48599
+ } catch {
48600
+ return;
48601
+ }
48602
+ let settings;
48603
+ try {
48604
+ settings = JSON.parse(raw);
48605
+ } catch {
48606
+ return;
48607
+ }
48608
+ settings.retainEveryNTurns = 1;
48609
+ writeFileSync5(settingsPath, JSON.stringify(settings, null, 2) + `
48610
+ `, "utf-8");
48611
+ }
48591
48612
  function buildWorkspaceContext(args) {
48592
48613
  const {
48593
48614
  name,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "switchroom",
3
- "version": "0.12.22",
3
+ "version": "0.12.24",
4
4
  "description": "Run Claude Code 24/7 on your Claude Pro/Max subscription over Telegram. Open-source alternative to OpenClaw and NanoClaw — no API keys.",
5
5
  "type": "module",
6
6
  "bin": {