Data Integrations > Make this a Subgraph

This item from the Data Integrations Menu can be used to create a Pull Script that can later be used to update the content of the current asset collection based on an ADS script. In particular this feature can be used to define subgraphs of other asset collections. For example, you can use it to define a Taxonomy as a sub-hierarchy of another (larger) taxonomy, when you only need to use certain terms.

The dialog mainly asks for - the URI of a source graph that contains the “full” graph. For example, if you have the Geography Taxonomy as the source graph, it would be urn:x-evn-master:geo. - an ADS script that declares a new variable called assets and makes it an array of NamedNode instances for all the nodes that shall be included into the subgraph.

Here is an example script that returns the “Events” subtree of the RxNORM taxonomy:

let assets = skos.everyConceptScheme().concat(graph.select(`
    SELECT ?concept
    WHERE {
        ?concept skos:broader* <http://purl.bioontology.org/ontology/STY/T051> .
    }
`).bindings.map(b => b.concept));

Once such a data integration has been established, users with editing permissions can:

  • use the Pull Changes Button to replace the content of the current asset collection or workflow with the content returned by the script.

Note

Before your first attempt you may want to reload the browser page to see the new action in the Pull dialog.

Further Reading on Data Integrations Menu

Further Reading on Data Integration Buttons

Further Reading on TopBraid