Skip to content

Anystyle conversion

Dan Visel requested to merge anystyle-conversion into main

This is the Anystyle conversion. It consists of three parts:

  1. A Docker volume that runs the Anystyle converter. Anystyle is a Ruby app that can be run from the command line. This accepts plain text as a string; it returns Anystyle-flavored XML. The Docker volume has been redone in Coko Server; on Docker it's here: https://hub.docker.com/repository/docker/dbvisel/coko-anystyle and in Gitlab it's here: https://gitlab.coko.foundation/dbvisel/anystyle-service . That code needs to be reviewed, even though it's not part of the Kotahi Gitlab!
  2. A server component that sends a string of plain text to Anystyle, gets XML back, then converts the XML to Kotahi's JATS-flavored HTML.
  3. Additions to Wax that allow sending a selected string of text to the server, which sends it to Anystyle. On response, the text is replaced by the HTML that comes back from the server.

Part 1, the Docker volume, is why this is in draft; this is being redone to be based on Coko Server. Running it this way will require authentication. But this affects part 2 minimally and part 3 not at all.

There can be some strangeness in the results obtained from Anystyle. In my experience, it's only completely right about half the time. That said, if it's messing up entirely, a command-control-Z will undo what's happened; and if it's mislabeling things, the editor can use the Wax citation tools to do the same job manually.

Edited by Dan Visel

Merge request reports