emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Richard Lawrence <richard.lawrence@berkeley.edu>
To: Matt Lundin <mdl@imapmail.org>
Cc: emacs-orgmode@gnu.org
Subject: Re: Citation processing via Zotero + zotxt
Date: Thu, 03 Dec 2015 09:56:15 -0800	[thread overview]
Message-ID: <87k2ovwh4w.fsf@berkeley.edu> (raw)
In-Reply-To: <87lh9bh7se.fsf@fastmail.fm>

Hi Matt and all,

Matt Lundin <mdl@imapmail.org> writes:

> But for bibtex users, wouldn't there presumably have to be another
> zotero plugin that would allow for live, automated importing of bibtex
> into zotero? (If anyone knows whether such a plugin exists, please do
> let me know.)

Well, my hope is that this could be added to zotxt without much effort,
so we could still just depend on Zotero and zotxt.  The translation
capability already exists in Zotero; it's just a matter of exposing it
as an API, and I imagine that Erik would happily accept a patch to zotxt
that does so.

> A thought experiment... Do we need a fork of pandoc-citeproc?

(The name "org-citeproc" might be a bit misleading: it's not a fork of
pandoc-citeproc, but a small wrapper script that takes care of
marshalling data into and out of Pandoc, in a format that's easy to
generate and read from Emacs lisp.  But because it's written in Haskell,
building it still requires a full Haskell build chain, and distributing
it is non-trivial.)

> Or could we rather write an emacs-lisp wrapper that would feed
> citation data and a bibliography to pandoc and receive a string
> containing citations formatted in org syntax (one of pandoc's
> outputs). This could be done via an export filter, with all the
> necessary manipulation being done on the emacs/org side of things.

Yes, you're basically describing the approach that I eventually realized
org-citeproc should take: use the full capabilities of Pandoc to render
citations and bibliography in Org format, then re-parse these on the Org
side.  I did start to work on this, though I didn't finish and I'm not
sure if I pushed it to the public repo.

If we want to use pandoc-citeproc directly, instead of wrapping it with
something like org-citeproc, what we'd need to do is be able to
translate an Org document (or at least the citations within it) both to
and from pandoc-compatible JSON, since pandoc-citeproc reads and writes
in that format.  This can certainly be done in Emacs Lisp, and maybe it
would be worth doing, because it would mean that we'd gain a nice
serialization format for Org documents.

I am not opposed to this idea -- indeed, I kind of like it, which is why
I started work on org-citeproc in the first place.  Still, it would be a
non-trivial amount of work to develop this solution even to the point
that it can do what Zotero and zotxt can do right now.

> Javascript interpreters/engines are widely available for all platforms
> if we create a wrapper script around citeproc-js. Node itself is also
> easily available for most platforms. But we wouldn't need to set it up
> as a node server à la citeproc-node.

My concern here is with the wrapper script.  Yes, it's pretty easy to
install a javascript interpreter; but getting from there to the point
where you have a fully-working toolchain for processing citations from
Org mode is the problem.  What I think we should avoid is a process that
looks like:

1) Install node (or whatever interpreter)
2) Install citeproc-js and the wrapper script
3) Make sure the wrapper script is available as an executable that can
be called from Emacs
4) ...

Steps 2 and 3 are a bit much to ask people to do manually, and we don't
have the option of doing them through the system package manager.  They
could of course be automated by packaging up citeproc-js and a wrapper
script into a node package.  But again, that requires some work that no
one so far has volunteered to do; and anyway, it doesn't get away from
the worry about having to install packages/plugins from heterogeneous
sources.  (Also, we'd have to develop the wrapper script, and our own
way of translating items stored in BibTeX format into a format
compatible with citeproc-js.  This means duplicating efforts that have
already been put into both pandoc-citeproc and Zotero.)

It's a question of where to focus the limited resources we've got.  My
impression is that going with the combination of Zotero and zotxt will
represent the least amount of effort to get citations working on
non-LaTeX backends, for both Org developers and users.  I understand
that it won't be ideal for everyone, and there is time enough later on
to develop an alternative toolchain if that would better suit the needs
of people who don't want to depend on a GUI, etc.  I fully support that.
But until more people have time to work on this, it seems to me that
Zotero and zotxt represent the most practical path forward.
 
Best,
Richard

  reply	other threads:[~2015-12-03 17:56 UTC|newest]

Thread overview: 37+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-11-28 20:16 Citation processing via Zotero + zotxt Richard Lawrence
2015-11-30  8:12 ` Martin Yrjölä
2015-12-01  0:32   ` John Kitchin
2015-12-01  2:59     ` Richard Lawrence
2015-12-03  0:27       ` Matt Lundin
2015-12-03  1:41         ` Christian Wittern
2015-12-03 14:25           ` Matt Lundin
2015-12-03  4:32         ` Richard Lawrence
2015-12-03 15:27           ` Matt Lundin
2015-12-03 17:56             ` Richard Lawrence [this message]
2015-12-03 19:14               ` Thomas S. Dye
2015-12-03 22:05                 ` Rasmus
2015-12-03 20:45               ` Matt Lundin
2015-12-03 21:04                 ` Matt Lundin
2015-12-03 23:31         ` John Kitchin
2015-12-04  0:03           ` Rasmus
2015-12-04  1:49             ` John Kitchin
2015-12-05 21:18               ` Matt Lundin
2015-12-05 22:23                 ` John Kitchin
2015-12-04  2:06           ` Matt Lundin
2015-12-04 11:22             ` John Kitchin
2015-12-04 14:13               ` Matt Lundin
2015-12-05  1:23                 ` John Kitchin
2015-12-04  9:20           ` Eric S Fraga
2015-12-01  9:34     ` Ramon Diaz-Uriarte
2015-11-30 11:35 ` Eric S Fraga
2015-11-30 12:02   ` Ramon Diaz-Uriarte
     [not found] ` <CAN_Dec-JCmwQ2bc=U93rRaPMYyXOiN_PRbtyya9x396r3qqMrg@mail.gmail.com>
2015-12-01 12:12   ` Fwd: " Matt Price
2015-12-01 15:28     ` Eric S Fraga
2015-12-01 15:51       ` Richard Lawrence
2015-12-01 19:20         ` Matt Price
2015-12-01 21:34         ` Eric S Fraga
2015-12-01 21:51     ` Matt Lundin
2015-12-02 15:21       ` Richard Lawrence
2015-12-01 14:36 ` Rasmus
2015-12-01 19:37   ` Matt Price
2015-12-02 15:58   ` Richard Lawrence

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.orgmode.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87k2ovwh4w.fsf@berkeley.edu \
    --to=richard.lawrence@berkeley.edu \
    --cc=emacs-orgmode@gnu.org \
    --cc=mdl@imapmail.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).