Expand description
Two-ref structural diff types.
Diff is the engine-level response shape for Engine::diff(ref_a, ref_b, config). Consumers (LLM replay skills, PR-review UIs,
pre-merge previews, snapshot comparisons, cross-mem reflection
tools) all consume this one struct rather than re-walking git trees
themselves.
Wire format is deterministic and stable so external tooling (memstead-mcp, memstead-cli, future Webhooks) can deserialise into the same types it serialises.
The rename-chain + ripple fields are motivated by the LLM-replay flow that consumes these diffs.
Structs§
- Diff
- Top-level diff response. Echoes the two refs the caller passed in (verbatim), reports the SHAs they resolved to, surfaces the configuration the operation used, and lists every per-entity entry.
- Diff
Config - Caller-supplied diff configuration. Defaults yield a useful diff without requiring callers to opt in to every feature.
- Incoming
Ripple - One entry in an entity’s incoming-wikilink ripple list. The
referrer entity is on either
ref_aorref_b(sidediscriminates); consumers building a “what would break” preview consult both sides.
Enums§
- Entity
Diff - Per-entity diff entry. Variants mirror the change kinds an
entity-level diff can produce;
InvalidEntityis the soft-failure path for entities that fail to parse on either side (consumers decide how to handle each case —memstead_diffdoes not refuse the whole call just because one entity is malformed).