@ngosangns/ns-bridge 0.1.19 → 0.1.21

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,4 +1,4 @@
1
- // @ngosangns/ns-bridge 0.1.19 — catalog refresh bundle.
1
+ // @ngosangns/ns-bridge 0.1.21 — catalog refresh bundle.
2
2
  import { createRequire as __nsBridgeCreateRequire } from 'node:module';
3
3
  const require = __nsBridgeCreateRequire(import.meta.url);
4
4
  var __create = Object.create;
@@ -98920,6 +98920,29 @@ function getKiroEffortConfig(schema, kiroModelId) {
98920
98920
 
98921
98921
  // ../kiro-core/dist/models.js
98922
98922
  init_endpoints();
98923
+
98924
+ // ../kiro-core/dist/long-context.js
98925
+ var KIRO_LONG_CONTEXT_THRESHOLDS = {
98926
+ "gpt-5-6-luna": 272e3,
98927
+ "gpt-5-6-sol": 272e3,
98928
+ "gpt-5-6-terra": 272e3
98929
+ };
98930
+ var KIRO_CLAUDE_COMPACTION_TARGET = 15e4;
98931
+ function kiroCompactionTarget(model) {
98932
+ if (!model.id.startsWith("claude-"))
98933
+ return void 0;
98934
+ if (model.contextWindow <= 2e5)
98935
+ return void 0;
98936
+ if (KIRO_CLAUDE_COMPACTION_TARGET >= model.contextWindow)
98937
+ return void 0;
98938
+ return KIRO_CLAUDE_COMPACTION_TARGET;
98939
+ }
98940
+ function kiroStandardContextWindow(model) {
98941
+ const threshold = Object.hasOwn(KIRO_LONG_CONTEXT_THRESHOLDS, model.id) ? KIRO_LONG_CONTEXT_THRESHOLDS[model.id] : void 0;
98942
+ return threshold !== void 0 && threshold < model.contextWindow ? threshold : model.contextWindow;
98943
+ }
98944
+
98945
+ // ../kiro-core/dist/models.js
98923
98946
  init_profile();
98924
98947
  init_endpoints();
98925
98948
  var KIRO_MANAGEMENT_CACHE_VERSION = 1;
@@ -99143,7 +99166,7 @@ var kiroModels = bootstrapKiroModels.map((model) => ({
99143
99166
  // The seed is what a machine that never refreshed serves, so it carries the
99144
99167
  // same budget a refresh would write. `compactionBudget` never returns
99145
99168
  // undefined for these windows.
99146
- compaction: compactionBudget(model) ?? { reserveTokens: model.maxTokens, thresholdTokens: model.contextWindow }
99169
+ compaction: kiroCompactionBudget(model) ?? { reserveTokens: model.maxTokens, thresholdTokens: model.contextWindow }
99147
99170
  }));
99148
99171
  var BOOTSTRAP_KIRO_MODEL_IDS = kiroModels.map((model) => model.kiroModelId);
99149
99172
  var KIRO_MODEL_IDS = new Set(BOOTSTRAP_KIRO_MODEL_IDS);
@@ -99264,8 +99287,18 @@ function hasReasoningFamilyFallback(modelId) {
99264
99287
  function hasVerifiedImageInput(kiroModelId) {
99265
99288
  return kiroModelId.startsWith("claude-") || VERIFIED_IMAGE_MODEL_IDS.has(kiroModelId.toLowerCase());
99266
99289
  }
99290
+ function kiroCompactionBudget(model) {
99291
+ const target = kiroCompactionTarget(model);
99292
+ if (target !== void 0) {
99293
+ return {
99294
+ reserveTokens: Math.max(1, Math.min(Math.floor(model.maxTokens), COMPACTION_RESERVE_FLOOR)),
99295
+ thresholdTokens: target
99296
+ };
99297
+ }
99298
+ return compactionBudget({ contextWindow: kiroStandardContextWindow(model), maxTokens: model.maxTokens });
99299
+ }
99267
99300
  function withCompaction3(model) {
99268
- const budget = compactionBudget(model);
99301
+ const budget = kiroCompactionBudget(model);
99269
99302
  if (!budget)
99270
99303
  return model;
99271
99304
  const current = model.compaction;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ngosangns/ns-bridge",
3
- "version": "0.1.19",
3
+ "version": "0.1.21",
4
4
  "description": "Install, update, and refresh ns-bridge providers outside Pi, OMP, and DSH.",
5
5
  "type": "module",
6
6
  "license": "MIT",