Anki MCP Server

local-only server

The server can only run on the client’s local machine because it depends on local resources.

Integrations

  • Connects to a locally running Anki application through the Anki-Connect add-on, providing tools for card review and creation, including retrieving due and new cards, updating card ease ratings, and adding new flashcards.

Anki MCP サーバー

ローカルで実行されている Anki に接続し、カードのレビューと作成を提供する MCP サーバー実装。

このサーバーは、Anki デスクトップ アプリおよびAnki-Connectアドオンで動作するように設計されています。

使用する前にアドオンがインストールされていることを確認してください。

リソース

  • アンキ://search/deckcurrent
    • 現在のデッキからすべてのカードを返します
    • Ankiのdeck:currentに相当するもの
  • アンキ://search/isdue
    • 復習と学習を待っているカードを返します
    • Ankiのis:dueに相当するもの
  • アンキ://search/isnew
    • 未表示のカードをすべて返す
    • Ankiのis:newに相当するもの

ツール

  • アップデートカード
    • 指定されたカード ID のカードを回答済みとしてマークし、1 (再回答) から 4 (簡単) までの容易さスコアを付与します。
    • 入力:
      • answers (配列): cardId (数値)とease (数値)フィールドを持つオブジェクトの配列
  • カードを追加
    • デフォルトの Anki デッキに新しいカードを作成します
    • 入力:
      • front (文字列): カードの表面
      • back (文字列): カードの裏面
  • 期限切れカードを取得する
    • 現在レビューが必要なカードのn枚数を返します
    • 入力:
      • num (数字): カードの枚数
  • 新しいカードを取得する
    • 新しいカードからn枚のカードを返す
    • 入力:
      • num (数字): カードの枚数

発達

依存関係をインストールします:

npm install

サーバーを構築します。

npm run build

自動リビルドを使用した開発の場合:

npm run watch

構成

Claude Desktop で使用するには、サーバー設定を追加します。

MacOS の場合: ~/Library/Application Support/Claude/claude_desktop_config.json Windows の場合: %APPDATA%/Claude/claude_desktop_config.json

{ "mcpServers": { "anki-mcp-server": { "command": "/path/to/anki-mcp-server/build/index.js" } } }

デバッグ

MCPサーバーはstdio経由で通信するため、デバッグが困難になる場合があります。パッケージスクリプトとして提供されているMCP Inspectorの使用をお勧めします。

npm run inspector

インスペクターは、ブラウザでデバッグ ツールにアクセスするための URL を提供します。

You must be authenticated.

A
security – no known vulnerabilities
A
license - permissive license
A
quality - confirmed to work

ローカルで実行されている Anki に接続し、モデル コンテキスト プロトコルを通じてカードのレビューと作成を可能にするサーバー実装。

  1. Resources
    1. Tools
      1. Development
        1. Configuration
          1. Debugging

        Appeared in Searches

        ID: 1srmm6tbie