Skip to main content
Glama

Latest release CI MIT License Python 3.12+ Model Context Protocol Works with Claude

About the project

AnkiPlus in Claude Desktop

You've just sat through a two-hour lecture with 80 slides. Making good cards from it takes another evening: finding what your existing deck already covers, writing clozes for the gaps, cropping diagrams, hiding labels for image occlusion, then fixing the cards that came out wrong.

AnkiPlus hands the mechanical part of that to Claude. Point Claude at a lecture PDF and ask for cards in plain English. AnkiPlus gives Claude the tools to read the slides, pull out the diagrams, read their labels, build image occlusions, check formatting and show you exactly how each card will look. Claude writes the questions; you look at the previews and decide what goes into Anki.

Why students use it:

  • Nothing reaches Anki without your OK. You see front and back previews of every card first, and Claude asks before it changes your collection.

  • Reuse before you write. Claude can check which of your existing cards (AnKing or your own) already cover the lecture, and only draft the gaps.

  • Diagrams become image-occlusion cards. Labels are read automatically with a built-in OCR model; nothing else to install.

  • Your files stay yours. AnkiPlus runs on your computer, reads only the lecture folders you choose, and never edits the originals.

  • One install, automatic updates. A Claude plugin that brings the server and its card-writing skill together in Claude Code, or a Claude Desktop extension plus the skill from the same plugin marketplace.

NOTE

AnkiPlus is an MCP server: a set of tools that Claude uses. It has no window or chat of its own. You talk to Claude as usual, and Claude decides when to use AnkiPlus.

What it does

Your study task

What AnkiPlus gives Claude

Make cards from a lecture

The slide text, slide numbers, figures and learning objectives to draft from.

Reuse cards you already have

Lecture material and previews so Claude can compare your existing Anki cards with the lecture, then draft only the gaps.

Learn a labelled diagram

Label positions read by OCR, and image-occlusion masks that hide them for recall.

See how cards will look

Front/back images, and contact sheets with many card previews on one image.

Improve an existing deck

Local copies, formatting checks, suggested edits and a before/after preview.

Know what you've missed

Optional checks against the slides and objectives, with a note of anything left out on purpose.

Get cards into Anki

Checked add/update requests and media, ready for the Anki connector to apply.

A cloze hides part of a sentence: "The {{c1::sinoatrial node}} sets the heart rate." An image occlusion hides part of a diagram. A workspace is a local folder that holds one task's lecture copy, cards, previews and results, so Claude can pick up where you left off.

How it fits together

flowchart LR
    You([You]) -- "study task in plain English" --> Claude
    Claude -- "read slides, OCR, previews, checks" --> AnkiPlus[AnkiPlus MCP<br/>on your computer]
    AnkiPlus -- "your lecture folders (read-only)" --> PDFs[(Lecture PDFs)]
    Claude -- "approved adds and edits" --> AnkiMCP[Anki connector<br/>e.g. AnkiMCP]
    AnkiMCP --> Anki[(Your Anki<br/>collection)]

Part

Its job

You

Choose what to learn, look at the cards, approve changes.

Claude

Understand the lecture, write the questions, choose which tools to use.

AnkiPlus

The mechanical work: reading PDFs, OCR, masks, checks, previews, preparing changes.

An Anki connector

Search your collection and apply the changes you approved.

AnkiPlus never connects to Anki itself, so it can't change your collection by accident. Claude reaches Anki through a separate connector such as AnkiMCP; see Connect Anki.

Built with

  • Python

  • MCP Python SDK

  • PyMuPDF for lecture PDFs

  • OCRia-nano-1 (via liteparse) for diagram labels

  • Playwright for card previews

  • Pillow for images and masks

  • Node.js for the dependency-free installer

  • uv for the private Python environment

Related MCP server: Mousetail

Getting started

TIP

New to this? Follow the student guide. It takes about 15 minutes, most of it waiting for a download, and needs no coding.

Prerequisites

  • A Mac with Claude Desktop (or Claude Code if you already use it). Linux works; Windows should work but hasn't been tested yet.

  • Anki, open while you work.

  • Google Chrome for card previews (or run setup once to get a private Chromium).

  • An internet connection the first time: AnkiPlus downloads about 500 MB of components on first start, then works offline. The OCR model (about 72 MB) downloads the first time you read a diagram.

Install in Claude Desktop (no terminal)

  1. Download ankiplusmcp-<version>.mcpb from the latest release.

  2. In Claude Desktop, open Settings → Extensions, drag the file in and click Install.

  3. When asked for Lecture folders, pick the folders that hold your lecture PDFs. AnkiPlus can read only these, and never changes them.

  4. Quit Claude Desktop fully and reopen it. Give the first start a few minutes.

  1. Add the companion skill, which teaches Claude how to write good cards: open Customize → Plugins, choose Add → Add marketplace, enter Hamza-Xoho/ankiplusMCP, then install AnkiPlus skill. Turn on Sync automatically for that marketplace and the skill stays up to date by itself. It also reaches Claude Code and Cowork on the same account.

Install AnkiPlus skill, not the ankiplusmcp plugin, in Claude Desktop: the full plugin carries a second copy of the server, which chat can't run and which would show up twice in Cowork. If you skip the skill, Claude reads the same guidance from AnkiPlus when it needs it.

Install in Claude Code

With uv installed and Claude Code 2.1.275 or later, run one command, replacing ~/Lectures with your lecture folder:

claude plugin install ankiplusmcp --marketplace Hamza-Xoho/ankiplusMCP --config lecture_folders=~/Lectures

That installs the ankiplusmcp plugin: the AnkiPlus server and its companion skill together. Restart Claude Code (or run /reload-plugins). The first start downloads about 500 MB, so give it a few minutes; if /mcp shows AnkiPlus as failed, wait a minute and reconnect it there.

  • More folders: separate them with commas, --config "lecture_folders=~/Lectures,~/My Drive/BMC". Leave the option out to let AnkiPlus read the folder Claude Code is working in.

  • Textbooks: add --config books_folders=~/Books.

  • Change them later: /plugin configure ankiplusmcp@ankiplusmcp.

  • Inside Claude Code instead: /plugin marketplace add Hamza-Xoho/ankiplusMCP, then /plugin install ankiplusmcp@ankiplusmcp, which asks for the folders.

If you installed AnkiPlus with npx ... init before, remove that copy first so Claude Code doesn't run two servers: npx -y github:Hamza-Xoho/ankiplusMCP#semver:x uninstall --host claude-code.

init remains the installer for other hosts: --host accepts claude-desktop, codex, opencode and hermes (it needs Node.js 18+ and uv); see setup. Two more commands help when something is missing:

npx -y github:Hamza-Xoho/ankiplusMCP#semver:x doctor   # what's missing, and the command that fixes it
npx -y github:Hamza-Xoho/ankiplusMCP#semver:x setup    # download Chromium for previews and the OCR model ahead of time

Connect Anki

AnkiPlus prepares the cards; a second connector puts them into Anki. Follow Connect Claude to Anki (about 5 minutes). Then check it worked by asking Claude:

List my Anki decks.

If Claude names your real decks, you're set.

Staying up to date

  • Claude Code (plugin): open /plugin, choose Marketplaces, select ankiplusmcp and turn on auto-update; new releases then arrive by themselves. Without it, Claude tells you when a new version is out and /plugin marketplace update ankiplusmcp fetches it.

  • Claude Code (init) and other hosts: nothing to do. AnkiPlus checks for a new release about twice a day, installs it in the background and switches over the next time you restart. To stay on one version, install with a tag and --pin, for example #v0.3.2 init --pin ....

  • Claude Desktop: the skill updates with its marketplace. For the server, Claude tells you when a new version is out. Download the new .mcpb from the latest release and install it the same way.

Update checks send only AnkiPlus's version number to GitHub. Set ANKIPLUSMCP_UPDATES=off to turn them off. Your workspaces are kept between versions. Installs from before 0.3.2 need to run init once more to start updating themselves.

Usage

You don't type commands. Ask Claude in your own words; here are prompts that work well. Claude asks before changing Anki, and when you're done, sync Anki.

Make cards from a lecture

Use AnkiPlus to read cardiac-cycle.pdf in my lecture folder. Start with slides 2–8. Check which of my existing Anki cards already cover them, draft cloze cards only for the gaps, include slide references, and show me front/back previews before adding anything to Anki.

Reuse your existing deck and fill the gaps

Read the learning objectives in this lecture. Search my existing deck and suggest cards that already cover them. Draft new cards only for the gaps, with useful explanations and the relevant lecture image on the back. Show me every proposed card, both sides, and wait for my approval.

Learn a labelled diagram

Find the labelled diagram of the brachial plexus on slide 12. Read its labels and propose masks for the main structures. Show me the mask preview before saving image-occlusion cards.

Fix cards that aren't working

Fetch my cards tagged #cardio, show me how they look, suggest clearer wording and better Extras, and show the before/after before applying anything.

Check what you missed

Compare the draft cards with the lecture's learning objectives. List the gaps, and note any slides we deliberately left out with a reason for each.

Pick up where you left off

List my AnkiPlus workspaces, reopen the cardiac cycle one and show me the saved cards and the latest report.

A typical lecture looks like this. It's an example, not a fixed pipeline: ask for one diagram, a few slides or a whole lecture.

flowchart TD
    A[Read the lecture and its objectives] --> B[Compare with your existing Anki cards]
    B --> C[Pick existing cards to reuse]
    B --> D[Draft cards for the gaps and diagram masks]
    C --> E[Preview everything, both sides]
    D --> E
    E --> F{Approve?}
    F -->|Revise| R[Fix drafts and preview again]
    R --> E
    F -->|Yes| G[Claude adds or unsuspends through the Anki connector]
    G --> H[Claude checks the result; you sync Anki]
IMPORTANT

Claude can make mistakes, in card content and in matching existing cards. The formatting and coverage checks catch structural problems, not wrong facts. Read the previews before you approve.

For the full walk-through, see the worked study workflow.

Tools

AnkiPlus gives Claude 41 tools. You never call them yourself, but here's what Claude is working with:

Group

Tools

Setup and workspaces

capabilities, get_guidance, create_workspace, list_workspaces, get_workspace

Lecture text and figures

extract_source, read_source, search_source, get_page_image, list_figures, get_figure, export_figures

Textbook library

library_status, save_library_settings, start_overnight_reading, library_map, search_library, read_section, list_book_figures, get_book_figure

Images and occlusions

import_image, ocr_image, build_occlusion

Cards and targets

resolve_target, save_cards, get_cards, save_omissions, check_cards, render_cards

Optional review

prepare_review, submit_review, apply_changes

Anki handoff and reporting

prepare_write, record_external_results, get_report

Artifacts, jobs and diagnostics

list_artifacts, read_artifact, get_image, get_job, cancel_job, measure_usage

The tool reference covers each tool's inputs, results and limits (500 PDF pages, 500 cards per workspace, 64 MiB files, 20 million image pixels). AnkiPlus speaks MCP over stdio, opens no network port and needs no API key of its own.

Documentation

Guide

For

Student guide

Installing in Claude Desktop or Claude Code, first prompt, troubleshooting.

Connect Claude to Anki

The second connector that reads and changes your collection.

Worked study workflow

Reusing cards, drafting gaps, reviewing and approving, step by step.

Setup and troubleshooting

Other hosts, preview browser, folders, profiles, updates, offline use.

Tool reference

Every tool's inputs, results, prerequisites and errors.

Companion skill

How Claude should choose, write and review cards.

Developer guide

Architecture, testing and releases.

Documentation index

Everything else, including legacy and development records.

Roadmap

  • Independent MCP tools for extraction, OCR, occlusion, checks and previews

  • One-command init for Claude Code, Claude Desktop, Codex, opencode and Hermes

  • One-click Claude Desktop extension (.mcpb)

  • Built-in OCR model (OCRia-nano-1), no Tesseract or Homebrew needed

  • Automatic releases and self-updating installs

  • Real screenshots and a short demo video

  • Tested on Windows

  • Verified end to end on Codex, opencode and Hermes

  • Update the Claude Desktop extension in place, when Claude Desktop allows it

See the open issues for proposed features and known problems.

Contributing

Contributions are very welcome, and you don't need to write code to help: telling us what went wrong during install, or which prompts gave you bad cards, is just as useful. Open an issue with what you tried.

To contribute code:

  1. Fork the project

  2. Create a branch (git checkout -b feature/better-masks)

  3. Set up and run the checks:

    python3 -m venv .venv
    .venv/bin/pip install -e '.[dev]'
    .venv/bin/python -m playwright install chromium
    ./scripts/check.sh
  4. Commit your changes and add a line under ## Unreleased in CHANGELOG.md

  5. Push the branch and open a pull request

You'll need Python 3.12+ and Node 18+. The server is in src/ankiplusmcp/ and the installer in launcher/. Releases are published automatically when a change merges to main. The developer guide covers the architecture, tests and release process; AGENTS.md lists the rules for AI coding agents working on the repo.

License

Distributed under the MIT License. See LICENSE for details.

PyMuPDF, a dependency, is AGPL-licensed (commercial licences are sold separately), and the OCRia-nano-1 model is free for personal use and research; see the licence notes.

Contact

Hamza (@Hamza-Xoho): questions, bugs and ideas are best as a GitHub issue.

Project link: https://github.com/Hamza-Xoho/ankiplusMCP

Acknowledgments

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      A
      quality
      D
      maintenance
      Enables safe, review-first Anki authoring with tools to inspect structure, create note types, add notes, preview renderings, and manage cards via AnkiConnect.
      16
      11 npm
      MIT
    • A
      license
      Not graded
      quality
      D
      maintenance
      A headless, sync-native Anki MCP sidecar that lets AI agents safely manage a real Anki collection without Anki Desktop or AnkiConnect, supporting sync with AnkiWeb or self-hosted servers.
      1
      MIT