From mboxrd@z Thu Jan 1 00:00:00 1970 From: John Kitchin Subject: Re: More questions about CSL and org-mode Date: Mon, 07 Dec 2015 06:56:56 -0500 Message-ID: References: <87r3izupne.fsf@berkeley.edu> <87oae3uonn.fsf@berkeley.edu> Mime-Version: 1.0 Content-Type: text/plain Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:45814) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1a5uPf-00023U-IV for emacs-orgmode@gnu.org; Mon, 07 Dec 2015 06:57:04 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1a5uPa-0001g1-W9 for emacs-orgmode@gnu.org; Mon, 07 Dec 2015 06:57:03 -0500 Received: from mail-qk0-x234.google.com ([2607:f8b0:400d:c09::234]:36158) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1a5uPa-0001fx-RA for emacs-orgmode@gnu.org; Mon, 07 Dec 2015 06:56:58 -0500 Received: by qkcb135 with SMTP id b135so21493603qkc.3 for ; Mon, 07 Dec 2015 03:56:58 -0800 (PST) In-reply-to: <87oae3uonn.fsf@berkeley.edu> List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: Richard Lawrence Cc: Org Mode Thanks. Its an interesting jam. You want to have multiple outputs as a possibility, but there isn't a robust markup that readily works across all backends. What about this. For now consider a bibliography database with org-formatting in the entries, e.g. subscripts, superscripts, etc... (but not like putting italics on titles or anything related to bibliography formatting). So I can have a title like "The role of H_{2}O in /d/-orbital splitting of \alpha particles" in an entry. I assume it would also be ok to have utf-8 characters in it. Equations are still problematic, as we use LaTeX syntax for those. On export the in-text citations are transformed to unique text blobs, e.g. uuids, and the document exported. The only important features of these blobs is that they do not get changed on export, and they are unique because we replace them later. The strings in the bibliography entry are "exported" to convert the org-markup to the output format. The in-text citations, expanded bibliography and style are sent to the citation processor, which outputs replacements and a formatted bibliography in the desired output format. Finally, you replace each uuid with the appropriate replacement, and insert the bibliography where it belongs. That should be the final document. If you did this with a bibtex file, it would probably break its use in LaTeX without some clever transformation of the bibtex file to a new file that was LaTeX formatted, and an on the fly change to the org buffer to use this new file. But, since the point of this is for non-LaTeX export, I guess this is ok. I bet you could even expand the bibtex format to include journal abbreviations, and directly use the fields that CSL uses (although I strongly dislike "container-title" for the journal name!) The downside is the processor now needs to output different formats, but presumably there are a few standard ones that are a one-time investment like html. Richard Lawrence writes: > Richard Lawrence writes: > >>> IIUC, the current aim is to get a citeproc that will do the following on >>> export: >>> 1. replace in-text citation syntax with org-formatted replacements >>> 2. Insert an org-formatted bibliography somewhere in the document >>> 3. proceed with org-to-something export, with built-in >>> exporters. >> >> That's basically my understanding too. There is one snag with the >> "org-formatted replacement" plan, though, which I saw in a Zotero dev >> discussion yesterday. > > Here's the reference for that discussion, by the way: > > https://groups.google.com/d/msg/zotero-dev/Bz_IenruxX4/24QWuyEIp_IJ > > Best, > Richard > > P.S. John, thanks for your continued research on this. I see that our > procrastination habits are on the same schedule. :) -- Professor John Kitchin Doherty Hall A207F Department of Chemical Engineering Carnegie Mellon University Pittsburgh, PA 15213 412-268-7803 @johnkitchin http://kitchingroup.cheme.cmu.edu