dsh-model-switch 0.4.56 → 0.4.57

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.
@@ -1,2 +1,2 @@
1
- import { a as bindAutoReviewSessionCorrelation, c as installToolCallSafetyNet, d as resolveSessionAutoReviewRoute, f as reviewLlm, i as autoReviewStatus, l as isReviewerInfrastructureFailure, n as autoReviewGate, o as defensivePermissionPresets, p as reviewScope, r as autoReviewRouteOf, s as inject, t as apply, u as name } from "./auto-review-D0RrXQQb.js";
1
+ import { a as bindAutoReviewSessionCorrelation, c as installToolCallSafetyNet, d as resolveSessionAutoReviewRoute, f as reviewLlm, i as autoReviewStatus, l as isReviewerInfrastructureFailure, n as autoReviewGate, o as defensivePermissionPresets, p as reviewScope, r as autoReviewRouteOf, s as inject, t as apply, u as name } from "./auto-review-0qWCLB6y.js";
2
2
  export { apply, autoReviewGate, autoReviewRouteOf, autoReviewStatus, bindAutoReviewSessionCorrelation, defensivePermissionPresets, inject, installToolCallSafetyNet, isReviewerInfrastructureFailure, name, resolveSessionAutoReviewRoute, reviewLlm, reviewScope };
@@ -292,21 +292,19 @@ function installAutomodeCompat(ctx, loader, settings) {
292
292
  * Row entry point: adapt the third-party row on activation and on remount.
293
293
  * @param ctx - this row's context.
294
294
  */
295
- function apply(ctx) {
296
- const runtime = ctx.get("modelSwitch", false);
297
- if (runtime === void 0) {
298
- ctx.logger.warn("model-switch: the automode-compat row is mounted without the modelSwitch service; the classifier route is left untouched");
299
- return;
300
- }
301
- const loader = ctx.get("loader", false);
302
- const settings = () => runtime.currentSettings();
303
- const adapter = installAutomodeCompat(ctx, loader, settings);
304
- ctx.effect(function* () {
305
- yield adapter.dispose;
306
- yield ctx.on("model-switch/settings-update", () => {
307
- if (adapter.replay()) ctx.logger.info(`model-switch: re-applied the dsh-automode adaptation after a settings change (${lastSummary})`);
308
- });
309
- }, "model-switch: keep the dsh-automode adapter aligned with the settings");
295
+ function apply(outer) {
296
+ outer.inject(["modelSwitch"], (ctx) => {
297
+ const runtime = ctx.modelSwitch;
298
+ const loader = ctx.get("loader", false);
299
+ const settings = () => runtime.currentSettings();
300
+ const adapter = installAutomodeCompat(ctx, loader, settings);
301
+ ctx.effect(function* () {
302
+ yield adapter.dispose;
303
+ yield ctx.on("model-switch/settings-update", () => {
304
+ if (adapter.replay()) ctx.logger.info(`model-switch: re-applied the dsh-automode adaptation after a settings change (${lastSummary})`);
305
+ });
306
+ }, "model-switch: keep the dsh-automode adapter aligned with the settings");
307
+ });
310
308
  }
311
309
  //#endregion
312
310
  export { AUTOMODE_PACKAGE, apply, automodeCompatStatus, automodeCompatView, describeAutomodePlan, inject, installAutomodeCompat, isAutomodeEntry, name, planAutomodeCompat };
package/lib/index.js CHANGED
@@ -1,9 +1,10 @@
1
1
  import { s as normalizeProviderGroups } from "./session-route-D8izd8Zd.js";
2
2
  import { r as resolveToolSource, t as DEFAULT_READ_ONLY_TOOLS } from "./tool-allowlist-DlzB5GlQ.js";
3
- import { i as autoReviewStatus } from "./auto-review-D0RrXQQb.js";
3
+ import { i as autoReviewStatus } from "./auto-review-0qWCLB6y.js";
4
4
  import { ModelSwitchAdapterRegistry } from "./adapter-registry.js";
5
5
  import { automodeCompatView } from "./automode-compat.js";
6
- import { u as reviewTimeoutStatus } from "./review-timeout-CKTTDj8g.js";
6
+ import { u as reviewTimeoutStatus } from "./review-timeout-DJJot3kf.js";
7
+ import { l as primeMemoryCompatStatus } from "./prime-memory-compat-X6WlrtaN.js";
7
8
  import { createRequire } from "node:module";
8
9
  import z from "@deepseek-ai/schemastery";
9
10
  import { Service } from "@deepseek-ai/cordis";
@@ -543,6 +544,12 @@ function installCapabilitiesRpc(ctx, registry, snapshot) {
543
544
  allowedCalls: autoReviewStatus.allowedCalls,
544
545
  skippedReadOnly: autoReviewStatus.skippedReadOnly,
545
546
  automode: automodeCompatView(),
547
+ primeMemory: {
548
+ installed: primeMemoryCompatStatus.installed,
549
+ route: primeMemoryCompatStatus.route,
550
+ routeSkipped: primeMemoryCompatStatus.routeSkipped,
551
+ replays: primeMemoryCompatStatus.replays
552
+ },
546
553
  reviewTimeout: {
547
554
  configuredMs: reviewTimeoutStatus.configuredMs,
548
555
  applied: reviewTimeoutStatus.applied,