Formica is an SDK and a collection of tools for the data in the Library of Identification Resources.
Install globally:
npm install --global @larsgw/formica
Run locally:
npx --package @larsgw/formica -- ...
loir-validate-catalog [./catalog.csv ./authors.csv ./places.csv ./publishers.csv]: Validate the CSV files containing metadata (schema).loir-validate-resources [./B1234.txt]: Validate the.txtfiles containing information on the taxonomic scope of keys (documentation).loir-validate-integrity .: Check if all values are mapped as expected.loir-resources-process [./resources]: Interactive tool to convert the aforementioned.txtfiles to Darwin Core archives (documentation), and link the taxa to GBIF and Catalogue of Life identifiers.- Use
-sor--sourceto specify which files should be processed:unprocessed(default) for.txtfiles without corresponding Darwin Core files;modifiedif in a Git repo to update existing Darwin Core files while keeping the identifiers stable (in most cases);allfor all.txtfiles; ordwcfor only update identifier mappings. - Use
-uor--update-mappingsto specify which mappings to update:colorgbif. This argument can be repeated. By default, both COL and GBIF are updated. - Use
-kor--keep-mappingsto not update any mappings. Cannot be used in conjunction with-u. - Use
--mapping-apito use eithergnverifier(default) orclb, the ChecklistBank API, to update the mappings.
- Use
loir-resources-index [./resources]: Create indices of the Darwin Core archives.loir-resources-check-diff [./resources/dwc]: Determine which columns changed.
const Formica = require('@larsgw/formica')
// Load catalog data
const catalog = Formica.catalog.loadData(`...`, 'catalog')