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.
- package/dist/cli/switchroom.js +23 -2
- package/package.json +1 -1
- package/telegram-plugin/dist/gateway/gateway.js +350 -105
- package/telegram-plugin/gateway/gateway.ts +35 -0
- package/telegram-plugin/gateway/inbound-delivery-machine-shadow.ts +117 -0
- package/telegram-plugin/gateway/inbound-delivery-machine.ts +435 -0
- package/telegram-plugin/tests/inbound-delivery-machine.test.ts +475 -0
- package/telegram-plugin/uat/scenarios/jtbd-fast-trivial-dm.test.ts +127 -0
- package/telegram-plugin/uat/scenarios/jtbd-memory-survives-restart-dm.test.ts +239 -0
- package/telegram-plugin/uat/scenarios/jtbd-wake-audit-content-dm.test.ts +145 -0
package/dist/cli/switchroom.js
CHANGED
|
@@ -47247,8 +47247,8 @@ var {
|
|
|
47247
47247
|
} = import__.default;
|
|
47248
47248
|
|
|
47249
47249
|
// src/build-info.ts
|
|
47250
|
-
var VERSION = "0.12.
|
|
47251
|
-
var COMMIT_SHA = "
|
|
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