vibeostheog 0.23.23 → 0.23.25

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/CHANGELOG.md CHANGED
@@ -1,3 +1,11 @@
1
+ ## 0.23.25
2
+ - fix: footer always shows regime + vector_changed + optimization_mode — no expiry, no hidden conditions
3
+
4
+
5
+ ## 0.23.24
6
+ - fix: ML-driven tier pipeline end-to-end
7
+
8
+
1
9
  ## 0.23.23
2
10
  - fix: apiComputeControlVector overrides server tier_bias with local regime-driven value
3
11
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "vibeostheog",
3
- "version": "0.23.23",
3
+ "version": "0.23.25",
4
4
  "description": "Cost-aware delegation enforcer for OpenCode. Tracks model usage, routes Task subagents to cheaper tiers, surfaces cumulative savings in chat. Includes research audit, reporting framework, project memory, progressive scratchpad decadence, and trinity CLI for brain/medium/cheap slot switching.",
5
5
  "scripts": {
6
6
  "release": "node scripts/release.mjs",
@@ -219,7 +219,7 @@ export function syncControlSettings(cv, options = {}) {
219
219
  writeSessionSlot(sid, slot);
220
220
  writeIf("vector_changed_slot", slot);
221
221
  writeIf("vector_changed_at", Date.now());
222
- const applied = applySlot(slot);
222
+ const applied = applySlot(slot, onSystemTransform._directory || "");
223
223
  if (!applied?.ok) {
224
224
  console.error(`[vibeOS] failed to apply slot ${slot}: ${applied?.reason || "unknown"}`);
225
225
  }
@@ -299,15 +299,18 @@ async function _appendFooter(input, output, directory) {
299
299
  }
300
300
  try {
301
301
  const bb = _latestBlackboxState;
302
- if (bb?.sub_regime)
303
- vibeLine += ` | ${bb.sub_regime}`;
302
+ const regime = bb?.sub_regime || "INIT";
303
+ vibeLine += ` | ${regime}`;
304
304
  }
305
305
  catch { }
306
306
  try {
307
307
  const sel = loadSelection();
308
- if (sel?.vector_changed_slot && sel?.vector_changed_at && (Date.now() - sel.vector_changed_at < 60000)) {
308
+ if (sel?.vector_changed_slot) {
309
309
  vibeLine += ` | → ${sel.vector_changed_slot}`;
310
310
  }
311
+ if (sel?.optimization_mode && sel.optimization_mode !== "auto") {
312
+ vibeLine += ` | ${sel.optimization_mode}`;
313
+ }
311
314
  }
312
315
  catch { }
313
316
  const footerText = stripped + `\n\n${vibeLine} —`;
@@ -1229,7 +1229,7 @@ export function _refreshModel(directory) {
1229
1229
  }
1230
1230
  catch { }
1231
1231
  }
1232
- export function applySlot(slot) {
1232
+ export function applySlot(slot, projectDir = "") {
1233
1233
  try {
1234
1234
  const TIERS_FILE = join(getVibeOSHome(), "model-tiers.json");
1235
1235
  const j = safeJsonParse(readFileSync(TIERS_FILE, "utf-8"));
@@ -1237,11 +1237,11 @@ export function applySlot(slot) {
1237
1237
  if (!ocModel)
1238
1238
  return { ok: false, reason: `slot '${slot}' has no oc model` };
1239
1239
  j.selection.active_slot = slot;
1240
- const _tmp = TIERS_FILE + ".tmp." + Date.now();
1240
+ const _tmp = TIERS_FILE + ".tmp." + Date.now() + "." + Math.random().toString(36).slice(2, 8);
1241
1241
  writeFileSync(_tmp, JSON.stringify(j, null, 2) + "\n", "utf-8");
1242
1242
  renameSync(_tmp, TIERS_FILE);
1243
- // Prefer project-local config to avoid mutating global provider/dropdown config.
1244
- const localOcConfig = join(process.cwd(), "opencode.json");
1243
+ const dir = projectDir || process.cwd();
1244
+ const localOcConfig = join(dir, "opencode.json");
1245
1245
  const ocConfig = existsSync(localOcConfig)
1246
1246
  ? localOcConfig
1247
1247
  : join(getOpenCodeHome(), "opencode.json");
@@ -87,7 +87,7 @@ export function writeSelection(key, value) {
87
87
  if (!j.selection)
88
88
  j.selection = {};
89
89
  j.selection[key] = value;
90
- const tmp = TIERS_FILE + ".tmp";
90
+ const tmp = TIERS_FILE + ".tmp." + Date.now() + "." + Math.random().toString(36).slice(2, 8);
91
91
  writeFileSync(tmp, JSON.stringify(j, null, 2) + "\n");
92
92
  renameSync(tmp, TIERS_FILE);
93
93
  return true;