
一个模型上下文协议(MCP)服务器,使 AI 助手能够与 Anki(间隔重复抽认卡应用)交互。
概览
通过模型上下文协议,将Anki与AI助手无缝集成 - 该项目处于积极开发阶段。API和功能可能会发生变化。 一个模型上下文协议(MCP)服务器,使 AI 助手能够与 Anki(间隔重复抽认卡应用)交互。 用自然语言互动改变你的Anki体验——就像请私人家教一样。AI助手不仅提供问题和答案;它能解释概念,使学习过程更具吸引力和人性化,提供背景信息,并适应你的学习风格。它能实时创建和编辑笔记,将你的学习会话变成动态对话。更多功能即将推出! 如需全面指南、实际案例及逐步教程,了解如何在 Claude Desktop 中使用该 MCP 服务器,请访问: - 完整的文档,包含实际示例和用例 请参阅文档/补充文档,包括评审者设置指南和Anki样板。
概述(AI 翻译)
通过模型上下文协议,将Anki与AI助手无缝集成
[!重要] 大多数设置偏好AnkiMCP插件。
插件(GitHub)直接运行 MCP 服务器在 Anki 内部。没有安装Node.js,没有 AnkiConnect 需要配置,也没有独立进程需要持续运行:用代码
124672614安装,重启 Anki,每次 Anki 打开时服务器就会启动。它涵盖了本地 HTTP 访问和通过内置隧道远程访问。当您需要以下工具时,这个仓库是正确的选择:
- STDIO 传输 — Claude Desktop、Claude Code、Cursor,或任何将服务器作为子进程生成的客户端
- MCPB 捆绑包 — Claude Desktop 的一键安装
.mcpb对于 HTTP、隧道或基于网页的客户端(claude.ai、ChatGPT 等),插件是更简单且支持更好的路径。
这个仓库没有被弃用。它会与插件一起维护并发布,作为同一 ankimcp.ai 项目的一部分。
一个模型上下文协议(MCP)服务器,使 AI 助手能够与 Anki(间隔重复抽认卡应用)交互。
本页由 AI 翻译,技术细节请以原文为准。
README
以下为原文 README 节选,完整内容请查看原文。
Anki MCP Server
[!IMPORTANT] Prefer the AnkiMCP addon for most setups.
The addon (GitHub) runs the MCP server directly inside Anki. There is no Node.js to install, no AnkiConnect to configure, no separate process to keep running: install it with code
124672614, restart Anki, and the server is up every time Anki opens. It covers local HTTP access and remote access through a built-in tunnel.This repository is the right choice when you specifically need:
- STDIO transport — Claude Desktop, Claude Code, Cursor, or any client that spawns the server as a subprocess
- MCPB bundle — the one-click
.mcpbinstall for Claude DesktopFor HTTP, tunnel, or web-based clients (claude.ai, ChatGPT), the addon is the simpler and better-supported path.
This repo is not being deprecated. It stays maintained and released alongside the addon as part of the same ankimcp.ai project.
A Model Context Protocol (MCP) server that enables AI assistants to interact with Anki, the spaced repetition flashcard application.
Transform your Anki experience with natural language interaction - like having a private tutor. The AI assistant doesn’t just present questions and answers; it can explain concepts, make the learning process more engaging and human-like, provide context, and adapt to your learning style. It can create and edit notes on the fly, turning your study sessions into dynamic conversations. More features coming soon!
Examples and Tutorials
For comprehensive guides, real-world examples, and step-by-step tutorials on using this MCP server with Claude Desktop, visit:
ankimcp.ai - Complete documentation with practical examples and use cases
See docs/ for supplementary documentation, including the reviewer setup guide and the sample Anki deck.
Example Use Cases
Three representative prompts showing the tool flows this server enables:
- “Help me review my Spanish deck.” — The assistant offers to sync with AnkiWeb (
sync), fetches due cards (get_due_cardswith deck filter), presents each card (present_card), and records your rating (rate_card). Natural study conversation with explanations tailored to you.
安装
npx -y @ankimcp/anki-mcp-server --stdio配置
{
"mcpServers": {
"anki-mcp": {
"command": "npx",
"args": ["-y", "@ankimcp/anki-mcp-server", "--stdio"],
"env": {
"ANKI_CONNECT_URL": "http://localhost:8765"
}
}
}
}