Step-by-step guide to installing and uninstalling packages

Package management requires write access to the dataspace's settings document, which in practice means the owner of the dataspace.

Packages were introduced in LinkedDataHub 5.2. Since 5.10 they are installed declaratively: a dataspace imports a package with a single ldh:import triple in its settings. The dedicated install/uninstall endpoints, and the package Actions menu that drove them, have been removed.

Install a package

Installing a package adds new functionality to your dataspace by importing its ontology and stylesheet. Packages are published under https://packages.linkeddatahub.com/, with their sources in the packages/ directory of the LinkedDataHub-Apps repository.

Follow these steps to install a package through the web interface:

  1. Open the end-user dataspace of your dataspace and make sure you are logged in
  2. Click the settings dropdown button in the right section of the navigation bar
  3. Select Dataspace from the dropdown menu to open the Dataspace settings modal
  4. Scroll down to the Packages section, which lists the available packages with their descriptions
  5. Tick the Installed checkbox of the package you want to install
  6. Click Save

The page reloads with the package applied. The checkboxes are inputs of the settings form, so several packages can be installed and uninstalled in a single Save.

Uninstall a package

Uninstalling a package removes its ontology and stylesheet from your dataspace. Data you created using the package vocabulary remains but may not display or function correctly without the package.

Follow these steps to uninstall a package through the web interface:

  1. Open the Dataspace settings modal as described above
  2. Find the package in the Packages section
  3. Untick its Installed checkbox
  4. Click Save

Verify the installation

Installing or uninstalling a package takes effect on the next request — the package ontology joins the dataspace's imports closure and its stylesheet is composed into the dataspace stylesheet. No restart is needed.

After installing a package, verify that it was applied:

  1. Reopen the Dataspace settings modal and check that the package's Installed checkbox is ticked
  2. Check that the ldh:import declaration was stored by fetching the settings document:
    ldh get \
      --accept text/turtle \
      "https://localhost:4443/settings"

    The output contains an ldh:import triple with the package URI as its object.

  3. Check that the package ontology joined the imports closure by querying the ns endpoint — for the taxonomy editor package, the skos:Concept constructor becomes visible there:
    curl -k -G \
      -E ssl/owner/cert.pem:"$owner_cert_password" \
      -H "Accept: application/sparql-results+xml" \
      "https://localhost:4443/ns" \
      --data-urlencode 'query=ASK { <http://www.w3.org/2004/02/skos/core#Concept> <http://spinrdf.org/spin#constructor> ?constructor }'

    SPARQL queries fall outside the ldh command set, so this one uses curl with the PEM certificate.

  4. In the end-user dataspace, check that package-specific classes are offered by the Create dropdown
  5. If the package includes a stylesheet, verify that its custom UI elements are rendering

Edit the package ontology

On the first request after the import, the package ontology is copied into a document of your dataspace's admin dataspace, under its ontologies/ container and named after the package path — for the taxonomy editor, https://admin.localhost:4443/ontologies/editor-taxonomy/. That document is the package ontology as far as your dataspace is concerned: its constructors, constraints and views are edited there the same way as those of your own namespace ontology, and a change takes effect after the ontology cache is cleared.

The copy is taken once. A newer version of the package does not reach a dataspace that already imported it; to pick it up, delete the ontologies/ document, clear the ontology cache, and let the next request materialize the package again — edits made to the document are lost with it.

ldh delete "https://admin.localhost:4443/ontologies/editor-taxonomy/"
ldh admin clear ontology

Customize package behavior

Packages may include custom XSLT stylesheets that affect how data is displayed. You can further customize the behavior by:

See the Change layout guide for detailed instructions on stylesheet customization.

Troubleshooting

Installation fails

If the Save or the ldh patch is rejected:

  • Verify you are logged in with an agent that has write access to the dataspace's settings
  • Verify the package URI is correct and dereferenceable, and that its metadata declares lds:ontology and ac:stylesheet
  • Review the error message — a rejected settings update reports the constraint violation that caused it

Package functionality not visible

If installed package features are not visible:

  • Reload the page — the stylesheet is composed on the next request, but the browser may still hold the previous one
  • Clear the browser cache if stylesheets are not updating
  • Verify the package ontology is in the imports closure by querying the ns endpoint as shown above
  • Check that you have appropriate permissions to view package resources

Read more about how packages work.