embed-key 0.1.0

Deterministic cache key for an embedding request: hash text + mix in provider, model, and dimensionality. So a cache survives model upgrades without false hits. Zero deps.
Documentation
  • Coverage
  • 100%
    2 out of 2 items documented1 out of 2 items with examples
  • Size
  • Source code size: 21.09 kB This is the summed size of all the files inside the crates.io package for this release.
  • Documentation size: 256.11 kB This is the summed size of all files generated by rustdoc for all configured targets
  • Ø build duration
  • this release: 19s Average build duration of successful builds.
  • all releases: 19s Average build duration of successful builds in releases after 2024-10-23.
  • Links
  • Homepage
  • MukundaKatta/embed-key
    0 0 0
  • crates.io
  • Dependencies
  • Versions
  • Owners
  • MukundaKatta

embed-key

crates.io

Deterministic 64-char cache key for an embedding request.

use embed_key::key;
let k = key("openai", "text-embedding-3-large", 3072, "hello");

Survives model upgrades — change any of (provider, model, dim) and the key changes too. Zero deps. MIT or Apache-2.0.