vibeostheog 0.25.29 → 0.25.30
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.
|
@@ -40,6 +40,8 @@ type StatusResponse = {
|
|
|
40
40
|
model_locked?: boolean
|
|
41
41
|
locked_slot?: string | null
|
|
42
42
|
locked_model?: string | null
|
|
43
|
+
optimization_mode?: string | null
|
|
44
|
+
tiers?: Record<string, { oc?: string }> | null
|
|
43
45
|
}
|
|
44
46
|
|
|
45
47
|
type SavingsResponse = {
|
|
@@ -270,18 +272,31 @@ const plugin: TuiPlugin = async (api, _options, _meta) => {
|
|
|
270
272
|
</Slot>
|
|
271
273
|
<Slot name="sidebar_content" session_id={props.session_id}>
|
|
272
274
|
<box flexDirection="column" padding={1}>
|
|
273
|
-
<text dim bold>
|
|
275
|
+
<text dim bold>MODE TIERS CONNECTED</text>
|
|
274
276
|
<newline />
|
|
275
277
|
<box>
|
|
276
|
-
<text
|
|
277
|
-
|
|
278
|
-
</text>
|
|
279
|
-
{activeSlot === "brain" && <text color="green"> active</text>}
|
|
278
|
+
<text>brain </text>
|
|
279
|
+
<text color={activeSlot === "brain" ? "green" : "dim"}>{s?.tiers?.brain?.oc ?? "-"}</text>
|
|
280
|
+
{activeSlot === "brain" && <text color="green" bold> active</text>}
|
|
280
281
|
</box>
|
|
281
282
|
<newline />
|
|
282
283
|
<box>
|
|
283
|
-
<text>
|
|
284
|
-
<text color={
|
|
284
|
+
<text>medium </text>
|
|
285
|
+
<text color={activeSlot === "medium" ? "green" : "dim"}>{s?.tiers?.medium?.oc ?? "-"}</text>
|
|
286
|
+
{activeSlot === "medium" && <text color="green" bold> active</text>}
|
|
287
|
+
</box>
|
|
288
|
+
<newline />
|
|
289
|
+
<box>
|
|
290
|
+
<text>cheap </text>
|
|
291
|
+
<text color={activeSlot === "cheap" ? "green" : "dim"}>{s?.tiers?.cheap?.oc ?? "-"}</text>
|
|
292
|
+
{activeSlot === "cheap" && <text color="green" bold> active</text>}
|
|
293
|
+
</box>
|
|
294
|
+
<newline />
|
|
295
|
+
<text dim>---</text>
|
|
296
|
+
<newline />
|
|
297
|
+
<box>
|
|
298
|
+
<text>Session </text>
|
|
299
|
+
<text color="green" bold>{s?.active_slot ?? "?"}</text>
|
|
285
300
|
</box>
|
|
286
301
|
<newline />
|
|
287
302
|
<box>
|
package/README.md
CHANGED
|
@@ -30,7 +30,7 @@ vibeOS is not a collection of static rules. It is a learning system that pattern
|
|
|
30
30
|
|
|
31
31
|
The flagship routing strategy. Every turn passes through a three-stage cascade:
|
|
32
32
|
|
|
33
|
-
1. **
|
|
33
|
+
1. **Cheap proposal** — Your configured cheap slot generates an initial response (e.g., a local Ollama model via `trinity set cheap magiccoder:7b`, or any API model).
|
|
34
34
|
2. **Flash review** — DeepSeek v4 Flash critiques and refines the proposal.
|
|
35
35
|
3. **Pro polish** — DeepSeek v4 Pro applies final quality pass on complex sections.
|
|
36
36
|
|
|
@@ -88,13 +88,13 @@ DeepSeek Chat costs $0/turn when routed through the Direct DeepSeek provider (no
|
|
|
88
88
|
|
|
89
89
|
| Policy | Quality vs Brain | Cost vs Brain | Savings | Method |
|
|
90
90
|
|--------|-----------------|--------------|---------|--------|
|
|
91
|
-
| VibeUltraX | 107% | 0.58x | 42% |
|
|
91
|
+
| VibeUltraX | 107% | 0.58x | 42% | cheap -> medium -> brain cascade |
|
|
92
92
|
| VibeQMaX | ~100% | 0.50x | 50% | same model, framework optimizations |
|
|
93
93
|
| Raw Brain | 100% | 1.00x | - | baseline |
|
|
94
94
|
| VibeMaX | ~75% | 0.18x | 82% | trained cascade (conservative escalate) |
|
|
95
95
|
| Budget | ~40% | 0.00x | 100% | direct routing |
|
|
96
96
|
|
|
97
|
-
**VibeUltraX** —
|
|
97
|
+
**VibeUltraX** — Cheap slot proposes, medium reviews, brain refines. 107% quality at 58% cost.
|
|
98
98
|
|
|
99
99
|
**VibeQMaX** — Routes strategic turns through v4 Pro with full thinking, strict enforcement, strict flow checks, and quality TDD. Write/edit delegated per enforcement rules. Blended cost ~$0.00029/turn (50% of brain baseline).
|
|
100
100
|
|
|
@@ -108,7 +108,7 @@ DeepSeek Chat costs $0/turn when routed through the Direct DeepSeek provider (no
|
|
|
108
108
|
|------|-------|----------|-------------|------|-----|
|
|
109
109
|
| Raw Brain | v4 Pro | full | - | - | - |
|
|
110
110
|
| VibeQMaX | v4 Pro | full | strict | strict | quality |
|
|
111
|
-
| VibeUltraX | cascade (
|
|
111
|
+
| VibeUltraX | cascade (cheap->medium->brain) | auto | auto | auto | auto |
|
|
112
112
|
| VibeMaX | v4 Flash (auto-escalate) | auto | auto | auto | auto |
|
|
113
113
|
| Speed | v4 Flash | off | relaxed | audit | lazy |
|
|
114
114
|
| Budget | DeepSeek Chat | off | relaxed | audit | lazy |
|
|
@@ -119,9 +119,9 @@ When auto-mode is active, the VibeBoX control vector is the authority. `syncCont
|
|
|
119
119
|
|
|
120
120
|
| Regime | Mode | Enforce | Flow | TDD | Tier | Think |
|
|
121
121
|
|--------|------|---------|------|-----|------|-------|
|
|
122
|
-
| INIT / DIVERGENT / EXPLORING / REFINING |
|
|
122
|
+
| INIT / DIVERGENT / EXPLORING / REFINING | vibelitex | relaxed | audit | lazy | cheap | off |
|
|
123
123
|
| CONVERGING / CLOSED | quality | strict | strict | quality | brain | full |
|
|
124
|
-
| LOOPING |
|
|
124
|
+
| LOOPING | quality | relaxed | audit | lazy | brain | full |
|
|
125
125
|
|
|
126
126
|
Stress > 1.5 escalates any regime to quality mode regardless of the above mapping.
|
|
127
127
|
|
|
@@ -1 +1 @@
|
|
|
1
|
-
window.__VIBEOS_DASHBOARD_BASE__ = "http://127.0.0.1:
|
|
1
|
+
window.__VIBEOS_DASHBOARD_BASE__ = "http://127.0.0.1:64544";
|
package/dist/vibeOS.js
CHANGED
|
@@ -5542,7 +5542,7 @@ function getApiClient2() {
|
|
|
5542
5542
|
}
|
|
5543
5543
|
return _apiClient;
|
|
5544
5544
|
}
|
|
5545
|
-
function
|
|
5545
|
+
function isApiFallback() {
|
|
5546
5546
|
return _apiFallbackMode || isApiFallbackMode() || !isApiEnabled();
|
|
5547
5547
|
}
|
|
5548
5548
|
function isApiConnected() {
|
|
@@ -7754,7 +7754,7 @@ function classifyTurnSimple2(userText) {
|
|
|
7754
7754
|
async function classifyTurnRemote(text) {
|
|
7755
7755
|
try {
|
|
7756
7756
|
const client2 = getApiClient2();
|
|
7757
|
-
if (!client2 ||
|
|
7757
|
+
if (!client2 || isApiFallback()) {
|
|
7758
7758
|
_lastClassifiedByApi = false;
|
|
7759
7759
|
return classifyTurnSimple(text);
|
|
7760
7760
|
}
|
|
@@ -7804,7 +7804,7 @@ function resolveOptimizationMode(subRegime, stressMultiplier, optimizationMode)
|
|
|
7804
7804
|
const normalized = String(optimizationMode || "auto").toLowerCase();
|
|
7805
7805
|
if (normalized === "auto" || normalized === "")
|
|
7806
7806
|
return autoSelectMode2(subRegime || "INIT", stressMultiplier);
|
|
7807
|
-
if (
|
|
7807
|
+
if (isApiFallback())
|
|
7808
7808
|
return "vibelitex";
|
|
7809
7809
|
if (normalized === "balanced" || normalized === "budget" || normalized === "quality" || normalized === "speed" || normalized === "longrun" || normalized === "audit" || normalized === "forensic" || normalized === "vibeultrax" || normalized === "vibeqmax" || normalized === "vibemax" || normalized === "vibelitex") {
|
|
7810
7810
|
return normalized;
|
|
@@ -7816,7 +7816,7 @@ async function selectOptimizationModeRemote(subRegime, stressMultiplier, fallbac
|
|
|
7816
7816
|
const fallback2 = resolveOptimizationMode(subRegime, stressMultiplier, fallbackMode);
|
|
7817
7817
|
if (normalizedRequestedMode !== "auto" && normalizedRequestedMode !== "")
|
|
7818
7818
|
return fallback2;
|
|
7819
|
-
if (
|
|
7819
|
+
if (isApiFallback())
|
|
7820
7820
|
return fallback2;
|
|
7821
7821
|
try {
|
|
7822
7822
|
const client2 = getApiClient2();
|
|
@@ -8190,7 +8190,7 @@ function resolveEnforcementMode() {
|
|
|
8190
8190
|
async function syncOutcomeToApi(outcome) {
|
|
8191
8191
|
try {
|
|
8192
8192
|
const client2 = getApiClient2();
|
|
8193
|
-
if (!client2 ||
|
|
8193
|
+
if (!client2 || isApiFallback())
|
|
8194
8194
|
return;
|
|
8195
8195
|
await client2.blackboxOutcome(_OC_SID, outcome);
|
|
8196
8196
|
} catch {
|
|
@@ -8199,7 +8199,7 @@ async function syncOutcomeToApi(outcome) {
|
|
|
8199
8199
|
async function fetchBlackboxEnrichment(sessionId, localState) {
|
|
8200
8200
|
try {
|
|
8201
8201
|
const client2 = getApiClient2();
|
|
8202
|
-
if (!client2 ||
|
|
8202
|
+
if (!client2 || isApiFallback())
|
|
8203
8203
|
return null;
|
|
8204
8204
|
const result = await client2.blackboxAnalyze(sessionId, {
|
|
8205
8205
|
userText: "",
|
|
@@ -8586,7 +8586,7 @@ function researchAudit({ hours = 24, session: sessionFilter } = {}) {
|
|
|
8586
8586
|
function normalizeTrend(trend) {
|
|
8587
8587
|
return trend === "up" || trend === "down" ? trend : "flat";
|
|
8588
8588
|
}
|
|
8589
|
-
function buildStatusPayload({ selection, tiersData, currentModel: currentModel3, creditPercent, version, todos, backendConnected, backendHealthUrl, backendVersion, apiFallbackMode, apiFallbackSince, modelLocked, lockedSlot, lockedModel }) {
|
|
8589
|
+
function buildStatusPayload({ selection, tiersData, currentModel: currentModel3, creditPercent, version, todos, backendConnected, backendHealthUrl, backendVersion, apiFallbackMode, apiFallbackSince, modelLocked, lockedSlot, lockedModel, fallbackThinking, optimizationMode, tiers }) {
|
|
8590
8590
|
const activeSlot = selection?.active_slot || "brain";
|
|
8591
8591
|
const todoList = Array.isArray(todos) ? todos : [];
|
|
8592
8592
|
const pendingTodos = todoList.filter((t) => t?.status === "pending").length;
|
|
@@ -8619,6 +8619,8 @@ function buildStatusPayload({ selection, tiersData, currentModel: currentModel3,
|
|
|
8619
8619
|
model_locked: lockActive,
|
|
8620
8620
|
locked_slot: resolvedLockedSlot,
|
|
8621
8621
|
locked_model: resolvedLockedModel,
|
|
8622
|
+
optimization_mode: selection?.optimization_mode || optimizationMode || null,
|
|
8623
|
+
tiers: tiers?.trinity || null,
|
|
8622
8624
|
label_modes: [...LABEL_MODES]
|
|
8623
8625
|
};
|
|
8624
8626
|
}
|
|
@@ -11495,7 +11497,8 @@ function observeToolPattern(toolName, input, output, directory3) {
|
|
|
11495
11497
|
} catch {
|
|
11496
11498
|
}
|
|
11497
11499
|
}
|
|
11498
|
-
if (repeat === 0 && _patternFiredKeys.size > 0) {
|
|
11500
|
+
if (repeat === 0 && _patternFiredKeys.size > 0 && !_trustedCountFired) {
|
|
11501
|
+
_trustedCountFired = true;
|
|
11499
11502
|
try {
|
|
11500
11503
|
updateGlobalLearning((gl) => {
|
|
11501
11504
|
gl.patternQuality ??= { ignoredCount: 0, trustedCount: 0 };
|
|
@@ -12639,7 +12642,7 @@ var onSystemTransform = async (_input, output) => {
|
|
|
12639
12642
|
pushSystem(output, "[vibeOS dashboard display] When the trinity tool returns output starting with '[vibeOS-dashboard]', use the question tool to display that data in a clean, human-readable format. Use the question field (not the header) to show the dashboard data. Format it with clear sections separated by blank lines, aligned columns with spaces, and plain text only. The header should be 'vibeOS Dashboard'. Include only one option in options: {label: 'Dismiss', description: ''}. Strip the '[vibeOS-dashboard]' marker line before displaying.");
|
|
12640
12643
|
}
|
|
12641
12644
|
if (!oneShot("vibeos_dopamine_style_" + fp2)) {
|
|
12642
|
-
pushSystem(output, regimeAwareToolStyleDirective(
|
|
12645
|
+
pushSystem(output, regimeAwareToolStyleDirective(_latestBlackboxState3?.sub_regime || classifiedRegime, _currentTemplate, stressScore));
|
|
12643
12646
|
}
|
|
12644
12647
|
} catch (err) {
|
|
12645
12648
|
console.error(`[vibeOS] system.transform failed: ${err.message}`);
|
|
@@ -12804,6 +12807,9 @@ function buildFooterLine(input) {
|
|
|
12804
12807
|
if (enforcementPulse) {
|
|
12805
12808
|
line += ` | ${enforcementPulse}`;
|
|
12806
12809
|
}
|
|
12810
|
+
if (input.stressGauge) {
|
|
12811
|
+
line += ` | ${input.stressGauge}`;
|
|
12812
|
+
}
|
|
12807
12813
|
if (sessionSlot && sessionSlot !== activeSlot) {
|
|
12808
12814
|
line += ` | session:${sessionSlot}`;
|
|
12809
12815
|
}
|
|
@@ -13038,7 +13044,7 @@ async function _appendFooter(input, output, directory3) {
|
|
|
13038
13044
|
}
|
|
13039
13045
|
const selNowFooter = loadSelection3();
|
|
13040
13046
|
const normalizedIntent = classifyTurnSimple2(latestUserIntent || "");
|
|
13041
|
-
const
|
|
13047
|
+
const currentSubRegime = _latestBlackboxState?.sub_regime || normalizedIntent;
|
|
13042
13048
|
const bbMode = resolveEnforcementMode();
|
|
13043
13049
|
const enfTags = buildEnforcementTags({
|
|
13044
13050
|
delegationEnforce: selNowFooter.delegation_enforce,
|
|
@@ -13056,8 +13062,8 @@ async function _appendFooter(input, output, directory3) {
|
|
|
13056
13062
|
const ltTotal = ltTasks + ltCache;
|
|
13057
13063
|
const activeSlot = selNowFooter.active_slot || "brain";
|
|
13058
13064
|
const flashIcon = isApiConnected() ? " \u26A1" : "";
|
|
13059
|
-
const
|
|
13060
|
-
const vibeBrand = resolveBrand(loadOptimizationMode() ||
|
|
13065
|
+
const displayMode = autoSelectMode2(currentSubRegime, _footerStress);
|
|
13066
|
+
const vibeBrand = resolveBrand(loadOptimizationMode() || displayMode, activeSlot);
|
|
13061
13067
|
const vibeLine = buildFooterLine({
|
|
13062
13068
|
activeSlot,
|
|
13063
13069
|
providerLabel: execution.provider_label,
|
|
@@ -13065,12 +13071,13 @@ async function _appendFooter(input, output, directory3) {
|
|
|
13065
13071
|
ltTotal,
|
|
13066
13072
|
ltTrend: sesTrend,
|
|
13067
13073
|
vibeBrand,
|
|
13068
|
-
optMode:
|
|
13074
|
+
optMode: displayMode,
|
|
13069
13075
|
flashIcon,
|
|
13070
13076
|
enfTags,
|
|
13071
13077
|
sessionSlot,
|
|
13072
13078
|
vectorChangedSlot: selNowFooter?.vector_changed_slot,
|
|
13073
|
-
subRegime:
|
|
13079
|
+
subRegime: currentSubRegime,
|
|
13080
|
+
stressGauge: _footerStress > 0.85 ? "\u2588" : _footerStress > 0.7 ? "\u2586" : _footerStress > 0.5 ? "\u2585" : _footerStress > 0.3 ? "\u2583" : _footerStress > 0.1 ? "\u2582" : "\u2581"
|
|
13074
13081
|
});
|
|
13075
13082
|
const footerText = stripped + `
|
|
13076
13083
|
|
|
@@ -15167,7 +15174,7 @@ var onToolExecuteAfter = async (input, output) => {
|
|
|
15167
15174
|
}
|
|
15168
15175
|
const execution = resolveExecutionIdentity(displayModel || resolvedModel || "", projectDirectory);
|
|
15169
15176
|
const currentSid = _OC_SID;
|
|
15170
|
-
const
|
|
15177
|
+
const currentSubRegime = loadBlackboxState()?.sessions?.[currentSid]?.sub_regime || classifyTurnSimple2(latestUserIntent || "");
|
|
15171
15178
|
const bbMode = resolveEnforcementMode();
|
|
15172
15179
|
const enfTags = buildEnforcementTags({
|
|
15173
15180
|
delegationEnforce: selNow.delegation_enforce,
|
|
@@ -15178,8 +15185,8 @@ var onToolExecuteAfter = async (input, output) => {
|
|
|
15178
15185
|
quietIntent: isGreetingLike2(latestUserIntent || "")
|
|
15179
15186
|
});
|
|
15180
15187
|
const activeSlot = selNow.active_slot || (execution.quality === "brain" ? "brain" : execution.quality === "medium" ? "medium" : "cheap");
|
|
15181
|
-
const
|
|
15182
|
-
const vibeBrand = resolveBrand(
|
|
15188
|
+
const displayMode = autoSelectMode2(currentSubRegime, latestUserIntent ? scoreStress(latestUserIntent) : 0);
|
|
15189
|
+
const vibeBrand = resolveBrand(displayMode, activeSlot);
|
|
15183
15190
|
const sessionSlot = loadSessionSlot(currentSid);
|
|
15184
15191
|
const flashIcon = isApiConnected() ? " \u26A1" : "";
|
|
15185
15192
|
_footerText = buildFooterLine({
|
|
@@ -15189,12 +15196,12 @@ var onToolExecuteAfter = async (input, output) => {
|
|
|
15189
15196
|
ltTotal,
|
|
15190
15197
|
ltTrend: sesTrend || "",
|
|
15191
15198
|
vibeBrand,
|
|
15192
|
-
optMode:
|
|
15199
|
+
optMode: displayMode,
|
|
15193
15200
|
flashIcon,
|
|
15194
15201
|
enfTags,
|
|
15195
15202
|
sessionSlot,
|
|
15196
15203
|
vectorChangedSlot: selNow.vector_changed_slot,
|
|
15197
|
-
subRegime:
|
|
15204
|
+
subRegime: currentSubRegime
|
|
15198
15205
|
}) + "\n\n";
|
|
15199
15206
|
const footerTarget = _payload(output);
|
|
15200
15207
|
output.title = _footerText.trim();
|
|
@@ -15934,7 +15941,15 @@ async function ensureMcpServerRunning() {
|
|
|
15934
15941
|
backendConnected: isApiConnected(),
|
|
15935
15942
|
backendHealthUrl: `${VIBEOS_API_URL}/health`,
|
|
15936
15943
|
backendVersion: getBackendVersion(),
|
|
15937
|
-
|
|
15944
|
+
optimizationMode: loadSelection()?.optimization_mode || null,
|
|
15945
|
+
tiers: (() => {
|
|
15946
|
+
try {
|
|
15947
|
+
return safeJsonParse2(readFileSync17(getTiersFile(), "utf-8"))?.trinity;
|
|
15948
|
+
} catch {
|
|
15949
|
+
return null;
|
|
15950
|
+
}
|
|
15951
|
+
})(),
|
|
15952
|
+
apiFallbackMode: isApiFallback(),
|
|
15938
15953
|
apiFallbackSince: getApiFallbackSince(),
|
|
15939
15954
|
modelLocked: _modelLocked,
|
|
15940
15955
|
lockedSlot: _lockedSlot,
|
|
@@ -16320,7 +16335,7 @@ async function DelegationEnforcer({ client: client2, directory: directory3 } = {
|
|
|
16320
16335
|
setBlackboxEnabled,
|
|
16321
16336
|
loadBlackboxState,
|
|
16322
16337
|
saveBlackboxState,
|
|
16323
|
-
isApiFallback: () =>
|
|
16338
|
+
isApiFallback: () => isApiFallback(),
|
|
16324
16339
|
get _apiFallbackSince() {
|
|
16325
16340
|
return getApiFallbackSince();
|
|
16326
16341
|
},
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "vibeostheog",
|
|
3
|
-
"version": "0.25.
|
|
3
|
+
"version": "0.25.30",
|
|
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",
|