Dictionaries¶
Presentation¶
- The use of dictionaries has no other purpose to facilitate the entry of metadata, entry which can be long and repetitive in generalist data warehouses (such as repository based on Dataverse).
- Dictionaries allow you to record multiple information necessary to define an entity, such as the names of people or even the funders. These information, once entered and saved in a file called a dictionary, can be subsequently associated with the corresponding entity.
- The dictionaries offered by default are: people (people), funders (grant), data producers (producer), as well as a vocabulary dictionary (vocabulary) allowing you to mix ontologies and thesauri from several sources.
- To add a new dictionary, simply create a directory under web/cvlist then putting the files corresponding to the dictionary inside. Dictionaries will be automatically found by browsing this directory.
- Dictionary files are made using a simple spreadsheet then exported in TSV format.
- Dictionaries are accessed through secure access limited to administrators allowing their editing. The login is by default 'admin'. You can add another account for consultation only using the following command:
sh ./run passwd <user>
The people dictionary¶
- Note : must not be changed in its format nor in its name.
-
Like any dictionary, there must be 3 files (see below). Please note that the names of these files must always contain the name of the dictionary, i.e. same as the directory.
-
The format of the file containing the dictionary data (people.txt) is defined by another file (people_format.txt).
- Thus, we know that the people dictionary must contain 5 columns (last name, first name, institution, ORCID number and email address) and that some fields are mandatory (last name, first name, institution) and others optional (ORCID number, email address).
- Each of the fields must respect a format specified by a regular expression in order to be accepted as valid.
- Optionally, you can connect an web API to each of the fields in order to make an entry by autocompletion from a remote register. Currently only ROR (Research Organization Registry) web API is possible but the mechanism is in place for new extensions.
- The third file, a very simple script written in JavaScript, defines the way to retrieve the list of names (here by containing the first and last name). Note that the name of the variable must always be identical to that of the dictionary.
var people = []; // Each item in the 'people' list consists of the first two columns (0,1) separated by a space get_dictionary_values('people', merge=[0,' ',1])
-
Below, an example is given when modifying a record. When you click on the Institute field which is connected to the ROR web API, the drop-down list of reseach organizations that can correspond in the register appears, if there are any.
-
Note: It is possible to edit dictionaries, by adding an entry for example, and at the same time be able to immediately find this new entry in the metadata entry in the Maggot tool. Indeed each dictionary is reloaded into memory as soon as the corresponding input box is clicked. See an illustration.
Other dictionaries¶
-
Funders : The dictionary of the funders allows you to define the funding agency, project ID and its corresponding URL.
-
Producers : The dictionary of the data producers allows you to define their Institute and project ID and their corresponding URL. Optionally, you can add the URL of the logo.
-
Vocabulary : Use this dictionary for mixing thesauri and ontologies in order to better target the entire controlled vocabulary of its field of application. Only the vocabulary is mandatory, the URL linked to an ontology or a thesaurus is optional. See Vocabulary section to learn the extent of the possibilities concerning vocabulary in Maggot.