Implementing card linking (I'm open to contributing)

I was interested in potentially implementing an anki add-on for card linking, but I wanted to get your feedback so I have a sense of how difficult it would be. I only have python background though, I think rust would be higher activation energy for me.

So I noticed the FAQ mentions linking cards is not a great idea, due to the extra complexity of inputting cards, and possible under/over-scheduling. I appreciate these difficulties, but… I still think this is a very important feature for spaced repetition systems to get right for use with technical/conceptual material.

I’ve been using anki for a wide variety of subjects for the past several years during my neuroscience PhD – coding, math, biology. It’s been invaluable for me, but I feel like there’s a bit of a hole many people mention, which is that having flashcards being so disjointed can rob you of the context needed for technical cards to sink into your brain. I think having a scheduler that could modify the review status of all cards of topic X after you have forgotten one card in topic X would help address that. Not necessarily abruptly set everything in topic X to forgotten, but to modify it somewhat. And IMO, if you already remember some cards, then re-reviewing them again is very low-time/low-cost.

So I was wondering:

A) Is it possible for me to primarily implement such an add-on in python? Or is this something that would just have to be in Rust, due to the large amount of interfacing with the Rust back-end that would be needed?

B) I’m comfortable with just requiring the users to manually specify the links (but I wouldn’t require this at note input time), but are there any fundamental technical difficulties in implementing a system like this?

I understand the concern raised in the FAQ about potential under/over-scheduling of coupled cards, but… I think personally it could be a cost worth paying for some subjects in return for greater context during reviews.

2 Likes

There might be a way to achieve this with tags, especially the hierarchical ones. But it could become a rabbit-hole of multiple ways to point at various cards as having a single hierarchy or graph of cards linked is impossible in many forms of knowledge.

Tags seems totally fine to me, even if they’re not hierarchical. Maybe it’s possible to have “hidden” tags so that these connections don’t also mix up the usual tags that people want to use.

I was thinking I might try to implement this in an older version of anki that uses python, and hope porting it to rust is easier…? Idk.

It’s not a feature I think belongs in the core code at this time, but you should be able to accomplish it with an add-on - you can just hook into the review process and reschedule the other cards after the review is done.