Versions in this module Expand all Collapse all v0 v0.1.2 Jul 4, 2026 v0.1.1 Jun 25, 2026 Changes in this version + func DefaultPath() (string, error) + type Aggregate struct + AvgSavingsPct float64 + EventCount int + PeriodEnd time.Time + PeriodStart time.Time + TotalBytesSaved int + type Event struct + Command string + CompressedBytes int + CompressedTokens int + ID int64 + Mode string + Model string + OriginalBytes int + OriginalTokens int + SavingsPct float64 + Tier string + Timestamp time.Time + type Tracker struct + func New(ctx context.Context) (*Tracker, error) + func NewAt(ctx context.Context, path string) (*Tracker, error) + func (t *Tracker) Aggregate(ctx context.Context, days int) (Aggregate, error) + func (t *Tracker) Close() error + func (t *Tracker) Prune(ctx context.Context) (int64, error) + func (t *Tracker) Recent(ctx context.Context, n int) ([]Event, error) + func (t *Tracker) Record(ctx context.Context, ev Event) error + func (t *Tracker) WithRetention(days int) *Tracker