Files
anki/pylib
Luc Mcgrady db98bb675a feat: Experimental options in preferences (#5057)
<!--
Title (for the Pull Request title field at the top):
Use a short prefix so the change type is obvious. You do not need to
repeat it in the body below.

Examples:
- fix: — bugfix
- feat: — feature
- refactor: — internal change without user-facing feature
- docs: — documentation only
- chore: — tooling, CI, deps, build housekeeping
- test: — tests only
-->

## Linked issue (required)

<!-- Fixes #123 / Closes #123 / Refs #123 -->

closes #4871

## How to test (required)

Find "Labs" as a new option in the preferences

### Checklist (minimum)

- [X] I ran `./ninja check` or an equivalent relevant check locally.
- [ ] I added or updated tests when the change is non-trivial or
behavior changed.

### Details

<!-- Commands, manual steps, edge cases, and what you observed -->
I've implemented the "Labs" feature in a web-view as I presume we are
moving away from QT and
Currently these options have no function. Before we can add the
functionality we should try and come up with the pattern that we should
use to register new flags.

## UI evidence (required for visual changes; otherwise N/A)

<img width="746" height="736" alt="image"
src="https://github.com/user-attachments/assets/28c4fd28-a593-4599-b43e-c2c23881251e"
/>
<img width="746" height="736" alt="image"
src="https://github.com/user-attachments/assets/c1cd69f9-3d8d-4866-a784-030b4274b4e7"
/>

## Scope

- [X] This PR is focused on one change (no unrelated edits).
2026-07-13 16:16:42 +03:00
..
2025-06-29 14:38:35 +07:00
2025-06-27 16:10:12 +07:00

Anki

Build Status

Core Python library for Anki, the spaced repetition flashcard program.

About

Anki is a spaced repetition program that helps you remember things efficiently. This package contains the Python layer of Anki's core: it wraps the Rust backend (rslib) and exposes the primary API used by the desktop app and add-ons alike.

It provides access to:

  • Collection — open, read, and write an Anki .anki2 database
  • Notes & Cards — create, update, and query notes and cards
  • Decks & Models — manage deck configurations and note types
  • Scheduler — the FSRS/SM-2 scheduling algorithms
  • Media — media file management and sync
  • Import / Export — support for .apkg, .colpkg, and other formats
  • Sync — synchronisation with AnkiWeb
  • Hooks — event system for extending behaviour

Installation

pip install anki

Note: anki is the headless library. If you want the full desktop application, install aqt instead, which depends on this package.

Add-on development

If you are building an Anki add-on, this is the package that gives you access to the collection and scheduling internals. See the Add-on Guide for full documentation.

Contributing

Want to contribute? Check out the Contribution Guidelines and the Development Guide.

License

AGPL-3.0-or-later