A hash of the source lift inputs, recorded in the sidecar so a later edit to the intent can be detected as making the attestation stale. This is a standalone digest of (frontmatter + body); it is NOT the vault's `content_hash` and never feeds it. `attest` writes it; `validate`/`show`/ `verify` recompute it to decide whether a sidecar is still fresh.
(inputs: &LiftInputs)
| 177 | /// `content_hash` and never feeds it. `attest` writes it; `validate`/`show`/ |
| 178 | /// `verify` recompute it to decide whether a sidecar is still fresh. |
| 179 | pub fn source_content_hash(inputs: &LiftInputs) -> String { |
| 180 | let fm = serde_json::to_string(&inputs.frontmatter).unwrap_or_default(); |
| 181 | let mut hasher = blake3::Hasher::new(); |
| 182 | hasher.update(fm.as_bytes()); |
| 183 | hasher.update(b"\0"); |
| 184 | hasher.update(inputs.body.as_bytes()); |
| 185 | format!("blake3:{}", hasher.finalize().to_hex()) |
| 186 | } |
| 187 | |
| 188 | /// The state of an intent's attestation sidecar relative to the current source. |
| 189 | pub enum Attestation { |