Skip to content

feat: papis / Zotero integration — export search results to reference manager #18

Closed

Description

@szaghi

Summary

Allow mosaic search results to be exported directly into Papis or Zotero reference management libraries.

Motivation

Many researchers manage their bibliography with Papis or Zotero. Exporting MOSAIC results directly into these tools would remove the manual copy-paste step and keep metadata in sync with the local cache.

Proposed behaviour

# Add all results to the default Papis library
mosaic search "attention is all you need" --oa-only | mosaic export --papis

# Add to a specific Papis library
mosaic search "diffusion models" --export papis --papis-lib mylib

# Add to Zotero (requires Zotero local API running on port 23119)
mosaic search "protein folding" --export zotero --zotero-collection "AI Biology"

# Export from a previous search (cache)
mosaic export --papis --query "diffusion models"

Implementation notes

Papis:

  • Invoke papis add --from-doi <doi> for each result (if DOI known)
  • Or write a temporary BibTeX file and papis add --from-bibtex
  • Optionally copy the downloaded PDF to the Papis document folder

Zotero:

  • Use the Zotero local API (port 23119) — no credentials needed
  • POST /users/0/items with CSL-JSON payload built from Paper fields
  • Attach PDF if already downloaded

Dependency: Papis integration requires papis to be installed separately. Zotero integration has no Python dependency (pure HTTP to localhost).

Priority

Tier 2 — moderate value, moderate complexity

Activity

  1. szaghi commented on Oct 14, 2026

    @szaghi
    OwnerAuthor

    Closing: Zotero export has shipped — mosaic search/get --zotero [--zotero-collection NAME] [--zotero-local] via mosaic/zotero.py (local API on :23119 or web API with key), including PDF attachment in local mode. The piped mosaic search | mosaic export --papis syntax proposed here doesn't match the current CLI.

    Papis was never implemented. If there is demand, it is a small follow-up (papis add --from-bibtex on top of the existing BibTeX exporter) and deserves its own narrowly scoped issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions