pub struct PreparedInputCacheIdentity { /* private fields */ }Expand description
Cache identity coupling an ordered prepared-input description to caller-owned content.
PreparedInputIdentity deliberately excludes tensor payload bytes. Prompt caches need
both that stable description and a digest of the semantic content that produced the native
tensors, so equal shapes alone can never make two media requests cache-equivalent.
Implementations§
Source§impl PreparedInputCacheIdentity
impl PreparedInputCacheIdentity
Sourcepub fn new(
prepared: PreparedInputIdentity,
semantic_content_fingerprint: impl Into<String>,
) -> Result<Self, PreparedInputCacheIdentityError>
pub fn new( prepared: PreparedInputIdentity, semantic_content_fingerprint: impl Into<String>, ) -> Result<Self, PreparedInputCacheIdentityError>
Couples one prepared-input description to a nonempty semantic-content fingerprint.
Sourcepub const fn prepared(&self) -> &PreparedInputIdentity
pub const fn prepared(&self) -> &PreparedInputIdentity
Exact ordered payload-free prepared-input description.
Sourcepub fn semantic_content_fingerprint(&self) -> &str
pub fn semantic_content_fingerprint(&self) -> &str
Caller-owned digest identifying the semantic tensor payloads.
Sourcepub fn prefix_content_fingerprint(&self) -> &str
pub fn prefix_content_fingerprint(&self) -> &str
Canonical fingerprint stored in eredu_core::cache::PromptCacheDescriptor.
Sourcepub fn logical_metadata_bytes(&self) -> Option<u64>
pub fn logical_metadata_bytes(&self) -> Option<u64>
Logical host storage retained by a copied identity, including descriptions and both fingerprints. Allocator capacity/overhead is excluded.
Trait Implementations§
Source§impl Clone for PreparedInputCacheIdentity
impl Clone for PreparedInputCacheIdentity
Source§fn clone(&self) -> PreparedInputCacheIdentity
fn clone(&self) -> PreparedInputCacheIdentity
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more