CacheKit Docs

High-performance cache policies and supporting data structures.

View the Project on GitHub OxidizeLabs/cachekit

GreedyDual-Size / GreedyDual-Size-Frequency (GDS/GDSF)

Goal

Make eviction consider object size and/or miss cost (common in web/CDN caches), not just request count.

Core Idea

Assign each entry a key H (priority). Evict the smallest H.

Common scoring shape (varies by variant):

Core Data Structures

Typical implementation:

Implementation choices:

When It Matters

Use when:

References