Virtual Nodes and Relationships
This section includes:
We can filter some properties of nodes and relationships present in a subgraph using the apoc.graph.filterProperties
procedure,
or the analogous aggregation function.
For example, if we want to exclude embedding properties created with the
CALL apoc.ml.openai.embedding(["Test"], "<apiKey>", {}) yield embedding
with embedding
match (start:Start {id: 1}), (end:End {id: 2})
WITH start, end, embedding
CALL db.create.setNodeVectorProperty(start, "embeddingStart", embedding)
CALL db.create.setNodeVectorProperty(end, "embeddingEnd", embedding)
RETURN start, end
we would return virtual entities without those properties.
If we return the nodes to Neo4j Browser or Neo4j Bloom we would have the following situations, where we can se the log embedding properties :
But if we filter the embedding properties, then the situation would be as follows, easier to read: