Skip to main content

What is a node set

A node set is a tag you attach to data when you add it. cognify passes the tag on to the DataPoints it builds from that data, so searches can be limited to it.

How node sets work in Rust

A node set is a tag attached to ingested data and the DataPoints derived from it, used to categorize and later scope the knowledge base. It is partially realized in Rust today:
  • Tagging at ingest — add accepts a node_set, stored on Data.node_set and under external_metadata["node_set"], where cognify reads it and propagates it to derived DataPoints as source_node_set. Earlier versions wrote only the column, so data added with a node set was never tagged and node_name searches missed it; cognify now falls back to the column for those rows. Adding the same content again with a node set replaces its stored tags (without one, they are kept). Every name must be non-empty, and an item’s own external_metadata["node_set"] must be a list of names or null; otherwise the whole add fails with IngestionError::InvalidNodeSet before anything is stored. The pipeline executor can attach node_set provenance to task outputs (Tagged / TaggedMeta in cognee-core).
  • Scoping — a graph subset can be selected by node type and node name (the graph trait’s get_nodeset_subgraph, used by search’s node-name filter). The internal persist_sessions step tags cached session data with a fixed node set. Memify’s --node-type / --node-name scoping went away with memify.
Note: this is type/name-based subgraph filtering rather than a fully general named-node-set query surface; treat node sets as a tagging-and-scoping primitive, not a finished feature.

Recall

Scope a recall by node name

Add

Tag data at ingest

DataPoints

Where the tag is stored