Skip to main content

external_ref_node_with

Function external_ref_node_with 

Source
pub fn external_ref_node_with(qualified: &str, provenance: Provenance) -> Node
Expand description

external_ref_node, with the placeholder’s provenance chosen by the caller.

The placeholder carries the provenance of the claim that the target exists: Provenance::Inferred for a confidence-scored match, Provenance::Authored for a [[links]] declaration someone wrote.

Both flavours share a key, so a repo that both declares and infers the same target has one placeholder — and since each layer upserts it, the node’s own provenance is whichever layer was applied last. Do not read it as the link’s provenance. The edges carry that, one per ref, and a consumer asking “is this link authored?” must look there:

"incoming": [
  { "provenance": "authored", "confidence": null },
  { "provenance": "inferred", "confidence": 0.9   }
]