Skip to main content

Easily import data from a variety of formats into Anki.

Project description

Dejima - A flexible content importer for Anki

Learning a foreign language? It takes a lot of effort to make flash cards every time you find a new word you'd like to learn -- Dejima makes it possible for you to use your time more efficiently by automatically creating Anki flash cards from various sources you might be using to learn a new language including "Language Learning with Netflix".

Free Software: MIT License

Requirements

  • AnkiConnect must be installed into Anki as an add-on.

Sources Supported

  • Language Learning with Netflix
  • Reading annotations on Onyx Boox devices.
  • A source importer you write yourself -- see "Adding your own Sources" below.

You can read more about the built-in sources below.

Language Learning with Netflix (lln-json)

In "Language Learning with Netflix" (LLN), you can "save" particular words or phrases. Those phrases can be exported from LLN using your browser, and imported into Anki as flash cards.

Examples

Question:

Answer:

Reverse Question (Optional):

Reverse Answer (Optional):

How to use

  1. Download your saved annotations in "Language Learning with Netflix" using the "JSON" export type:

  1. Run dejima with the following command, replacing My Deck Name with the name of the deck you'd like the cards generated in, and /path/to/export.json with the path to the file you exported above:
dejima import "My Deck Name" lln-json -i /path/to/export.json

That's it!

Onyx Boox Reading Annotation Exports (boox)

In Onyx Boox e-readers and tablets, there's an annotation mode in which you can highlight particular words or sentences, see a translation into your native language, or write notes to yourself about:

If you, too, use these for making note of unfamiliar words, you can use Dejima to convert those highlighted annotations into flash cards.

How to use

  1. Export your saved annotations from your device and save them to the device that you are running Anki and Dejima on:

  1. Run dejima with the following command, replacing My Deck Name with the name of the deck you'd like the cards generated in, and /path/to/export.txt with the path to the file you exported above:
dejima import "My Deck Name" boox -i /path/to/export.txt

Installation

You can install dejima from pypi by running:

pip install dejima

Adding your own sources

Dejima was built to make it easy for me to easily add sources I need so hopefully that effort makes it easy for you, too!

A sample project exists at https://github.com/coddingtonbear/dejima-importer-example showing you how you might create your own importer class.

Why is this named "Dejima"

Anki is the Japanese word for "memorization". During one particular part of Japanese history, one of the few ways you could import goods into Japan was via the port of Dejima in Nagasaki.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

dejima-2.1.1.tar.gz (594.9 kB view hashes)

Uploaded Source

Built Distribution

dejima-2.1.1-py2.py3-none-any.whl (806.3 kB view hashes)

Uploaded Python 2 Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page