Edges

An Edge is a directed relationship between two nodes, stored in the node_edges table. Edges are what turn a pile of individual nodes into an actual graph a reader can navigate. "Prerequisite" isn't a separate concept from edges — it's the name for one family of edge type; there are three in total, and they don't all mean the same thing.

The three edge types

  • def_dependency — a precise, canonical prerequisite: the minimal knowledge required to understand every term used in this node's own definition. If a proof or definition literally cites another concept, that's a def_dependency, not a suggestion.
  • prep_hint — a flexible, heuristic prerequisite: helpful background that isn't strictly required, weighted by how useful it is. Use this for "you'll follow this more easily if you already know X" rather than "you cannot understand this without X."
  • context_variantnot a prerequisite at all. It connects two nodes that represent the same underlying concept presented in different contexts (see Nodes for the line-bundle example). It's how a reader looking at one presentation of a concept can find the other — there's no dependency direction implied.

The first two — def_dependency and prep_hint — are collectively the prerequisite edges; the distinction between them matters for how the graph is used downstream. def_dependency edges are treated as hard requirements when computing what a reader needs to know before a node. prep_hint edges are suggestions, not blockers, and (once weighting is fully wired up) are ranked by how strongly the community has found them useful.

When you're authoring

Today, def_dependency and prep_hint are the two edge types you can set directly in a node's frontmatter, as separate lists of target node slugs. context_variant edges exist in the schema but aren't yet exposed through the authoring pipeline.

When you're deciding what to link as a prerequisite, ask: "if a reader hasn't seen this yet, can they actually follow the definition I just wrote?" If the answer is no, it's a def_dependency. If it's "they can follow it, but it'll click faster if they already know this," it's a prep_hint.

Not the same as facet attachments

Facet-to-node attachments (which facet belongs to which node) are relationships too, but they're a separate mechanism — different tables, not part of the node_edges/EdgeType system described here. See Facets for those.

PreviousNext