const totals = {
    inputTokens: 0,
    outputTokens: 0,
    cacheHitTokens: 0,
    cacheMissTokens: 0,
};
export function recordUsageSnapshot(usage) {
    totals.inputTokens += usage.inputTokens ?? 0;
    totals.outputTokens += usage.outputTokens ?? 0;
    totals.cacheHitTokens += usage.cacheHitTokens ?? 0;
    totals.cacheMissTokens += usage.cacheMissTokens ?? 0;
    return getUsageTotals();
}
export function getUsageTotals() {
    return { ...totals };
}
export function resetUsageTotals() {
    totals.inputTokens = 0;
    totals.outputTokens = 0;
    totals.cacheHitTokens = 0;
    totals.cacheMissTokens = 0;
}
export function getTotalInputTokens() {
    return totals.inputTokens;
}
export function getTotalOutputTokens() {
    return totals.outputTokens;
}
