MCPcopy Create free account
hub / github.com/atomicdotdev/atomic / lift

Function lift

atomic-cli/src/commands/memory/bridge.rs:112–116  ·  view source on GitHub ↗

Lift the given inputs into a canonical `MemoryNode`, mapping a lift failure (missing `uid`, missing `memoryKind`, …) to a clean argument error.

(inputs: &MemLiftInputs)

Source from the content-addressed store, hash-verified

110/// Lift the given inputs into a canonical `MemoryNode`, mapping a lift failure
111/// (missing `uid`, missing `memoryKind`, …) to a clean argument error.
112pub fn lift(inputs: &MemLiftInputs) -> CliResult<MemoryNode> {
113 lift_memory(&inputs.frontmatter, &inputs.body).map_err(|e| CliError::InvalidArgument {
114 message: format!("could not lift memory: {e}"),
115 })
116}
117
118/// Sanitize a memory id for use as a directory name in the sidecar/vault path.
119/// Keeps ASCII alphanumerics, `-` and `_`; everything else becomes `_`.

Callers 5

runMethod · 0.70
runMethod · 0.70
runMethod · 0.70
kind_status_aboutFunction · 0.70

Calls 1

lift_memoryFunction · 0.85

Tested by 2

runMethod · 0.56