Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion src/node.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1043,7 +1043,9 @@ async function main(): Promise<void> {
const extraTag = extra.length > 0 ? ` (${extra.join(' ')})` : '';
const tag = e.info?.compressed
? `compressed ${e.info.origChars}ch → ${e.info.imageCount}img/${e.info.imageBytes}B${extraTag}`
: (e.info?.reason ?? '');
: e.info?.reason
? `savings:skip(${e.info.reason})`
: '';
const cacheRead = e.usage?.cache_read_input_tokens ?? 0;
const inputTokens = e.usage?.input_tokens ?? 0;
const usageTag =
Expand Down
4 changes: 3 additions & 1 deletion src/worker.ts
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,9 @@ export default {
// shows up in `wrangler tail`).
const tag = e.info?.compressed
? `compressed ${e.info.origChars}ch → ${e.info.imageCount}img/${e.info.imageBytes}B`
: (e.info?.reason ?? '');
: e.info?.reason
? `savings:skip(${e.info.reason})`
: '';
const cacheRead = e.usage?.cache_read_input_tokens ?? 0;
console.log(`${e.method} ${e.path} → ${e.status} (${e.durationMs}ms) ${tag} cache_read=${cacheRead}`);

Expand Down