llm-for-zotero

yilewangAGPL-3.0活跃维护

把 LLM 研究助手接进 Zotero 文献库,基于 RAG 和 MCP 让 AI 直接检索、阅读并分析你收藏的论文,省去手动翻找和整理。

An open-source research agent system for your Zotero library.

v3.9.17发布于 2026-11-10 06:12 UTC3,543star +24 / 7 天221fork同步于 2026-11-11 05:38 UTC

怎么上手

由 README 提炼,执行前请确认
从 Releases 下载最新 .xpi,在 Zotero 中打开 Tools -> Add-ons -> 齿轮图标 -> Install Add-on From File 选择该 .xpi,重启 Zotero 后在 Preferences -> llm-for-zotero 配置 Provider、Base URL、Key 和模型并点击 Test Connection
硬件要求按 README 说明

README 未说明显存或 GPU 要求;插件运行在 Zotero 内,模型可走云端 API、本地 OpenAI 兼容模型或 WebChat/Codex/Claude Code 等后端。

下载:源码 zip·GitHub Releases(安装包)本站不镜像安装包

项目说明

由 README 自动翻译提炼

把大模型接进 Zotero 阅读器,边读论文边问答、总结、比文献并直接存笔记

把 LLM 研究助手接进 Zotero 文献库,基于 RAG 和 MCP 让 AI 直接检索、阅读并分析你收藏的论文,省去手动翻找和整理。

核心能力

  • 在 Zotero 侧边栏对当前 PDF 提问并生成可跳转原文的引用
  • 支持截图识图、上传 PDF/DOCX/PPTX/TXT/Markdown 作补充上下文
  • 用斜杠命令引用多篇论文做跨文献对比
  • Agent 模式可全库检索、打标签、改元数据、导入与整理笔记
  • 笔记可写入 Zotero 或本地 Markdown 目录如 Obsidian、Logseq

容易踩的坑

需先在 Zotero 偏好设置里填好 provider 的 base URL、密钥和模型名并测试连接,否则无法对话;不想用 API key 需另行配置 WebChat 或 Codex App Server;Codex 与 Claude Code 模式依赖本地 codex app-server 运行时或自己的 Claude Code 登录。

内容由模型根据 README 生成,可能不完整或不准确,以官方文档为准。看原文 README

最近发版

5 个版本v3.9.17
  1. v3.9.17Release v3.9.17最新正式版2026-11-10 · 2026-11-10 06:12 UTC

    What's new in LLM for Zotero

    Changes since 3.9.16

    You can now ask about a PDF selection right in the reader, in a small card next to the text. The agent reads books and theses part by part instead of reading cut text. Note batches now resume safely after a crash, and MinerU 4.1 works again.

    Inline Ask in the PDF reader

    why inline ask feature?

    • I want to provide a truly immersive experience of your reading. If you have a question, just ask right the way, even without opening side panel. Attention is precious: inline ask is for people who truly want to focus on reading and understanding, with as less as interruption from other information. You select, ask, save as annotation, and then move on for the next challenge.

    Select text in a PDF, then click Inline Ask next to Add Text. A card opens next to the selection, in place of Zotero's selection popup.

    • Ask your own question, or click a quick prompt: Explain, Define terms, or Translate.
    • The answer streams into the card, and you can ask follow-up questions.
    • Math in answers renders as it does in the chat panel.
    • Select text in an answer to copy it, or click Quote to ask a follow-up about that part.
    • Pick the model and the effort in the card. The card keeps its own choice, apart from the sidebar.
    • Right-click a quick prompt to edit, delete, or add prompts.
    • The card opens at a comfortable reading width. Drag it by its blank margins to move it, and drag any corner to resize it.
    • Set the text size from the More menu, or with Cmd/Ctrl + =, -, and 0.
    • Press Escape anywhere in the reader to close the card.
    • In the Add Text box, press Cmd/Ctrl+Enter to send the quote and your question.

    When you like an answer:

    • Save as annotation highlights the selection in the color you pick. The answer becomes the annotation's comment, and you can edit it before you save. Save works with the sidebar open or closed. If a save fails, the card keeps your color and comment, and Save tries again.
    • Continue in sidebar opens a new paper chat that holds the card's questions and answers. The chat shows in History like any other chat.

    Long documents

    Books and theses now get a map of their parts, with page ranges and sizes. The agent reads the parts that it needs, and it never reads text that was cut short.

    • Journal articles, preprints, and conference papers still load whole, as before.
    • A document that is too large and has no chapters gets a page map.
    • When you select text in a long document, the agent is told which part holds it.
    • Page reads now work for PDFs whose text lost its blank first pages.

    Notes

    • A chat reply saved as a note now takes your question as its title (#271). The note starts with the question as a heading, then the answer. A long question, or one with quoted passages, also appears in full under the heading. Save chat as note puts the first question at the top.
    • Citation chips now store the page label, the same as Zotero's own citations (#546).
    • Save as note on part of an answer keeps the whole selection, with its headings and code blocks (#549). Before, it lost everything after the first code block.
    • A note batch that stops mid-way, from a crash or a restart, now resumes without writing any note twice. This also holds for papers with two notes, for standalone notes, and after an undo.
    • In Auto mode, the agent's edit of a note with a new citation now saves on the first try. Before, the first attempt could be refused, and the retry could lose the citation.

    Sidebar

    • Every chat start page now has a short list o
  2. v3.9.16Release v3.9.162026-11-02 · 2026-11-02 16:23 UTC
    查看更新说明

    What's new in LLM for Zotero

    Changes since 3.9.15

    The agent now reads the parts of a paper you name, in any language, and shows you which parts it read. It can do more in your library: attach files, find PDFs, change item types, annotate, and open a PDF at a page. Claude Code and Codex show their steps in Task progress, and Codex asks before it writes to Zotero.

    Reading papers

    Ask for the parts you want

    Name the parts of a paper you want, such as "the abstract and the results". The agent picks those sections from the paper's own outline, in any language. It reads each picked section whole. If a paper has no such section, the agent says so instead of reading something else. On later turns, the agent reuses the same pick for that paper.

    See what was read

    Task progress shows the parts you asked for, such as "Abstract, Results". It no longer shows chunk numbers or "PDF text". "Full" now means that the agent read every character of the paper. Task progress also shows which papers the agent kept or skipped, and why.

    Digests and long papers

    A digest now reads up to 250,000 characters of a paper. If a paper is longer, the digest reads its start and its end, and says so. A digest's quotes can now be cited in later chat answers.

    Citations and quotes

    Quotes come from body sentences, not from headings. A quote never cuts a formula in half. Math in a cited passage looks the same in Task progress as in the quote card. A quote from an abstract that no PDF page holds now opens its paper. Literature reviews can cite papers that are not in your library.

    Library actions

    The agent can now:

    • attach a file or a web page to an item, and run Find Available PDF;
    • change an item's type;
    • edit an annotation's comment and color;
    • underline a passage or put a sticky note on it;
    • open a PDF at a page or at an annotation;
    • save a finished document as a standalone note in one or more collections;
    • add to many notes in one step;
    • read library statistics, tag counts and Related links.

    Bulk edits of more than 50 items save their progress. If Zotero stops during a bulk edit, the edit resumes without repeating done items, and you can still undo it. One approval card now covers every duplicate group in a merge. The undo card describes library changes in plain words.

    Fixes

    • Searches and lists report the true total and page through all results.
    • Duplicate search uses Zotero's own engine over every item.
    • A metadata edit lands on the item it names, and its card shows every field it writes.
    • Undo restores only the fields that an edit changed.
    • A merge refuses items of different types.

    Claude Code and Codex

    Claude Code shows its thinking and steps in Task progress. Its subagents stay inside the turn. Zotero passage citations now reach Claude Code answers. You can send per-snippet questions to Claude Code (#544).

    Codex shows an approval card before it runs a Zotero write. Codex threads use the plugin's Zotero tools, not your user-level Zotero server. Codex has its own copies of the skills.

    Model menu

    The model menu opens on your main agent's model list. A separate Subagent card sits above the list. Open it to pick the model that reads papers for the main agent. A fast, low-cost model suits the subagent.

    Documents in the side panel

    A document that the agent writes, such as a literature review, shows as Document in the side panel. Its text is larger, and you can change its size with - and +. You can open the document in its own window. Show in answer in Task progress now finds sentences inside documents.

  3. v3.9.15Release v3.9.152026-10-28 · 2026-10-28 21:07 UTC
    查看更新说明

    What's new in LLM for Zotero

    Changes since 3.9.14

    You can now open any chat in its own small window and keep it beside your paper. Answers are easier to read, with type and spacing closer to Claude desktop. Zotero's Codex sessions can use their own Codex home folder, apart from the Codex app.

    Chat windows

    Open a chat in its own window

    In the separate chat window, drag a chat out of the chat list, or drag the chat title. You can also right-click a chat and choose Open in New Window.

    The new window holds that one chat.

    It does not follow the PDF reader tab, so the chat keeps its own paper as context.

    This serves to your undivided attention: when you want to focus on this conversation, but at the same time, you may want to check other papers from zotero. By using this new independent window, you can focus on your task/workflow without getting visual interruption. The unlinked icon next to the title shows this; hover it for details.

    • History opens another chat in the same window.
    • The side panel lists your past chats, read only.
    • Open in main window moves the chat back to the separate chat window.
    • In a paper chat, click the paper line to show that paper in your library.

    Each chat opens in one window at most. If you open it again, its window comes to the front. These windows close with Zotero, and when their chat is deleted or their paper goes to the trash.

    Other window changes

    The side panel stays open when you switch between Paper chat and Library chat. Buttons in the separate chat window now show their tooltips.

    Easier reading

    Answer text is one step larger than the interface text. Paragraphs, headings, lists and tables have more even spacing. Code follows your font size setting instead of a fixed size. The sidebar chat has the same side margins in both pane layouts. A code block shows one language label while it is still being written. The paper chat's Cited card no longer repeats "Cited" inside it.

    If you changed line spacing or font size in Preferences, your settings still apply.

    Codex

    A new Codex home folder setting is in Agent → Codex → Advanced. Set it to keep Zotero's Codex sessions apart from the desktop Codex app, with the same ChatGPT sign-in. Leave it blank to keep the current behavior. You can paste a path in quotes, or start it with ~ for your home folder. Thanks to @excechen-create for the request (#529).

    Sync-for-Zotero

    Now you can also sync the html, images or codes back to your LLM-for-Zotero chat panel to read them. Check: https://github.com/yilewang/sync-for-zotero, version v0.0.19.

    Fixes

    • Closing a chat window while an answer is still being written no longer crashes Zotero.
    • With Gemini reasoning on, token counts now include thinking tokens. Thanks @pcbeingused333 (#539).
    • In the Chinese interface, action and skill descriptions in the command menu are now translated. Thanks @AlumiCh (#537).
    • Paper overviews now report MinerU as their text source when MinerU text was used. Thanks @AlumiCh (#538).
  4. v3.9.14Release v3.9.142026-10-26 · 2026-10-26 22:28 UTC
    查看更新说明

    What's new in LLM for Zotero

    Changes since 3.9.13

    The chat has a new layout: the composer floats over the bottom of the chat, and the window sidebar groups your chats by agent. Answers that use the web now credit their sources. Task progress shows which papers and pages each question used, and where the answer uses them. A local MinerU server can now start when you need it and stop when you don't.

    The chat window

    A floating composer

    The composer and the shortcut chips now float over the bottom of the chat. The chat fades out at its top and bottom edges, and new parts of an answer fade in while it is written. The composer starts at one line and grows as you type. If you drag the composer at the bottom of the screen, the window grows upward. The model and effort menus now open upward, like the runtime menu.

    Conversations, grouped by agent

    The window sidebar has a sortable Conversations list instead of time headings. You can group chats into foldable Agent, Codex and Claude sections. Each section has its own sort order and a + button for a new chat. Pinned chats use the same sections.

    Faster switching

    Switching between papers and between chats is quicker again.

    In the chat

    Task progress: the sources for each question

    Task progress now opens in a side panel tab. It has one block for each question, with the papers and web pages that question used. For a library paper, it lists the passages the agent read, then where the answer uses them. Show in answer finds the sentence that cites a source, highlights it, and scrolls to it. Each cited sentence ends with a numbered mark.

    Taks progress bar can show the exact evidence from your local library paper, when agent generates answer for you, during the library chat or paper chat:

    Even the internet library search:

    You can see what agent read for you, in details.

    Now, you have a better control what agent collected to generate answer, with every eligibility trace (term misuse, I knew)

    Especially with the new panel: "what agent read":

    Web answers credit their sources

    Fixes #526: web searches no longer end with "could not safely attach valid paragraph-level sources". Answers that use the web now show numbered source marks and a source chip at the end. The marks and the chip stay when you copy the answer. Paper and page links show the site's icon. Web links open in the side panel. The agent now reads a web page step by step, and goes deeper only when the page needs it.

    Dark theme

    Diagrams and web pages from the model stay readable in dark theme.

    MinerU

    A local server that starts and stops on its own

    Thanks to @AkimioJR (#530). In MinerU local mode, you can now enter a command that starts the server, for example mineru-api. The plugin starts the server when it parses a PDF. It stops the server after a set time with no work, to free memory and GPU memory. The default time is 10 minutes. Preferences shows the server status, with Start and Stop buttons. The server also stops when you quit Zotero.

    Models and fixes

    • OpenCode Go is now a provider preset, and OpenCode /inference URLs work (#525).
    • Fixed: on Zotero 10.0.6, LLM for Zotero no longer blocks other plugins from starting
  5. v3.9.13Release v3.9.132026-10-22 · 2026-10-22 21:45 UTC
    查看更新说明

    What's new in LLM for Zotero

    Changes since 3.9.12

    The chat window now has a side panel for side chats, past chats and everything a chat made. Files the agent saves show up as cards you can open. Code, diagrams and figures got a cleaner look, and Claude Code now works without any setup (now, you can use claude code mode without installing a separate repo cc-llm4zotero-adapter. But, a big shoutout to @jianghao-zhang and his repo for being the bridge for over 7 months to connect claude code into the plugin. https://github.com/jianghao-zhang/cc-llm4zotero-adapter)

    The chat window

    A side panel next to your chat

    The separate chat window has a new side panel. Open it with the button at the end of the Paper chat | Library chat row. The window grows to the right, and the panel holds up to eight tabs.

    • Side chat: ask a quick question without leaving your main chat. A side chat sees your main chat, can use a different model, and is not saved.
    • History: open any earlier chat to read it next to the one you are working in. From there you can quote it, add its paper, or make it your main chat.
    • Miscellaneous: a list of everything the chats of this paper made, such as diagrams, figures, web pages, code, plans and files, newest first. Go to chat takes you to the message that made it.

    Move anything into the side panel

    Diagrams, code, web pages, figures, plans and files in the chat have a →| button. It opens the item in its own side panel tab, so it stays in view while the chat moves on.

    Quote a reply in a side chat

    Select text in an answer and the popup now offers Quote | Quote in side chat. Type your question and press Enter, and it goes to a side chat instead of the main one.

    Pinned papers, each with its own side panel

    Pin the papers you are working on and they stay at the top of the sidebar. Click one to bring back its chat and its side panel tabs. Each paper keeps its own tabs. A dot shows while an answer is being written, and another shows an answer you have not seen yet.

    Faster switching, and an update button

    Switching between chats in the window is quicker, and the window opens at the same scroll position as the sidebar chat. A small button next to Preferences shows your version and its release notes. When an update is out, one click installs it, and Zotero no longer needs a restart for the update to look right.

    In the chat

    A cleaner look

    Code, diagrams, figures, tables and equations now sit directly in the answer, without a box around each one. Their buttons appear when you move the pointer over them.

    Web page previews

    When an answer contains a complete web page, you see it running right in the chat. The page runs in a safe box with no internet access.

    One full view for everything

    Click a figure, picture, diagram, web page or file to open it in one shared full-view window. Zoom with the trackpad or mouse wheel, drag to move, and double-click to fit it again. Figures from the paper appear in a row in the answer, with their caption and page. The figur

用户点评

登录用户的真实使用记录,可按版本和硬件筛选
共 0 条

    还没有人点评。第一个说出真实体验的人最有价值。

    README 原文

    未翻译

    LLM-for-Zotero: A Research Agent System for your Zotero Library

    Zotero support Using Zotero Plugin Template License: AGPL v3 Latest release GitHub Stars GitHub Downloads buymeacoffee

    LLM-for-Zotero brings Large Language Models into the Zotero reader, so you can ask questions, summarize papers, inspect figures, compare sources, and save notes without leaving your library. It works with standard API providers, local OpenAI-compatible models, WebChat, Codex App-Server, and Claude Code.

    Documentation:

    Demo Video

    How to do a library chat literature review with llm-for-zotero agent

    Table of Contents

    At a Glance

    • Chat with the current PDF, selected text, figures, screenshots, and uploaded documents directly inside Zotero.
    • Get grounded answers with citations that jump back to the source passage.
    • Compare multiple open papers or add external files as extra context.
    • Save answers, full conversations, and research notes to Zotero notes or local Markdown folders such as Obsidian and Logseq.
    • Enable Agent Mode for library-wide read, search, tagging, metadata, import, note-editing, and organization workflows.
    • Search the current public web and read relevant pages with Tavily, with source links attached to the answer.
    • Use your preferred backend: API keys, local models, ChatGPT WebChat, Codex App Server, or Claude Code.

    What's New

    • Codex App Server is the recommended Codex path for ChatGPT Plus users. It runs through the local codex app-server runtime and is configured from the Agent tab.
    • Claude Code Mode runs Claude Code as a separate conversation system inside Zotero, using your own Claude Code login. The plugin starts and stops the small bridge it needs for you. It can use the plugin's Zotero tools to read your library and, with your approval, edit notes, tags, metadata, and imports.
    • One history lists Agent, Codex and Claude chats together. Click the runtime badge in the message box to switch runtimes, and attach an earlier conversation from the slash menu or by asking for it in plain words.
    • Side panel in the standalone window opens read-only past chats or a temporary side chat next to the main chat.
    • Skills let you customize how Agent Mode handles research workflows. The plugin ships with 8 built-in skills and a portal for creating your own.
    • General Web Search lets the in-plugin Agent search the current public web with Tavily, read relevant pages, and attach source links to its answers.
    • Standalone Window Mode opens the assistant in a dedicated window with paper chat, library chat, and conversation history.
    • File-Based Notes save Markdown notes to local folders, including Obsidian, Logseq, or any plain Markdown directory.
    • Cache-aware Agent Mode preserves stable paper context, prior read evidence, and coverage state across longer research turns, then compacts old transcript history automatically when the context window gets crowded.
    • Citation navigation now keeps citation labels conservative until page locations are verified, while quote-based citations can jump back to the matching Zotero passage.
    • MinerU PDF parsing provides higher-fidelity extraction for tables, equations, figures, and local mineru-api servers, with a richer file manager for bulk parsing, cache repair, sync packages, tags, and parsing filters.

    Thanks to @jianghao-zhang and @boltma for major contributions to the Codex App Server, Claude Code, and file upload workflows.

    Quick Start

    1. Download the latest .xpi file from the Releases page.
    2. In Zotero, open Tools -> Add-ons -> gear icon -> Install Add-on From File, then select the .xpi.
    3. Restart Zotero.
    4. Open Preferences -> llm-for-zotero, choose a provider, enter the base URL, key, and model, then click Test Connection.
    5. Open a PDF in Zotero and click the LLM Assistant icon in the right-hand toolbar.

    If you do not want to use a provider API key, start with WebChat or Codex App Server.

    Configuration

    Open Preferences -> llm-for-zotero.

    1. Select your Provider.
    2. Paste your API Base URL, secret key, and model name.
    3. Click Test Connection.

    The plugin supports multiple provider protocols, including responses_api, openai_chat_compat, anthropic_messages, and gemini_native.

    You can configure multiple providers and models for different tasks, such as a multimodal model for figures and a text model for summaries. The conversation panel also supports model-specific reasoning levels and hyperparameters such as temperature and max_tokens_output.

    Demos

    Grounded Paper Chat

    On the first message, the model loads the current paper as context. Follow-up questions use focused retrieval from the same paper, keeping conversations fast and grounded. Click any generated citation to jump straight to the source passage in Zotero.

    Summaries and Selected Text

    Summarize a full paper, focus on methodology or results, or select any paragraph and ask the model to explain it. The selected-text pop-up can add highlighted text to chat with one click. It can also be disabled in settings.

    Figures and External Files

    Take screenshots of figures, attach up to 10 screenshots, or upload local files as additional context. Supported uploads include PDF, DOCX, PPTX, TXT, and Markdown.

    Multi-Paper Comparison

    Open multiple papers in Zotero tabs and type / to cite another paper as additional context.

    Notes, History, and Presets

    Save answers or selected text to Zotero notes, export full conversations in Markdown, and customize quick-action presets for repeated research tasks.

    File-Based Notes

    Beyond Zotero's built-in notes, the agent can save Markdown research notes to any local directory you choose. Point it at an Obsidian vault, a Logseq graph, or a plain folder of .md files.

    Open Preferences -> llm-for-zotero and scroll to the Notes Directory section.

    SettingDescriptionExample
    NicknameHow you refer to this directory in chatObsidian, Logseq
    Notes Directory PathAbsolute path to the root directory where notes are saved/Users/me/MyVault
    Default FolderDefault subfolder for new notesLogs
    Attachments FolderFolder for copied figures and images, relative to the directory rootLogs/imgs

    Ask the agent to write a note using the configured nickname, for example: "Summarize this paper and save it to Obsidian." The agent gathers paper metadata, writes a Markdown note, adds YAML frontmatter, optionally copies figures from MinerU-parsed PDFs, and saves the note under the configured folder.

    Or if you want to keep notes inside Zotero, the agent can also write to internal item notes with the write-note skill. Just ask it to "save a note for this paper" without mentioning an external directory.

    Zotero Notes vs. File-Based Notes (both generated by the plugin)

    Notes use Pandoc citation syntax such as [@citekey], which works with Obsidian Zotero Integration, Pandoc plugins, and many Markdown readers.

    Note templates and figure-embedding rules live in the write-note skill. Open the Standalone Window -> Skills portal to edit them.

    Editing Zotero Notes With the Agent

    The agent keeps citations, PDF highlights, and images intact when it edits a Zotero note.

    • Citations, PDF highlights, and images stay intact. The agent sees each one as a placeholder such as {{citation:3fa9c1 ("Smith", 2020, p. 42)}} and every edit puts the original item back, so a rewrite can move a citation but never break it. An edit that would drop one is refused unless you asked for it to be deleted.
    • Clickable citations. Ask for page citations and the agent writes {{cite item=123 page=42}}, which becomes the same citation Zotero's Insert Citation makes: clicking it opens the PDF at that page.
    • Study-note blanks. A line of underscores inside a quote (> ___) becomes a divider, and a checklist item made only of underscores (- [ ] ____) keeps its checkbox as a fill-in blank.

    Agent Mode (beta)

    Agent Mode is disabled by default. Turn on Original Agent in Preferences -> Agent tab. While it is on, new chats use the Agent. If you also turn on Codex or Claude Code, click the runtime badge in the message box to switch between them.

    It can read and search your library, draft notes, update metadata or tags with confirmation, and undo recent write actions from the conversation.

    When enabled, the LLM can act on your Zotero library with read tools, write tools, confirmation cards, and undo.

    The design philosophy is simple: read tools are unrestricted; write tools stay reviewable and undoable.

    Long agent runs are cache-aware. The plugin keeps stable Zotero context and previously read evidence separate from the changing chat transcript, tracks which papers and passages have already been inspected, and automatically compacts old turns when the model context fills up. This lets follow-up questions reuse grounded evidence when it is still relevant, while still asking the agent to read again when the needed source or coverage layer is missing.

    Tool areaToolsWhat they do
    Library and PDF readinglibrary_search, library_read, library_retrieve, paper_read, read_attachment, context_readSearch items and collections, read metadata, read papers, search paper passages, render PDF pages, inspect attachments and the chat context
    Scholarly discoveryliterature_search, literature_reviewSearch OpenAlex, arXiv, and Europe PMC for papers, recommendations, references, and citations (metadata lookup via CrossRef and Semantic Scholar), then present ranked candidates
    General web researchweb_search, web_readSearch the current public web with Tavily, read relevant pages, and show source links with the answer (only when a Tavily key is set)
    Library writeslibrary_update, library_import, library_delete, annotate_pdfApply tags, update metadata, move items, manage collections and attachments, merge duplicates, trash items, import identifiers or local files, highlight PDF passages
    Citations and settingslibrary_cite, library_settingsFormat citations and bibliographies with Zotero's citation engine, and read or change the Zotero preferences the agent may touch
    Notes and documentsnote_write, note_write_batch, submit_documentCreate, append to, or edit Zotero notes, write one note on each of many items, and finalize longer documents
    Filesystem and scriptingfile_io, run_command, zotero_scriptRead/write local files, run analysis commands, or execute Zotero JavaScript with write confirmations
    Skills and questionsload_skill, request_user_input, past_chat_attachLoad a skill's instructions when the task needs them, ask you a question when a choice is ambiguous, and add an earlier conversation to the chat
    Task trackingtask_update, workflow_scriptSplit a compound request into parts the plugin tracks, and run several tool calls in one script with loops and conditions
    SafetyundoUndo recorded write actions from the conversation's durable change history, one at a time or several newest-first

    Agent Mode Demos

    Multi-step workflow
    Find related papers

    Use /discover_related while viewing a paper to run the direct OpenAlex action. It opens Recommendations, References, and Citations tabs with up to 20 papers per mode by default. Use /discover_related 30 to change the initial retrieval limit, Load more to retrieve 20 more per mode while preserving your selections, and Import selected to save the papers you choose. This shortcut does not require a model.

    Ask “find relevant papers” in chat to start model-assisted discovery. The agent assesses retrieved candidates and presents a ranked card with relevance reasons. An explicit count, such as “find 15 relevant papers,” sets the batch size; otherwise it starts with five. Use Find more to add another batch of the same size while preserving your selections, then Import selected to save the papers you choose. Requests for references, citing papers, or a specific search source constrain discovery to that request. If fewer relevant matches are available, the card explains the shortfall instead of padding the list. A configured model is required for model-assisted discovery; literature search used to answer a question remains a separate flow that can finish with a cited answer without an import card.

    Apply tags
    Write a note

    Skills

    Skills customize Agent Mode behavior for recurring research workflows such as paper QA, evidence retrieval, figure analysis, paper comparison, literature reviews, note writing, and cited-reference import.

    Skills are customizable guidance files that shape how Agent Mode approaches different types of requests. The agent sees only each skill's name and description at the start of a turn. There is no automatic pre-selection step: the agent calls load_skill to read a skill's full instructions when it decides the task needs them. Choosing a skill with / applies it directly, and an approved plan keeps the exact skill versions it was approved with.

    Skills require Agent Mode. They have no effect in standard chat mode.

    Built-in skills:

    SkillWhat it guides the agent to do
    evidence-based-qaRetrieve missing evidence for specific paper questions
    analyze-figuresInterpret figures and tables using MinerU-extracted images
    compare-papersCompare multiple papers using batched reads and focused retrieval
    library-analysisSummarize or analyze your entire library without context overflow
    literature-reviewConduct a structured literature review
    reorganize-librarySort papers into folders or tags after you review the grouping
    write-noteWrite Zotero notes or Markdown notes in configured local folders
    import-cited-referenceImport papers cited in the current PDF into Zotero

    To create a custom skill, open the Standalone Window, click the Skills icon, choose "+ New skill", edit the skill file, and save. Skills are stored as Markdown files in {ZoteroDataDir}/llm-for-zotero/skills/.

    General Web Search

    Agent Mode can search the current public web with Tavily, AnySearch, or DeepSeek and read returned pages when search-result snippets are not enough. Use it for current facts, official documentation, news, finance, product information, and other general-web evidence. Scholarly discovery remains separate: the agent searches OpenAlex, arXiv, and Europe PMC (with CrossRef and Semantic Scholar for metadata lookup), and it can combine both kinds of search when a question needs academic and general-web sources.

    To enable general web search with Tavily:

    1. Get a Tavily API key from app.tavily.com.
    2. Open Preferences -> llm-for-zotero -> Agent.
    3. In Web search, keep Tavily (the default), paste the API key and click Test connection.
    4. Enable Agent Mode and ask it to search or verify something online.

    There is no separate enable switch. The web_search and web_read tools become available to compatible in-plugin Agent conversations when the selected provider can run: Tavily has a key, AnySearch is selected, or DeepSeek finds an official DeepSeek model profile. Tavily is the default. DeepSeek is an optional choice that uses the key of an official DeepSeek model profile, and DeepSeek bills that account. They are not added to WebChat, Codex App Server, or Claude Code conversations, which use their own runtimes and tool sets.

    With Tavily, the agent chooses basic or advanced search and page-reading depth from the request, or follows an explicit request such as "use advanced web search." It can narrow searches by topic, date, or domain, and answers include clickable source indicators for the pages actually used.

    Basic search costs 1 Tavily credit and advanced search costs 2. Page extraction also consumes Tavily credits, and Tavily currently offers a free monthly allowance. The API key stays in local Zotero preferences, but search queries and requested URLs are sent to Tavily, so do not include credentials or sensitive private text in web queries.

    AnySearch

    In Preferences → llm-for-zotero → Agent → Web search, select AnySearch. Leave AnySearch API key (optional) blank for anonymous access, or enter an existing key. Saving preferences does not make a request. The provider selection is persisted; selecting AnySearch does not reuse a Tavily key. No environment-variable key fallback is used. Test search (sends a public query) explicitly sends a fixed public query without invoking a model and displays result count, titles, URLs and the request ID when available. It consumes service quota; it is not an Agent conversation or proof of the Agent tool/citation path.

    AnySearch supports general search with query and maxResults (1–10), and web_read with one to five URLs returned by search in the same run. Extraction uses at most two concurrent requests and returns bounded page text, not query-focused passages. Depth, topic, date/domain filters, chunk controls and vertical/source selection are not supported and are rejected rather than silently ignored. PDF, Office and media-binary extraction are not supported. Search queries and requested URLs are sent to AnySearch; do not include credentials or private library content.

    Anonymous quotas and permissions are server-controlled. An exhausted quota produces an error; the integration does not adopt credentials from responses, automatically retry, switch providers, or report fictional credit usage.

    DeepSeek

    DeepSeek search uses the key of your first model profile whose API address is the official https://api.deepseek.com; keys of relays and other hosts are never sent to DeepSeek. It costs $0.75 per 1,000 successful searches or page fetches, billed to that DeepSeek account, and failed or empty calls are not billed. Queries are limited to 128 characters, including the site and date filters, and search queries and requested URLs are sent to DeepSeek.

    Codex Setup (ChatGPT Plus Subscribers)

    If you have a ChatGPT Plus subscription, you can use Codex models in the plugin without a separate API key by signing in through the Codex CLI.

    New users should choose Codex App Server from the Agent tab. The older Codex Auth (Legacy) path remains available for existing users, but is planned for future deprecation after app-server validation.

    Codex App Server setup

    1. Install the Codex CLI:

      npm install -g @openai/codex
      

      On macOS, you can also use brew install --cask codex. On Windows, you can also use winget install OpenAI.Codex; install Codex from PowerShell or Command Prompt rather than WSL, so Zotero MCP can use the Windows-local loopback connection.

    2. Log in:

      codex login
      

      Credentials are saved to ~/.codex/auth.json.

    3. In Zotero, open Preferences -> llm-for-zotero -> Agent tab.

    4. Turn on Enable Codex App Server integration.

    5. Choose the default model and reasoning level.

    6. Click Test connection.

    7. In the chat header, click Codex to switch into the Codex conversation system.

    Codex App Server and Claude Code are mutually exclusive runtime modes in the Agent tab. Disable one before enabling the other.

    Codex Auth (Legacy)

    Existing users can keep the legacy direct backend configuration:

    • Open the AI Providers tab.
    • Choose Auth Mode -> Codex Auth (Legacy).
    • Keep API URL https://chatgpt.com/backend-api/codex/responses.
    • Keep your Codex model name, for example gpt-5.5.

    Legacy notes:

    • Reads credentials from ~/.codex/auth.json or $CODEX_HOME/auth.json.
    • Automatically attempts token refresh on 401 responses.
    • Embeddings are not supported in this legacy direct mode yet.
    • Local PDF/reference text grounding and screenshot/image inputs are supported.
    • The Responses /files upload plus file_id attachment flow is not supported yet.

    Claude Code Setup

    Claude Code mode runs Claude Code as a separate conversation system inside Zotero. It reuses the sidebar and standalone-window UI, but has its own scope state, model settings, permission semantics, slash commands, and project skills. Claude chats appear in the same history list as your other chats, with a small Claude label.

    Special thanks to @jianghao-zhang, who built the Claude Code integration and its bridge (cc-llm4zotero-adapter). The bridge now ships inside the plugin, with the author's permission, under packages/claude-bridge.

    Claude Code mode can use the plugin's Zotero tools. It searches and reads your library and papers without asking. Library changes, such as editing notes, tagging papers, updating metadata, or importing items, follow your Claude Code Permission mode. In safe mode, they ask for your approval first.

    You need two things on your computer. The plugin takes care of the rest.

    • Node.js 18 or newer. Download it from nodejs.org (the LTS version is fine), or use a version manager such as NVM, Volta or Homebrew. Check it in a terminal with node --version.
    • Claude Code, installed and logged in. Follow Anthropic's installation and authentication guides. You can use your Claude subscription or an API key.

    1. Install and log in to Claude Code

    In a terminal, run:

    claude
    

    Finish the login steps it shows, then close it. You only need to do this once.

    2. Turn on Claude Code inside Zotero

    Open Preferences -> llm-for-zotero -> Agent tab, and switch on Claude Code. Recommended settings:

    SettingRecommended value
    Claude CodeOn
    Config sourcedefault - user + project + local
    Permission modesafe
    Default modelsonnet
    Default reasoningauto

    Then click the Claude Code button in the chat header, or click the runtime badge in the message box and pick Claude, to enter Claude Code mode.

    That is all. You do not need to download or start a bridge yourself. While Claude Code mode is on, Zotero starts a small helper program (the "bridge") that connects Zotero to your Claude Code. It runs only on your computer, only answers Zotero, and stops when you quit Zotero or turn Claude Code off. If you never turn on Claude Code, nothing extra runs.

    The Bridge section at the top of the Claude Code settings shows whether the bridge is running. Use Restart bridge if something seems stuck, and Open log to see what the bridge reported.

    Keep Config source on default unless you already understand Claude Code settings layers. In default, Claude Code can use your normal user settings plus Zotero-managed project and per-conversation local settings. The other options are:

    • user-only: only your machine-wide Claude settings.
    • zotero-only: only Zotero-managed project and local settings.

    3. If it does not work

    The Bridge status line says what is wrong in plain words. The usual causes:

    The status saysWhat to do
    Node.js was not foundInstall Node.js 18 or newer. If it is installed but Zotero cannot find it, run which node (macOS, Linux) or where node (Windows) in a terminal and paste the result into Advanced -> Node.js path.
    needs Node.js 18 or newerInstall a newer Node.js from nodejs.org.
    Claude Code was not foundInstall Claude Code. If it is installed, run which claude (macOS, Linux) or where claude (Windows) and paste the result into Advanced -> Claude Code path.
    Running, but Claude replies failClaude Code is probably not logged in. Run claude in a terminal and log in, then press Restart bridge.
    keeps stoppingPress Open log to see why, fix the cause, then press Restart bridge.

    Zotero opened from the Dock or Start menu does not always see the same programs as your terminal. The plugin looks in the usual places (NVM, Volta, Homebrew, ~/.local/bin and the Claude Code installer's folder), but the two path settings are there if it still cannot find them.

    Advanced options

    • Extra bridge options passes command-line options to the bridge, for example --additional-directories ~/Papers to let Claude read another folder, or --append-system-prompt-file ~/zotero-claude.md. Press Restart bridge after changing it.
    • Use my own bridge is for people who run the bridge themselves, for example inside WSL while Zotero runs on Windows, or on another computer. Zotero then sends Claude requests to the Bridge URL and does not start its own bridge. The bridge's code lives in packages/claude-bridge; see its README for how to run it by hand.

    Upgrading from the old cc-llm4zotero-adapter

    Earlier versions needed the separate cc-llm4zotero-adapter repository and npm run serve:bridge or npm run daemon:*. That is no longer needed. Your Claude Code conversations, skills and settings keep working, because the new bridge uses the same ~/Zotero/agent-runtime and ~/Zotero/agent-state folders.

    If you installed the old macOS background service, it can stay, since it does not get in the way, but it is no longer used. Zotero tells you once if it finds it. To remove it, run this in your old adapter folder:

    npm run daemon:uninstall
    

    If you already deleted that folder, run these two commands instead:

    launchctl bootout gui/$(id -u)/com.toha.ccbridge
    rm ~/Library/LaunchAgents/com.toha.ccbridge.plist
    

    4. Claude project skills and commands

    Zotero creates a Claude runtime root under your home directory, usually shaped like:

    ~/Zotero/agent-runtime/profile-.../
    

    Shared Claude project assets live in:

    CLAUDE.md
    .claude/settings.json
    .claude/skills/
    .claude/commands/
    

    Each Claude conversation also gets its own local .claude folder under the runtime scopes/ tree, so per-conversation overrides do not leak into other chats.

    The Zotero UI loads the model catalog advertised by the Claude Code bridge and preserves each model value exactly, including aliases, explicit model IDs, context-window variants, custom provider values, and future model families. The chat model picker identifies the active conversation so discovery uses the same scoped .claude/settings.local.json stack as the turn. The model preference remains editable when discovery is unavailable. Claude Code is responsible for resolving or rejecting the selected value and for applying provider or proxy configuration.

    MinerU PDF Parsing

    MinerU is an advanced PDF parsing engine that extracts high-fidelity Markdown from PDFs, preserving tables, equations, figures, and complex layouts that standard text extraction often mangles.

    When enabled, the plugin sends newly added PDF attachments to MinerU for parsing and caches the result locally. Later interactions with that paper use the MinerU-parsed content.

    How to enable MinerU

    1. Open Preferences -> llm-for-zotero.
    2. Find the MinerU section and check Enable MinerU.
    3. Keep cloud mode enabled, or check Use local MinerU server for local mode.
    4. For cloud mode, optionally enter your own MinerU API key — see below.
    5. For local mode, run a self-hosted mineru-api server and keep the default base URL (http://127.0.0.1:8000) unless your server uses a different address.
    6. Add or import a PDF into your Zotero library. The plugin will automatically parse newly added PDF attachments with MinerU and cache the result for future conversations.

    MinerU can start without an API key through the built-in API, but a personal key is strongly recommended. The built-in API may no longer be supported after June 1, 2026.

    To get a free personal key:

    1. Go to mineru.net and create an account.
    2. Navigate to account settings and generate an API key.
    3. In Zotero, paste the key into the MinerU section.
    4. Click Test Connection.

    When a personal key is provided, the plugin calls https://mineru.net/api/v4 directly.

    Using a local MinerU server

    Local MinerU server support was contributed by @renyong18 in PR #152.

    Local mode sends PDFs to a self-hosted mineru-api server through POST /file_parse and stores the returned ZIP output in the same local cache format as cloud parsing. The default base URL is http://127.0.0.1:8000.

    Prerequisites for local mode:

    1. Install MinerU and run mineru-api (see the MinerU docs for installation).
    2. Make sure required models are downloaded — mineru-api lazy-loads on first request, so the very first parse (or the first parse after switching backend) can take noticeably longer than steady state.

    You can pick a Backend in the local section:

    • pipeline (default) — general-purpose, multi-language, CPU-friendly.
    • vlm — VLM-based, high accuracy on Chinese/English documents, requires GPU.
    • hybrid — newer high-accuracy hybrid pipeline, multi-language, requires local compute.

    The first parse after starting the local server, or after changing backend, can be slow while MinerU loads or downloads models. Test Connection checks that the server process responds at /health; it does not guarantee that all models are warmed up.

    With the default 127.0.0.1 address, PDFs stay on your machine. If you change the base URL to a LAN or remote server, PDFs are sent to that server.

    Pause / cancel limitation: mineru-api exposes no cancel or DELETE endpoint (only POST /file_parse, POST /tasks, GET /tasks/{id}, GET /tasks/{id}/result, GET /health). When you click Pause, the plugin stops the queue and aborts the HTTP wait, but the parse already running on the server keeps executing until it finishes — the GPU/CPU will not free up sooner. If you need to abort immediately (for example to switch backend without waiting), restart the mineru-api process yourself.

    Managing MinerU caches

    The MinerU preferences tab includes a Manage Files panel for maintaining parsed PDF caches:

    • Browse cached and uncached PDFs by collection, tag, title, author, year, and added date.
    • Start parsing all visible files, only filtered files, or selected files.
    • Repair local MinerU caches and synced packages when metadata or files drift.
    • Delete all, filtered, selected, or single-item caches from the manager.
    • Use tag filters, including automatic Zotero tags, to choose which papers are included in bulk actions.

    Advanced parsing filters can skip files before automatic or bulk parsing:

    • Skip files over N pages controls the maximum page count used by Start All, Start Filtered, Start Selected, and auto-parse. The default is 100 pages.
    • Exclude PDFs by Filename accepts comma-separated substrings, or regex patterns wrapped in /slashes/, for translated copies, supplements, or other files you do not want parsed automatically.

    If Sync MinerU cache with Zotero file sync is enabled, the plugin can create companion ZIP attachments containing full.md, manifest.json, content_list.json, and extracted assets. Existing local caches sync only when you request it from the MinerU tab, and synced packages can restore a missing local cache when needed.

    WebChat Setup (ChatGPT, DeepSeek & Gemini Web Sync)

    WebChat mode sends questions to chatgpt.com, chat.deepseek.com, and gemini.google.com through a browser extension, then streams responses back into Zotero. It is useful when you want browser chat access without a provider API key.

    Prerequisites:

    • Access to the selected provider site. Provider account requirements depend on the site and feature; Gemini permits some anonymous text conversations, while PDF upload and history may require sign-in.
    • A Chromium-based browser such as Chrome.

    Setup:

    1. Download the latest extension.zip from sync-for-zotero releases.
    2. Unzip it.
    3. Open chrome://extensions, enable Developer Mode, choose Load unpacked, and select the unzipped extension folder.
    4. In Zotero, open Preferences -> llm-for-zotero and set Auth Mode -> WebChat.
    5. ⚠️: Keep the selected provider tab open in your browser. A green dot in Zotero means the extension and that exact site are connected. Make sure the tab and Zotero stay in the same monitor. No minimization or backgrounding, or the connection may drop.

    Gemini requires a companion extension version that explicitly advertises the gemini target and DOM answer capture; Zotero rejects older extension builds before dispatch. The canonical gemini.google.com/app/:id conversation path, anonymous text flow, and signed-in PDF composer DOM have been observed in Chrome. A complete automated Gemini PDF, follow-up, history, and restore run remains required before a release is declared verified.

    For release validation, keep Chrome signed in with the development extension loaded and run:

    npm run test:webchat:live
    

    This opt-in gate creates a real Zotero PDF fixture and clicks the real Zotero composer send control. It verifies one exact PDF upload and answer, toggles the visible PDF chip both ways, then verifies one prompt-only turn with zero submitted PDFs through the relay and Chrome extension.

    FAQ

    It depends on the backend you choose. The plugin supports multiple backends with different requirements:

    GoalRecommended pathAPI key required?
    Use OpenAI, Gemini, DeepSeek, Moonshot, or another providerConfigure an API provider in Zotero preferencesYes
    Use a local modelConnect any OpenAI-compatible local HTTP APIUsually no
    Use ChatGPT in the browserWebChat with the Sync for Zotero extensionNo
    Use Codex models with ChatGPT PlusCodex App ServerNo separate API key
    Use Claude Code inside ZoteroClaude Code bridgeClaude Code auth
    Search and read the current public webGeneral Web Search with TavilyTavily API key
    Improve PDF extraction for tables, equations, and figuresMinerU PDF parsingPersonal MinerU key recommended

    Is it free to use?

    • Yes, the plugin is free. You only pay for API calls if you choose a paid provider. With Codex App Server, ChatGPT Plus subscribers can use Codex models without a separate API key. If you find this helpful, consider leaving a star on GitHub or buying me a coffee.

    The plugin does not train models. Data handling depends on the backend you choose: your configured API provider, local model, WebChat, Codex, Claude Code, or MinerU.

    Please open an issue on GitHub.

    Privacy and Data Flow

    Data flow depends on the backend you choose. Local models and local MinerU can keep processing on your machine; cloud providers, WebChat, Claude Code, Codex, and cloud MinerU involve their respective services or companion runtimes.

    • In standard provider mode, paper content and user messages are sent to the model provider you configure.
    • In local-model mode, requests go to the local OpenAI-compatible endpoint you configure.
    • In WebChat mode, requests are relayed through the browser extension to chatgpt.com or chat.deepseek.com.
    • When Tavily Web Search is configured, web queries and requested public URLs are sent to Tavily; the API key remains in local Zotero preferences.
    • In cloud MinerU mode, newly added PDFs are sent to MinerU for parsing when parsing is enabled.
    • In local MinerU mode, newly added PDFs are sent to the local or remote mineru-api server you configure.
    • Conversation history and cached paper context are stored locally by the plugin.
    • Agent Mode write operations are routed through reviewable actions and session undo where supported.

    Contributing

    Contributions are welcome. Bug reports, feature requests, documentation improvements, and pull requests are all useful. Please open an issue or submit a PR.

    Roadmap

    • Agent mode (beta)
    • MinerU PDF parsing
    • GitHub Copilot auth
    • WebChat mode (ChatGPT, DeepSeek, and Gemini web sync)
    • Standalone window mode
    • File-based notes (Obsidian, Logseq, any Markdown directory)
    • Claude Code integration
    • Codex App Server integration
    • Local MinerU support
    • Customized skills
    • Cross-device synchronization (MinerU cache)
    • Agent memory system