Citations with org-ref, ox-bibtext, zotxt - use? Differences?

It seems that most people trying to integrate citations into org-roam notes are using org-ref. Is anyone using the “ox-***” family of packages for this? Is anyone using zotxt to integrate Emacs with Zotero directly? I would appreciate if anyone could help me understand whether these packages are just different approaches to the same functionality or whether they are actually doing fairly different things.

I know that org-ref can help create links from notes to sources in a reference database and can provide contextual information in the Emacs minibuffer when the cursor is on an org-mode link. Does it do other things that are important, such as for exporting documents to LaTex or .docx? How do ox-*** or zotxt do similar or different things? Thanks for any guidance here.

If you would like to use org-roam to build up your note taking system, then I think Zotero can be considered as just a place for converting and collecting the citation information. After a while, you could export all the citations in Zotero to bibtex form and sync with org-ref(not that much work).

When writing papers, org-ref should provide formal links format. If not, some other packages will, as most of them use the bibtex format.

Thanks for your response. Although Zotero can be used just to create the Bibtex file, I’m also
wondering how it can be used with zotxt to integrate with Emacs directly.

I don’t understand what this means. Org-mode can format links itself. Does “writing papers” mean just editing, or are you talking about exporting to a document format? I know the various packages overlap somewhat; I’m trying to understand how they are different so I can choose one and explain the choice to others.

I’ve never used zotxt, but my understanding is it would be at least a partial alternative to using helm-bibtex or ivy-bibtex; finding and inserting citations and such.

In the former, you’re connecting directly to zotero, and in the latter, you’re using bibtex or biblatex files for the data source.

I use the latter, and generate biblatex entries using zotero and better bibtex.

You could install zotxt and see what you think of the two options?

Note: on your first point here, I think if you did use zotxt, you’d lose that linking functionality.

The manual has info on the export options.

From what I understand, it has good latex output (where it relies on bibtex to do the actual formatting), and less on other formats.

Note, though:

  1. pandoc has support for org syntax, and full citation support, using the same CSL language as Zotero for citation styling; so you should be able to use that to process the org files to other output formats (docx, etc.)
  2. native citation support is coming to org “soon”, and part of that discussion includes the possibility to add citeproc.el, which would mean out-of-box support for CSL, and therefore full citation formatting for all org export formats

For me, the main problem with Zotero, Mendeley and similar software is that they do not use BibTeX as their native storage format. Consequently, there always pop up smaller and bigger problems such as citation key generation, field mapping and limited possibility to create custom fields. My current approach is actually the opposite: managing references in a program that works with BibTeX directly and then export a subset of citations into Zotero or Mendeley whenever I need their word-processing connectors. JabRef seems to be capable of most things Zotero can do. Bibdesk is a good choice for Mac users.

The main features of zotero are one-click metadata extraction, notes and such, and integration with word processors.

With Better BibTeX, you also get good bibtex and biblatex support.

I edit my biblatex files directly, in emacs.

I used Zotero for quite a while - maybe 5 or 6 years - as my main literature database. There were several solutions for connecting Zotero to Emacs, like some custom Zotero links in Org-mode and another thing, perhaps zotxt.

Unfortunately, I coudn’t make it along my way with them. I heavily relied on Better BibLaTeX extension for Zotero and it could even insert Org-ref cite links into Emacs, as far as I remember, I had to tinker with javascript to have a customize exporter which would support my BibTeX keys. But after all, the biggest challenge for me was keeping two databases - Zotero and my master .bib in sync. All these exports, they really - I mean really, without a hassle, work one way. Maybe the things are different now.

So I eventually migrated to a single .bib database, first managed with JabRef, now with Bibdesk. Both programs are able to retrieve metadata in one click through DOI, so I’m fine with that. Whenever I need to insert references into Microsoft Word, I export those references to a separate dedicated .bib file and import it into Zotero.

I don’t say Zotero is bad or whatever, the question was about how one manages their references. So this is just my story of a 10 years long personal experience.

@bruce, I’ve just read in another thread that you are the original creator of CSL. That’s amazing to meet you here in person!

Once upon a time, exactly 9 years ago in July, I was writing my PhD thesis and instead of writing the thesis I spent a whole week creating a custom CSL style for my dissertation. The requirements to that style were very stupid, posed by a standard called DSTU —Ukrainian analogue of Russian GOST, both based on ISBD — which was not really a citation style but something called bibliographic description. I think I was still using Mendeley back then or right in transition to Zotero. Anyway, since my discipline is chemistry, moreover a field of chemistry too far away from any computers and programming, I had a very hard time — had to start with reading what was XML in the first place. But that week, looking at it retrospectively, determined a lot in my relationship with computers. So the fact that I’m involved in org-roam-bibtex now, making my small contributions to org-roam, I really owe to you :slight_smile:

2 Likes

Right; really depends on your priorities.

The team that created Zotero, BTW, is headed up by historians. So it’s better optimized for, say, humanities, than others that may be better for sciences.

Well, I couldn’t complain about that.

It just appeared to me that Zotero uses a sqlite database as storage backend. So far, correct me if I’m wrong, all the Emacs connectors for Zotero used its web API to communicate with it. I wonder how feasible would it be to hack the Zotero sqlite database directly from Emacs. Since emacsql-sqlite3 is now quite a mature project, would it be reasonable to do some perhaps on-the-fly mapping between Zotero and .bib file?

After quick googling I’ve found this project: https://github.com/whacked/zotero-query.el
It is able

“to query the zotero db + open files, without having to have a running zotero instance”

And even provides custom zotero: links for Org-mode.

1 Like

Really interesting :slight_smile:

What does that give a user that better bibtex doesn’t?

Native Emacs interface to Zotero? It’d be a rather complex project, however, on par with better bibtex. And very niche, and with many caveats. I doubt it’s feasible therefore.

I’m not sure why one-way is a problem if I manage my references in Zotero and have the BetterBibTex extension keep my .bib file updated. Is there any reason I’d want/need to edit the .bib file directly in emacs?

1 Like

I don’t think so; no. This is with the caveat that you have BBT setup to maintain the correct citekeys.