Modularizing the meTypeset typesetter for the user interface phase

Originally published on eve.gd on 24 February 2014, last updated 6 September 2026.

Read this post on the web (with images, PDF and citation details)

Modularizing the Project

Today brings with it some notable changes to my scholarly article XML (NLM/JATS) typesetter (meTypeset). First off, the project is now nicely handling user supplied captions to figures, so long as they are in the format “Figure 1: a figure caption”.

meTypeset
handling user supplied captions

The second, more important change, that I've implemented, however, is to begin to modularize the project and to add individual command line hooks for different functions. So it's now possible to run specific functions. This will allow us to begin to build a user interface on top of the software.

The envisaged process at the moment is:

1. web service calls meTypeset on document

2. user is presented with WYSIWYG editor/step-by-step walkthrough to fix aspects

The way in which the step

The reference linker

A good example of this is the new options available via the reference linker. The reference linker is the portion of meTypeset that scans through documents looking for parenthetical references (Eve 2014 etc.) and then tries to link such items to valid ref-list/ref entries.

We have a moderately good success rate on such aspects. If it's done properly, with semicolons between bracketed entries and there is a single ref-list/ref entry that matches all the space separated and special-character normalized components of the reference, then we can link it no problem.

If, however, there are entries we can't parse, we need a user interface to handle this. While this will be web-based eventually, I today added an –interactive flag to the typesetter that will allow a command line input aspect, like this:

Figure 1: meTypeset running in interactive mode

This interface, which is based on the excellent beets music tagger, will be of great personal use to me when I typeset articles for Orbit (and for my hoped-for move to lens viewer at some point). Basically, here the user can select a specific option (Skip, Delete (remove the stub xref element), Enter search (>search the reference list for the correct entry), enter Link id (give an absolute element ID attribute to function as the rid attribute), or Abort the entire process).

beets music tagger
Orbit
lens viewer

This is just a start, but if we can develop a slick UI for the web on top of this, we will be solving a substantial problem in the currently commercial toolchain.

Cite this article

Please include the DOI in your citation: http://dx.doi.org/10.6084/m9.figshare.942425

You can view this post's XML with lens.

http://dx.doi.org/10.6084/m9.figshare.942425
view this post's XML with lens

References

This reference list has been generated, in many cases, through an automated process and may therefore contain errors or incomplete metadata. It is provided purely as assistance for finding the items mentioned within this post.

1. Eve, Martin Paul, ‘Modularizing the meTypeset typesetter for the user interface phase’, figshare, figshare, 24 February 2014 <https://doi.org/10.6084/m9.figshare.942425>

2. ‘GitHub - beetbox/beets: music library manager and MusicBrainz tagger’, GitHub <https://github.com/sampsyo/beets/>

3. ‘GitHub - elifesciences/lens: A novel way of viewing eLife articles.’, GitHub <https://github.com/elifesciences/lens>

4. ‘GitHub - MartinPaulEve/meTypeset at dev’, GitHub <https://github.com/MartinPaulEve/meTypeset/tree/dev>

5. ‘Link figure references in-text to graphic objects · MartinPaulEve/meTypeset@5662b3a’, GitHub <https://github.com/MartinPaulEve/meTypeset/commit/5662b3aeda62b9ee7a8bf009ce7b5cc77ed95fa6>

6. Orbit Pynchon journal website <https://www.pynchon.net/>

https://doi.org/10.6084/m9.figshare.942425
https://github.com/sampsyo/beets/
https://github.com/elifesciences/lens
https://github.com/MartinPaulEve/meTypeset/tree/dev
https://github.com/MartinPaulEve/meTypeset/commit/5662b3aeda62b9ee7a8bf009ce7b5cc77ed95fa6
https://www.pynchon.net/