Imports Closure Graphs

TopBraid supports special graphs stored in files ending with .icg. These so-called Imports Closure Graphs represent an RDF graph consisting of the complete imports closure of a list of other graphs. In contrast to normal graphs, these imports are "flattened", i.e. TopBraid does not create a complex union graph for them but instead loads them all into a single in-memory graph that includes all triples from all imported graphs.

Imports Closure Graphs can be useful when there is a collection of imported graphs that are used together and only in read-only mode. Due to the reduced overhead of the union graph architecture, these ICGs are usually significantly faster to query.

In order to create a new Imports Closure Graph, create a normal graph and use the Imports View to collect all sub-graphs that shall be flattened into the .icg file. Then right-click on a target folder or project and select Export > TopBraid Composer > Import Closure Graphs. In the wizard's page, enter a file name (without the suffix) and a valid base URI for the new closure graph. The latter will be the URI that can then be imported into other graphs.

Note that the .icg graphs only store references to the actual sub-graphs, not their triples. This means that when the sub-graphs change, the changed triples will be visible to the .icg graph on the next time when it is reloaded.