User:Daniel Mietchen/Talks/JATS-Con 2014/Media types


 * Media types are used by the OAMI to determine how to process the media files.
 * Wikimedia Commons only accepts audio or video files encoded in open formats

Problems with JATS

 * Two attributes: mimetype and mime-subtype. But, sometimes both parts are put into the former, and sometimes they are split.
 * In an example from JATS they are combined as mimetype="application/pdf")
 * The PMC Tagging Guidelines, on the other hand, specify that " also requires @mime-type, and @mime-subtype."


 * Where should the media type go? On  or on the child  or ?

Tagging and delivery problems

 * Mismatches between declared type and actual. (See graphic)  Often there were differences among all three: publisher XML, PMC XML, and actual Media type.


 * Mismatches between filename extension and media type (see discussion). For example, movie files that end in ".doc".


 * Media types missing altogether.

Recent efforts at PMC

 * Until October 2013, PMC was writing @mimetype and @mime-subtype attributes to newly received XML files based on actual filename extensions. Realizing that filename extensions are not reliable, they have stopped.


 * Around the same time, PMC implemented a new feature in its renderer, using libmagic, to accurately determine media type at render time, and use it to set the HTTP "Content-type" header.


 * Also now supports HEAD requests (facilitating easier discovery of media types in bulk)


 * But they will not retroactively fix the values in any source XML.

Standardization efforts

 * NISO/NFAIS Supplemental Journal Article Materials Working Group (remember the show of hands in Bruce Rosenblum's talk)