Skip to content

Guide · Agent skill

How to use the Zotero Command-Line Helper agent skill

Updated · written with AI from the project's own documentation and checked against our catalogue data

cli-anything-zotero is an agent skill that lets an AI agent read from and work with your Zotero desktop library through a command-line tool. This guide explains what the skill does, how to install it, how to ask for things in plain language, and what to watch out for. By the end you will know how to set it up and which tasks it handles well.

Zotero Command-Line HelperHKUDS/CLI-Anything · Apache-2.0

Quick start

  1. 1Install Zotero and Python. Install the Zotero desktop application and Python with pip on your computer.
  2. 2Download and unzip the skill. Download the ZIP from this page and unzip it into ~/.claude/skills/ or a project's .claude/skills/ folder.
  3. 3Install the package. From the package folder, run pip install -e . to install cli-anything-zotero.
  4. 4Enable the Local API. Open Zotero, check the status with cli-anything-zotero app status --json, and enable the Local API if it is off.
  5. 5Ask a Zotero question. In your agent chat, name Zotero and describe the citation, bibliography, tag or note task you want.
  6. 6Check the output. Review the citation or result the agent returns, especially before any write command runs.

What the skill lets the agent do

The skill teaches an agent to run a command-line tool called cli-anything-zotero against Zotero, a desktop app for managing research papers and references. It does not rebuild Zotero. It uses Zotero's own local interfaces, so the agent works with your real library.

Read commands cover app status, collections, items, tags and saved searches. Citation commands render a citation or bibliography in a style such as APA. Export returns items, and a note command adds a child note to an existing item. Some write features are marked experimental.

  • Look up collections, items, tags and saved searches
  • Generate citations and bibliographies in styles such as APA
  • Export items
  • Add child notes to existing items (note add)
  • Build structured context for an AI model from an item

Install the skill

Download the skill ZIP from this page and unzip it. Put the cli-anything-zotero folder in one of these places: ~/.claude/skills/ for all your projects, or .claude/skills/ inside a single project folder.

You can also upload the ZIP in the Claude apps under Settings → Capabilities → Skills.

The skill's package is installed with pip. From the package folder, run the install command below. The tool can then be started as cli-anything-zotero or as a Python module.

  • Install Zotero desktop first
  • Install Python with pip
  • Install the package from its folder
pip install -e .

Turn on the Zotero Local API

Search, export and citation commands depend on Zotero's Local API. If it is off, most read and citation commands will fail, so enable it before you ask for anything that uses those features.

The tool includes an enable-local-api command and a launch command. Check the state with the status command. Note that note add depends on the live Zotero window, so keep Zotero open and select the same library in the app that you want the agent to use.

cli-anything-zotero app status --json

Ask the agent for Zotero tasks in plain language

Once the skill is in place, you can ask your agent for Zotero work in ordinary sentences. The skill's description is short, so name Zotero in your request so the agent knows to use it.

Good requests name the thing you want and the output you need. For example, ask for an APA citation for one item, a bibliography for a collection, or the notes attached to a paper. If an item key is needed, give the key or ask the agent to find it first.

  • Use Zotero to give me an APA citation for item ABC123
  • Make an APA bibliography of the items in my selected collection
  • Add a note to this item saying the key takeaway is the sample size
  • List the items with the tag to-read

Examples of commands the agent can run

These examples come from the skill documentation. The agent runs them for you; you can also run them yourself to check results. Add --json to get machine-readable output.

Render a citation: the first command below. Read the selected collection: the second. Build context for model analysis: the third, which can include notes and links.

  • Keys are case-sensitive item identifiers from your library; replace <item-key> with a real key
cli-anything-zotero item citation <item-key> --style apa --locale en-US --json cli-anything-zotero collection use-selected --json cli-anything-zotero item context <item-key> --include-notes --include-links --json

Know the limits and safety notes

The skill runs scripts on your computer. It does not use the network, according to the skill's listing. Read the commands the agent proposes before you approve them if you are unsure.

Experimental SQLite write commands are local-only and user-library-only, and should be treated as non-stable power-user operations. They may corrupt or alter data if misused. Attaching files to existing items is out of scope. Attachments can only be imported for items created in the same connector session.

If a bare item key appears in more than one library, set the library with session use-library before running follow-up commands.

  • Back up your Zotero library before using any experimental write command
  • Do not expect bulk edits to be stable
  • Existing-item file attachment is not supported
cli-anything-zotero session use-library <id>

What people use it for

  • Generate an APA bibliography for a literature review from a chosen collection
  • Pull the notes and key details from saved papers to help summarise a topic
  • Organise saved papers by listing items by tag and collection
  • Assemble structured context from a Zotero item to feed into an LLM workflow
  • Add a short key-takeaway note to an existing item

Frequently asked questions

Is cli-anything-zotero free to use?

The skill is published under the Apache-2.0 licence in the HKUDS/CLI-Anything repository. Zotero itself is a separate desktop app, so check its own terms if you need details on it.

What do I need to install before using the skill?

You need the Zotero desktop application, the Zotero Local API enabled for search, export and citation commands, and Python with pip to install the package with pip install -e .

Why does my citation command fail?

Most read and citation commands need Zotero's Local API. Enable it, keep Zotero open, and check the state with the app status command.

Can the agent edit my whole Zotero library?

Not safely. The SQLite write commands are experimental and may corrupt or alter data if misused, so they are not suited to bulk edits. Keep backups and review each change.

Can I attach PDFs to existing items with this skill?

No. The documentation says arbitrary attachment upload to existing items is out of scope. Attachments are only supported for items created in the same connector session.

How does this compare with other ways to manage citations?

The skill works through Zotero's own local interfaces and adds an agent layer on top, instead of replacing Zotero. If you only need to format citations by hand, Zotero's built-in tools may be enough; this skill is for when you want an agent to do the lookup and formatting for you.

New agent skills, repos and AI tools — every week

The best new skills and open-source projects, the fastest-growing repos, and one free prompt. Five minutes to read. Unsubscribe anytime.

Our verdict

This skill suits researchers and students who already use Zotero desktop and want an AI agent to look up items, make citations and bibliographies, or add notes, as long as the Local API is enabled. It is a poor fit if you need stable bulk edits, file attachments to existing items, or if you do not use Zotero desktop.

Download the skill