cmem_client.models.vocabulary¤
Vocabulary models for Corporate Memory vocabulary catalog.
Provides Pydantic models for vocabulary catalog entries returned by the DataPlatform vocabularies API.
The catalog lists both the vocabularies a deployment has installed and those it offers
for installation; they are the items of client.vocabularies, keyed by their IRI.
The cache models describe something else: the classes and properties DataIntegration
extracted from the installed vocabularies, which is what drives autocompletion in the
user interface.
Classes:
- VocabCacheEntry – Cache data for one vocabulary, containing its classes and properties.
- VocabCacheItem – A single class or property in the vocabulary cache.
- VocabCacheItemInfo – Generic info for a vocabulary cache term.
- Vocabulary – A vocabulary catalog entry.
- VocabularyCache – Global vocabulary cache response from DataIntegration.
- VocabularyLabel – Label metadata for a vocabulary.
VocabCacheEntry¤
Bases: Model
Cache data for one vocabulary, containing its classes and properties.
Attributes:
- classes (
list[VocabCacheItem]) – Classes the vocabulary defines. - properties (
list[VocabCacheItem]) – Properties the vocabulary defines.
classes¤
model_config¤
properties¤
VocabCacheItem¤
Bases: Model
A single class or property in the vocabulary cache.
Attributes:
- generic_info (
VocabCacheItemInfo) – URI and label of the term.
generic_info¤
model_config¤
VocabCacheItemInfo¤
Bases: Model
Generic info for a vocabulary cache term.
Attributes:
- uri (
str) – URI of the class or property. - label (
str | None) – Human readable name of the term, if the vocabulary defines one.
label¤
model_config¤
uri¤
Vocabulary¤
Bases: Model, ReadRepositoryItem
A vocabulary catalog entry.
Attributes:
- iri (
str) – IRI of the vocabulary. This is the key of the repository. - installed (
bool) – Whether the vocabulary is installed in the deployment. - download_url (
str | None) – Where an uninstalled vocabulary can be fetched from, orNoneif the catalog offers no source for it. - vocabulary_label (
str | None) – Name of the vocabulary as given by the catalog. - label (
VocabularyLabel | None) – Label of the graph holding the vocabulary, once it is installed.
Functions:
- get_id – Get the IRI of the vocabulary.
download_url¤
get_id¤
Get the IRI of the vocabulary.
installed¤
iri¤
is_installable¤
Return True if the vocabulary can be installed from catalog.
label¤
model_config¤
vocabulary_label¤
VocabularyCache¤
Bases: Model
Global vocabulary cache response from DataIntegration.
Attributes:
- vocabularies (
list[VocabCacheEntry]) – Cache entry of each vocabulary DataIntegration knows.
model_config¤
vocabularies¤
VocabularyLabel¤
Bases: Model
Label metadata for a vocabulary.
Attributes: