@compilr-dev/cli 0.6.3 → 0.6.4
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/compilr-diff-companion.vsix +0 -0
- package/dist/repl-v2.js +25 -19
- package/package.json +1 -1
|
Binary file
|
package/dist/repl-v2.js
CHANGED
|
@@ -3306,28 +3306,34 @@ export class ReplV2 {
|
|
|
3306
3306
|
tokenDisplay += ` (${extras.join(', ')})`;
|
|
3307
3307
|
}
|
|
3308
3308
|
parts.push(tokenDisplay);
|
|
3309
|
-
//
|
|
3309
|
+
// Detailed breakdown is logged (not printed) to keep the per-turn
|
|
3310
|
+
// footer focused on duration + tokens. Set COMPILR_VERBOSE_FOOTER=1
|
|
3311
|
+
// to bring back the inline breakdown for debugging.
|
|
3310
3312
|
const cacheInfo = formatCacheInfo();
|
|
3311
|
-
|
|
3312
|
-
|
|
3313
|
-
|
|
3314
|
-
|
|
3315
|
-
|
|
3316
|
-
|
|
3317
|
-
|
|
3318
|
-
|
|
3313
|
+
const breakdown = cacheInfo ?? formatBreakdownCompact();
|
|
3314
|
+
log.debug({
|
|
3315
|
+
component: 'turn-summary',
|
|
3316
|
+
durationMs: metrics.durationMs,
|
|
3317
|
+
inputTokens: metrics.inputTokens,
|
|
3318
|
+
outputTokens: metrics.outputTokens,
|
|
3319
|
+
thinkingTokens: metrics.thinkingTokens,
|
|
3320
|
+
cacheReadTokens: metrics.cacheReadTokens,
|
|
3321
|
+
toolCalls: metrics.toolCalls,
|
|
3322
|
+
apiCalls: metrics.apiCalls,
|
|
3323
|
+
breakdown,
|
|
3324
|
+
debugPayload: metrics.debugPayload,
|
|
3325
|
+
}, 'Turn summary');
|
|
3326
|
+
if (process.env.COMPILR_VERBOSE_FOOTER === '1') {
|
|
3327
|
+
if (breakdown)
|
|
3319
3328
|
parts.push(breakdown);
|
|
3329
|
+
if (metrics.toolCalls > 0) {
|
|
3330
|
+
parts.push(`${String(metrics.toolCalls)} tool${metrics.toolCalls > 1 ? 's' : ''}`);
|
|
3331
|
+
}
|
|
3332
|
+
if (metrics.debugPayload) {
|
|
3333
|
+
const { systemTokens, contentsTokens, toolsTokens } = metrics.debugPayload;
|
|
3334
|
+
const totalTokens = systemTokens + contentsTokens + toolsTokens;
|
|
3335
|
+
parts.push(`[dbg ${String(metrics.apiCalls)}calls sent:${formatTokens(totalTokens)} sys:${formatTokens(systemTokens)} cont:${formatTokens(contentsTokens)} tools:${formatTokens(toolsTokens)}]`);
|
|
3320
3336
|
}
|
|
3321
|
-
}
|
|
3322
|
-
if (metrics.toolCalls > 0) {
|
|
3323
|
-
parts.push(`${String(metrics.toolCalls)} tool${metrics.toolCalls > 1 ? 's' : ''}`);
|
|
3324
|
-
}
|
|
3325
|
-
// DEBUG: Show payload debug info (token estimates sent to provider)
|
|
3326
|
-
if (metrics.debugPayload) {
|
|
3327
|
-
const { systemTokens, contentsTokens, toolsTokens } = metrics.debugPayload;
|
|
3328
|
-
const totalTokens = systemTokens + contentsTokens + toolsTokens;
|
|
3329
|
-
// Format: [dbg 2calls sent:31k sys:10k cont:8k tools:13k]
|
|
3330
|
-
parts.push(`[dbg ${String(metrics.apiCalls)}calls sent:${formatTokens(totalTokens)} sys:${formatTokens(systemTokens)} cont:${formatTokens(contentsTokens)} tools:${formatTokens(toolsTokens)}]`);
|
|
3331
3337
|
}
|
|
3332
3338
|
// Print as muted info line
|
|
3333
3339
|
this.ui.print({ type: 'turn-summary', parts });
|