Name | yanki JSON |
Version |
0.6.0
JSON |
| download |
home_page | None |
Summary | Build Anki decks from text files containing YouTube URLs. |
upload_time | 2025-08-16 22:43:52 |
maintainer | None |
docs_url | None |
author | None |
requires_python | >=3.11 |
license | None |
keywords |
anki
flashcards
|
VCS |
 |
bugtrack_url |
|
requirements |
No requirements were recorded.
|
Travis-CI |
No Travis.
|
coveralls test coverage |
No coveralls.
|
# Build [Anki] decks from text files containing YouTube URLs
Yanki makes it easy to build and maintain video flashcard decks for [Anki]. It
can use local video or image files, or it can download videos from YouTube or
any other source [yt-dlp] supports.
## Installation
You will need `ffmpeg` installed to use Yanki. On macOS, install it from
[ffmpeg.org] or with [`brew install ffmpeg`]. On Linux or Windows, try
installing [yt-dlp’s ffmpeg].
I recommend using [`uvx`] run Yanki. `uvx` is part of [uv], which can be
[installed][uv install] a number of ways, but it’s probably simplest to install
`uv` through your package manager, e.g. [`brew install uv`] on macOS.
## Quick start
Create a simple deck file, e.g. `basic.deck`, to define your flashcards:
```yaml
title: Basic ASL phrases
more: md:From [Lifeprint](https://www.lifeprint.com/)
audio: strip
https://www.youtube.com/watch?v=FHPszRvL9pg What is your name?
https://www.youtube.com/watch?v=zW8cpOVeKZ4 Are you deaf?
https://www.youtube.com/watch?v=xqKENRGkOUQ Are you a student?
```
On macOS and some Linux distributions, you can make `yanki` open Anki and start
the import of the new deck:
```
uvx yanki -v update basic.deck
```
Otherwise, you can make it build an `.apkg` and then import that into Anki:
```
uvx yanki -v build -o basic.apkg basic.deck
```
## Deck file format
There is a reference for the deck file format in [REFERENCE.adoc][].
### Examples
The [`asl/`][asl] directory contains example `.deck` files that can be used to
build a deck for the vocabulary and phrases in each [Lifeprint.com ASLU][LP]
lesson. Its [README.md][asl] briefly explains how the signs were chosen.
> ### 💡 Tip
> If you are interested in learning American Sign Language, please see Dr. Bill
Vicar’s [Lifeprint.com ASLU][LP]. These decks can help you, but they cannot
replace the Lifeprint lessons and vocabulary pages.
>
> Plus, Lifeprint is full of Dr. Bill’s humor.
## Command usage
This is a Python package that can be run with [`uvx`]. The most common usage is
probably just to build your decks and import them to Anki. That’s as simple as:
```
uvx yanki update *.deck
```
You can see all the commands and options with `--help`:
```
❯ uvx yanki --help
Usage: yanki [OPTIONS] COMMAND [ARGS]...
Build Anki decks from text files containing YouTube URLs.
Options:
-v, --verbose Be more verbose. May be passed up to 3 times.
--cache DIRECTORY Path to cache for downloads and media files.
[default: $YANKI_CACHE or ~/.cache/yanki]
--reprocess / --no-reprocess Force reprocessing videos.
-j, --concurrency INTEGER Number of ffmpeg process to run at once.
[default: $YANKI_CONCURRENCY or 4]
--version Show the version and exit.
--help Show this message and exit.
Commands:
build Build an Anki package from deck files.
list-notes List notes in deck files.
open-videos Download, process, and open video URLs.
save-flashcards Save HTML flashcard UI to a directory.
save-summary Save HTML summary of decks to a directory.
serve-flashcards Serve HTML flashcards localhost:8000.
serve-summary Serve HTML summary of deck on localhost:8000.
to-json Generate JSON version of decks.
update Update Anki from deck files.
```
## License
Unless otherwise noted, this is dual-licensed under the Apache 2 and MIT
licenses. You may choose to use either.
* [Apache License, Version 2.0](LICENSE-APACHE)
* [MIT license](LICENSE-MIT)
[Anki]: https://apps.ankiweb.net
[yt-dlp]: https://github.com/yt-dlp/yt-dlp
[ffmpeg.org]: https://www.ffmpeg.org
[`brew install ffmpeg`]: https://formulae.brew.sh/formula/ffmpeg#default
[`brew install uv`]: https://formulae.brew.sh/formula/uv#default
[yt-dlp’s ffmpeg]: https://github.com/yt-dlp/FFmpeg-Builds?tab=readme-ov-file#ffmpeg-static-auto-builds
[uv]: https://docs.astral.sh/uv/
[`uvx`]: https://docs.astral.sh/uv/guides/tools/#running-tools
[uv install]: https://docs.astral.sh/uv/getting-started/installation/
[REFERENCE.adoc]: https://github.com/danielparks/yanki/blob/v0.6.0/REFERENCE.adoc
[asl]: https://github.com/danielparks/yanki/blob/v0.6.0/asl#readme
[LP]: https://www.lifeprint.com
Raw data
{
"_id": null,
"home_page": null,
"name": "yanki",
"maintainer": null,
"docs_url": null,
"requires_python": ">=3.11",
"maintainer_email": null,
"keywords": "anki, flashcards",
"author": null,
"author_email": "Daniel Parks <oss-yanki@demonhorse.org>",
"download_url": "https://files.pythonhosted.org/packages/70/85/f7208276544066b9555ba99e48b137e6b4e46a14d503b32038181ace009e/yanki-0.6.0.tar.gz",
"platform": null,
"description": "# Build [Anki] decks from text files containing YouTube URLs\n\nYanki makes it easy to build and maintain video flashcard decks for [Anki]. It\ncan use local video or image files, or it can download videos from YouTube or\nany other source [yt-dlp] supports.\n\n## Installation\n\nYou will need `ffmpeg` installed to use Yanki. On macOS, install it from\n[ffmpeg.org] or with [`brew install ffmpeg`]. On Linux or Windows, try\ninstalling [yt-dlp\u2019s ffmpeg].\n\nI recommend using [`uvx`] run Yanki. `uvx` is part of [uv], which can be\n[installed][uv install] a number of ways, but it\u2019s probably simplest to install\n`uv` through your package manager, e.g. [`brew install uv`] on macOS.\n\n## Quick start\n\nCreate a simple deck file, e.g. `basic.deck`, to define your flashcards:\n\n```yaml\ntitle: Basic ASL phrases\nmore: md:From [Lifeprint](https://www.lifeprint.com/)\naudio: strip\n\nhttps://www.youtube.com/watch?v=FHPszRvL9pg What is your name?\nhttps://www.youtube.com/watch?v=zW8cpOVeKZ4 Are you deaf?\nhttps://www.youtube.com/watch?v=xqKENRGkOUQ Are you a student?\n```\n\nOn macOS and some Linux distributions, you can make `yanki` open Anki and start\nthe import of the new deck:\n\n```\nuvx yanki -v update basic.deck\n```\n\nOtherwise, you can make it build an `.apkg` and then import that into Anki:\n\n```\nuvx yanki -v build -o basic.apkg basic.deck\n```\n\n## Deck file format\n\nThere is a reference for the deck file format in [REFERENCE.adoc][].\n\n### Examples\n\nThe [`asl/`][asl] directory contains example `.deck` files that can be used to\nbuild a deck for the vocabulary and phrases in each [Lifeprint.com ASLU][LP]\nlesson. Its [README.md][asl] briefly explains how the signs were chosen.\n\n> ### \ud83d\udca1 Tip\n> If you are interested in learning American Sign Language, please see Dr. Bill\nVicar\u2019s [Lifeprint.com ASLU][LP]. These decks can help you, but they cannot\nreplace the Lifeprint lessons and vocabulary pages.\n>\n> Plus, Lifeprint is full of Dr. Bill\u2019s humor.\n\n## Command usage\n\nThis is a Python package that can be run with [`uvx`]. The most common usage is\nprobably just to build your decks and import them to Anki. That\u2019s as simple as:\n\n```\nuvx yanki update *.deck\n```\n\nYou can see all the commands and options with `--help`:\n\n```\n\u276f uvx yanki --help\nUsage: yanki [OPTIONS] COMMAND [ARGS]...\n\n Build Anki decks from text files containing YouTube URLs.\n\nOptions:\n -v, --verbose Be more verbose. May be passed up to 3 times.\n --cache DIRECTORY Path to cache for downloads and media files.\n [default: $YANKI_CACHE or ~/.cache/yanki]\n --reprocess / --no-reprocess Force reprocessing videos.\n -j, --concurrency INTEGER Number of ffmpeg process to run at once.\n [default: $YANKI_CONCURRENCY or 4]\n --version Show the version and exit.\n --help Show this message and exit.\n\nCommands:\n build Build an Anki package from deck files.\n list-notes List notes in deck files.\n open-videos Download, process, and open video URLs.\n save-flashcards Save HTML flashcard UI to a directory.\n save-summary Save HTML summary of decks to a directory.\n serve-flashcards Serve HTML flashcards localhost:8000.\n serve-summary Serve HTML summary of deck on localhost:8000.\n to-json Generate JSON version of decks.\n update Update Anki from deck files.\n```\n\n## License\n\nUnless otherwise noted, this is dual-licensed under the Apache 2 and MIT\nlicenses. You may choose to use either.\n\n * [Apache License, Version 2.0](LICENSE-APACHE)\n * [MIT license](LICENSE-MIT)\n\n\n\n[Anki]: https://apps.ankiweb.net\n[yt-dlp]: https://github.com/yt-dlp/yt-dlp\n[ffmpeg.org]: https://www.ffmpeg.org\n[`brew install ffmpeg`]: https://formulae.brew.sh/formula/ffmpeg#default\n[`brew install uv`]: https://formulae.brew.sh/formula/uv#default\n[yt-dlp\u2019s ffmpeg]: https://github.com/yt-dlp/FFmpeg-Builds?tab=readme-ov-file#ffmpeg-static-auto-builds\n[uv]: https://docs.astral.sh/uv/\n[`uvx`]: https://docs.astral.sh/uv/guides/tools/#running-tools\n[uv install]: https://docs.astral.sh/uv/getting-started/installation/\n[REFERENCE.adoc]: https://github.com/danielparks/yanki/blob/v0.6.0/REFERENCE.adoc\n[asl]: https://github.com/danielparks/yanki/blob/v0.6.0/asl#readme\n[LP]: https://www.lifeprint.com\n",
"bugtrack_url": null,
"license": null,
"summary": "Build Anki decks from text files containing YouTube URLs.",
"version": "0.6.0",
"project_urls": {
"ChangeLog": "https://github.com/danielparks/yanki/blob/main/CHANGELOG.md",
"Homepage": "https://github.com/danielparks/yanki",
"Issues": "https://github.com/danielparks/yanki/issues",
"Source": "https://github.com/danielparks/yanki"
},
"split_keywords": [
"anki",
" flashcards"
],
"urls": [
{
"comment_text": null,
"digests": {
"blake2b_256": "0e847f04a296a34e59bf01ffcdf3b2ecb602d029712e6a21d58697e7fe0a5a2e",
"md5": "43f9198d6f6be8210e1343fe1c4bdec5",
"sha256": "e13d21f878389acec04b1de5fb1ecce86a5b16c88dfb69fdcfe88c86126c4911"
},
"downloads": -1,
"filename": "yanki-0.6.0-py3-none-any.whl",
"has_sig": false,
"md5_digest": "43f9198d6f6be8210e1343fe1c4bdec5",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": ">=3.11",
"size": 50845,
"upload_time": "2025-08-16T22:43:49",
"upload_time_iso_8601": "2025-08-16T22:43:49.722900Z",
"url": "https://files.pythonhosted.org/packages/0e/84/7f04a296a34e59bf01ffcdf3b2ecb602d029712e6a21d58697e7fe0a5a2e/yanki-0.6.0-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": null,
"digests": {
"blake2b_256": "7085f7208276544066b9555ba99e48b137e6b4e46a14d503b32038181ace009e",
"md5": "4ce985ea4275366360788a8a7f7d1aef",
"sha256": "12e2d10329cf266803aa9f214477fef6419cd6547b67f885dece2facaa5a024f"
},
"downloads": -1,
"filename": "yanki-0.6.0.tar.gz",
"has_sig": false,
"md5_digest": "4ce985ea4275366360788a8a7f7d1aef",
"packagetype": "sdist",
"python_version": "source",
"requires_python": ">=3.11",
"size": 956986,
"upload_time": "2025-08-16T22:43:52",
"upload_time_iso_8601": "2025-08-16T22:43:52.647243Z",
"url": "https://files.pythonhosted.org/packages/70/85/f7208276544066b9555ba99e48b137e6b4e46a14d503b32038181ace009e/yanki-0.6.0.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2025-08-16 22:43:52",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "danielparks",
"github_project": "yanki",
"travis_ci": false,
"coveralls": false,
"github_actions": true,
"lcname": "yanki"
}