Autoregressive Cloze + Image Occlusion

AnkiWeb addon 1803356728

Creates and manages three note types that reveal cloze blanks and image-occlusion masks one by one per spacebar press, including combined cards, with automatic debug dumps.
AI-generated summary; may contain mistakes.

review-flowcard-templatesclozeimage-occlusiondeveloper-tools

Open on AnkiWeb GitHub Find alternatives

AnkiWeb

Votes
0 (πŸ‘ 0 Β· πŸ‘Ž 0)
Updated
2026-04-29
Anki versions
25.09.2~
License
AGPL-3.0 (from the license file in the package)
Virus scan
No ClamAV match A match does not prove malware. No match does not prove that the code is safe.
Languages
JavaScript, Python, JSON
Description language
en

Maintenance

stale

  • Last update or commit: 2026-04-29 (186 days before the snapshot).
  • Commits in the last year: 13.
  • Issues: 0 open, 0 closed.
  • Pull requests: 0 open, 0 merged.

Will it work on my Anki?

Version branches
Min AnkiMax AnkiUpdated
25.09.2+2026-04-29
History across monthly snapshots

Loading…

Similar addons

Cloze (Hide All)

Creates a cloze card type that hides all clozes except the one being reviewed in yellow boxes, with conditional reveal rules and a toggle mask button.

card-templatescloze

93 votes 73% approval πŸ‘ 76 Β· πŸ‘Ž 17 ⭐ 14 Updated 2026-05-10

Description

Autoregressive Cloze + Image Occlusion

Single Anki add-on package that creates and manages three note types:

  1. Autoregressive Cloze
  2. Autoregressive Image Occlusion
  3. Autoregressive Cloze + Image Occlusion

Check the source code here.

Reveal behavior

1. Autoregressive Cloze

Pressing the space bar reveals the current card's cloze blanks one by one, left-to-right. When the last blank is revealed, the answer is shown immediately.

2. Autoregressive Image Occlusion

Pressing the space bar reveals the current card's image masks one by one. Reveal order is top-to-bottom, then left-to-right, with ordinal respected first to match Anki's shape grouping. When the last mask is revealed, the answer is shown immediately.

3. Autoregressive Cloze + Image Occlusion

This note type is built on top of Image Occulsion, with four extra text fields:

  1. Text Before
  2. Cloze Before
  3. Text After
  4. Cloze After

Reveal order on each space bar press:

  1. Cloze Before blanks for the current card's cloze number, left-to-right
  2. Image occlusion masks for the current card's cloze number, top-to-bottom then left-to-right
  3. Cloze After blanks for the current card's cloze number, left-to-right

When the last item is revealed, the answer is shown immediately.

Note type creation

On profile open, the add-on creates the three note types automatically if possible.

If the note types were not created automatically, run:

Tools -> Setup 'Autoregressive Cloze + Image Occlusion' Note Types

Automatic debug dumps

For the three autoregressive note types, the add-on automatically writes reviewer dumps at:

  1. question shown
  2. every reveal step
  3. immediately before the answer is shown

Dump files are stored in:

/tmp/anki-arcio-dumps/cloze.json /tmp/anki-arcio-dumps/image-occlusion.json /tmp/anki-arcio-dumps/combined.json

Each file always contains only the most recently visited card for that note type, so at most three card dumps exist at the same time. The dump includes reveal state, rendered cloze spans, hidden image-occlusion masks, current IO setup config, and the question-side HTML snapshot.

Important setup note

Anki only creates its stock Image Occlusion note type after you use Image Occlusion at least once. If Autoregressive Image Occlusion or Autoregressive Cloze + Image Occlusion is missing, first create one stock Image Occlusion note in Anki, then run the setup action again.

README

Autoregressive Cloze + Image Occlusion

Single Anki add-on package that creates and manages three note types:

  1. Autoregressive Cloze
  2. Autoregressive Image Occlusion
  3. Autoregressive Cloze + Image Occlusion

The package is self-contained: note type creation, reviewer hooks, reveal order, and debugging all live in this repo.

Reveal behavior

1. Autoregressive Cloze

Pressing the space bar reveals the current card's cloze blanks one by one, left-to-right. When the last blank is revealed, the answer is shown immediately.

2. Autoregressive Image Occlusion

Pressing the space bar reveals the current card's image masks one by one. Reveal order is top-to-bottom, then left-to-right, with ordinal respected first to match Anki's shape grouping. When the last mask is revealed, the answer is shown immediately.

3. Autoregressive Cloze + Image Occlusion

This note type is built on top of Image Occulsion, with four extra text fields:

  1. Text Before
  2. Cloze Before
  3. Text After
  4. Cloze After

Reveal order on each space bar press:

  1. Cloze Before blanks for the current card's cloze number, left-to-right
  2. Image occlusion masks for the current card's cloze number, top-to-bottom then left-to-right
  3. Cloze After blanks for the current card's cloze number, left-to-right

When the last item is revealed, the answer is shown immediately.

Cards are generated by the image occlusion engine β€” one card per shape. The cloze number in Cloze Before/Cloze After is matched to the card by ordinal: c1 is active on the first shape's card, c2 on the second, and so on. If there are more cloze numbers than shapes, the excess cloze deletions will never appear as active blanks on any card.

Note type creation

On profile open, the add-on creates the three note types automatically if possible.

If the note types were not created automatically, run:

Tools -> Setup 'Autoregressive Cloze + Image Occlusion' Note Types

Automatic debug dumps

For the three autoregressive note types, the add-on automatically writes reviewer dumps at:

  1. question shown
  2. every reveal step
  3. immediately before the answer is shown

Dump files are stored in:

/tmp/anki-arcio-dumps/cloze.json /tmp/anki-arcio-dumps/image-occlusion.json /tmp/anki-arcio-dumps/combined.json

Each file always contains only the most recently visited card for that note type, so at most three card dumps exist at the same time. The dump includes reveal state, rendered cloze spans, hidden image-occlusion masks, current IO setup config, and the question-side HTML snapshot.

Important setup note

Anki only creates its stock Image Occlusion note type after you use Image Occlusion at least once. If Autoregressive Image Occlusion or Autoregressive Cloze + Image Occlusion is missing, first create one stock Image Occlusion note in Anki, then run the setup action again.