pub struct ParsedRelationRecovery {
pub kind: String,
pub source_id: EntityId,
pub target_id: EntityId,
pub rel_type: String,
}Expand description
Abstract recovery action attached to a PARSED_RELATION_INVALID
warning when the source mem is writable. The shape is tool-
agnostic: it names what to do, not which tool to call. A
consumer (agent, bulk-fix orchestrator, app surface) maps kind
to the concrete call on whichever MCP / CLI / UniFFI path it
uses; the warning’s payload itself does not drift when the
mutation surface evolves.
kind is the discriminator. Additive — new variants may land as
the recovery taxonomy grows. Current values:
"remove_explicit_relation"— drop the relation from the source entity’s## Relationshipssection. Agents map this tomemstead_relate { from: source_id, to: target_id, type: rel_type, remove: true }. The CLI maps it to the equivalentmemstead relate --removeinvocation. The bulk-fix consumer readssource_id,target_id,rel_typestraight from the payload.
The mirrored source_id / target_id / rel_type fields are
redundant with the warning’s entity_id / target / rel_type
— duplication is intentional. A consumer that branches on
recovery and forwards the payload downstream does not need to
stitch the warning’s top-level fields back in.
Fields§
§kind: String§source_id: EntityId§target_id: EntityId§rel_type: StringImplementations§
Source§impl ParsedRelationRecovery
impl ParsedRelationRecovery
Sourcepub const KIND_REMOVE_EXPLICIT_RELATION: &'static str = "remove_explicit_relation"
pub const KIND_REMOVE_EXPLICIT_RELATION: &'static str = "remove_explicit_relation"
Stable discriminator for the “drop the relation from the source markdown” recovery — the only abstract action this warning emits today.
Sourcepub fn remove_explicit_relation(
source_id: EntityId,
target_id: EntityId,
rel_type: String,
) -> ParsedRelationRecovery
pub fn remove_explicit_relation( source_id: EntityId, target_id: EntityId, rel_type: String, ) -> ParsedRelationRecovery
Constructor for the standard remove_explicit_relation
recovery — the only shape produced by the parser today.
Emission sites use this so the discriminator string lives in
one place.
Trait Implementations§
Source§impl Clone for ParsedRelationRecovery
impl Clone for ParsedRelationRecovery
Source§fn clone(&self) -> ParsedRelationRecovery
fn clone(&self) -> ParsedRelationRecovery
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for ParsedRelationRecovery
impl Debug for ParsedRelationRecovery
impl Eq for ParsedRelationRecovery
Source§impl PartialEq for ParsedRelationRecovery
impl PartialEq for ParsedRelationRecovery
Source§impl Serialize for ParsedRelationRecovery
impl Serialize for ParsedRelationRecovery
Source§fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
impl StructuralPartialEq for ParsedRelationRecovery
Auto Trait Implementations§
impl Freeze for ParsedRelationRecovery
impl RefUnwindSafe for ParsedRelationRecovery
impl Send for ParsedRelationRecovery
impl Sync for ParsedRelationRecovery
impl Unpin for ParsedRelationRecovery
impl UnsafeUnpin for ParsedRelationRecovery
impl UnwindSafe for ParsedRelationRecovery
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
Source§fn into_any(self: Box<T>) -> Box<dyn Any>
fn into_any(self: Box<T>) -> Box<dyn Any>
Box<dyn Trait> (where Trait: Downcast) to Box<dyn Any>, which can then be
downcast into Box<dyn ConcreteType> where ConcreteType implements Trait.Source§fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
Rc<Trait> (where Trait: Downcast) to Rc<Any>, which can then be further
downcast into Rc<ConcreteType> where ConcreteType implements Trait.Source§fn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
&Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &Any’s vtable from &Trait’s.Source§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
&mut Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &mut Any’s vtable from &mut Trait’s.Source§impl<T> DowncastSend for T
impl<T> DowncastSend for T
Source§impl<T> DowncastSync for T
impl<T> DowncastSync for T
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
impl<T> Fruit for T
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more