Attach Source to Relations

We add information about sources to the graph but have found these annotations work best when we step outside of the model for the reality we are observing.

We name each source and create a node that explains the source with a text description, an extraction date, and links to details about the source including the scripts we use to extract and transform the data that will appear elsewhere in our model.

We attach the source name to every relationship we add to our graph so if that information is judged suspect, we can retrieve details about its source. We thus use names that can be looked up later to establish a relation between every relationship and its source.

Queries often return the source for important relationships.

match (a) -[r]-> (b) return a.name as from, b.name as to, r.source as source

The source column of the resulting report will link to queries with a {source} parameter.

match (e:EXPLAIN {name: {source}}) return e.date as date, e.description as description, e.links as links

We've tried attaching source describing nodes to the other nodes within our model but have found their presence to complicate queries and to be less likely to answer the questions we have when queries return suspicious information.