pandoc
pandoc copied to clipboard
Add CRediT roles to JATS
Closes #10152
This PR adds support for annotating author roles using the Contribution Role Taxonomy (CRediT).
I'm motivated to add this to Pandoc since I want the Journal of Open Source Software (JOSS), which is built on top of Pandoc, to be able to create compliant JATS. We're already adding support for encoding this information in article metadata in parallel in https://github.com/openjournals/inara/pull/75.
On my first attempts to implement this, I tried to inject some clever logic inside the Haskell code to automatically look up the primary labels, but this had the two issues of being programatically complicated, and too rigid towards internationalization. Now, you can specify the roles in the metadata like this:
title: CRediT Test
author:
- name: Max Mustermann
roles:
- credit-id: software
credit-name: Software
degree: Lead
name: Programas
The tests (with narrative documentation) can be found in https://github.com/cthoyt/pandoc/blob/patch-1/test/command/10152.md. Run these tests specifically with cabal test --test-options="-p 10152.md"