A hash of the source lift inputs, recorded so a later edit to the memory can be detected as making the attestation stale. Standalone digest of (frontmatter + body); NOT the vault's `content_hash`. Copied verbatim from `intent/bridge.rs::source_content_hash`.
(inputs: &MemLiftInputs)
| 163 | /// (frontmatter + body); NOT the vault's `content_hash`. Copied verbatim from |
| 164 | /// `intent/bridge.rs::source_content_hash`. |
| 165 | pub fn source_content_hash(inputs: &MemLiftInputs) -> String { |
| 166 | let fm = serde_json::to_string(&inputs.frontmatter).unwrap_or_default(); |
| 167 | let mut hasher = blake3::Hasher::new(); |
| 168 | hasher.update(fm.as_bytes()); |
| 169 | hasher.update(b"\0"); |
| 170 | hasher.update(inputs.body.as_bytes()); |
| 171 | format!("blake3:{}", hasher.finalize().to_hex()) |
| 172 | } |
| 173 | |
| 174 | /// The state of a memory's attestation relative to the current source. |
| 175 | pub enum Attestation { |