Simon and I were referring to the existing extension-to-content-type mappings in mime.js, but I guess you're talking about web translation, where those aren't used, and for that a HEAD request is done if a content type isn't specified. I'm not up on the specifics of this code, but can we make this automatic based on the extension and just let translators override the defaults if necessary?

It's also annoying that HEAD requests are necessary at all, given that we're downloading the file (and therefore having either the same or more info on the content type) later anyway. We do this because we have two different methods for downloading—saveURI() for files and processDocuments() for HTML snapshots—but maybe there's a different way to do this? Something like always doing saveURI to the temporary directory first when a native type isn't specified, and then only doing processDocuments if sniffing the file reveals that it's a native type (and even that is only necessary for non-HTML types if we care about the more descriptive file name that having, say, an image in a document provides). Does processDocuments pull from the cache?