Expand description
Stable frame identity and the canonical composition order
(docs/context-reuse.md §1).
A FrameId is the triple (provider id, frame id, content digest) that
names a frame’s exact bytes. It is the spine the context-reuse guarantees
share: deterministic composition orders frames by it (§1), a usage report
references served frames by it (§2), and a context/verify request carries
it so a provider can answer “is this still valid?” without any frame body
travelling (§4).
The content_digest is provider-declared and opaque: a provider picks
the algorithm (the reference frames use sha256:<hex>, matching the
provenance digests) and the protocol never re-derives it. That is
deliberate — a host that computed the digest from its own serialization
would force every out-of-Rust provider to byte-exactly reproduce that
serialization just to answer a verify request, which is precisely the
lock-in the protocol exists to avoid. A frame that declares no digest
(content_digest: None) is simply not verifiable, and a host falls back
to re-querying it (§4).
Structs§
- FrameId
- The stable identity of one frame’s exact content bytes:
(provider id, frame id, content digest).
Functions§
- canonical_
order - Sort a set of frame identities into the protocol’s canonical composition
order (
docs/context-reuse.md§1). A thin, explicit wrapper over the derivedOrdso call sites read as intent, not a bare.sort().