pub struct Pattern {
pub base: KnowledgeBase,
pub kind: Option<PatternKind>,
pub origin: Option<Origin>,
pub attachments: Vec<Attachment>,
}Expand description
A MUR pattern — the atomic unit of learned knowledge.
YAML files in ~/.mur/patterns/ are the source of truth.
LanceDB indexes are always rebuildable from these.
KnowledgeBase fields are flattened so existing YAML stays compatible.
Fields§
§base: KnowledgeBaseShared knowledge fields (flattened into YAML)
kind: Option<PatternKind>The kind of knowledge this pattern represents. None is treated as Technical for backward compatibility.
origin: Option<Origin>Provenance metadata — where and how this pattern was learned.
attachments: Vec<Attachment>Attached diagrams, images, etc.
Implementations§
Source§impl Pattern
impl Pattern
Sourcepub fn effective_kind(&self) -> PatternKind
pub fn effective_kind(&self) -> PatternKind
Get the effective kind, defaulting to Technical if not set.
Trait Implementations§
Source§impl Deref for Pattern
impl Deref for Pattern
Source§type Target = KnowledgeBase
type Target = KnowledgeBase
The resulting type after dereferencing.
Source§fn deref(&self) -> &KnowledgeBase
fn deref(&self) -> &KnowledgeBase
Dereferences the value.
Source§impl DerefMut for Pattern
impl DerefMut for Pattern
Source§fn deref_mut(&mut self) -> &mut KnowledgeBase
fn deref_mut(&mut self) -> &mut KnowledgeBase
Mutably dereferences the value.
Source§impl<'de> Deserialize<'de> for Pattern
impl<'de> Deserialize<'de> for Pattern
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for Pattern
impl RefUnwindSafe for Pattern
impl Send for Pattern
impl Sync for Pattern
impl Unpin for Pattern
impl UnsafeUnpin for Pattern
impl UnwindSafe for Pattern
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
Mutably borrows from an owned value. Read more