Anki unexpectedly refused to work, so I had to throw together a workaround.