Skip to content

Getting started

  • Python 3.10 or later
  • uv package manager

Clone the repository and install dependencies:

Terminal window
git clone https://github.com/dharc-org/changes-metadata-manager.git
cd changes-metadata-manager
uv sync

The tool expects two things to be in place before you run it:

  1. A knowledge graph in Turtle format at data/kg.ttl. This file is generated by morph-kgc-changes-metadata and contains all the RDF triples describing the digitized objects.

  2. A folder structure following the pattern Sala*/Folder/Stage/ on the local filesystem. See the digitization stages page for what each stage represents.

Once you have the knowledge graph and the folder structure, generate metadata and provenance for all objects:

Terminal window
uv run python -m changes_metadata_manager.folder_metadata_builder /path/to/root

Each stage folder will receive:

  • meta.ttl: RDF metadata extracted from the knowledge graph
  • prov.trig: provenance snapshots in TriG format
Terminal window
uv run pytest

With coverage reporting:

Terminal window
uv run pytest --cov=changes_metadata_manager --cov-report=term