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

Function lift

atomic-repository/src/intent_bridge.rs:161–165  ·  view source on GitHub ↗

Lift the given inputs into a canonical node, mapping a lift failure (unknown directive, missing `id`, malformed `:::ref`, …) to a clean argument error so the CLI reports it gracefully instead of surfacing an internal error.

(inputs: &LiftInputs)

Source from the content-addressed store, hash-verified

159/// directive, missing `id`, malformed `:::ref`, …) to a clean argument error so
160/// the CLI reports it gracefully instead of surfacing an internal error.
161pub fn lift(inputs: &LiftInputs) -> BridgeResult<CanonicalNode> {
162 lift_intent(&inputs.frontmatter, &inputs.body).map_err(|e| RepositoryError::InvalidOperation {
163 message: format!("could not lift intent: {e}"),
164 })
165}
166
167/// Sanitize an intent id/key for use as a directory name in the sidecar/vault
168/// path. Keeps ASCII alphanumerics, `-` and `_`; everything else becomes `_`.

Callers 15

context_from_inputsFunction · 0.70
prepareFunction · 0.70
load_intent_nodeFunction · 0.50
open_review_intentMethod · 0.50
review_intent_subjectMethod · 0.50
check_review_subjectMethod · 0.50
approve_review_intentMethod · 0.50
verifyFunction · 0.50
read_intentFunction · 0.50
sign_intentFunction · 0.50

Calls 1

lift_intentFunction · 0.85