Giter VIP home page Giter VIP logo

anki-bury-future-sibs's Introduction

anki-bury-future-sibs

anki 2.1 add-on: buries new card siblings of any cards due in the next N days

Why?

This add-on solves the problem with the following scenario: You are studying your Anki deck and a new card pops up:

Q: What is the former name of Kazakhstan's capital city Nur-Sultan? A: Astana

You study the card and learn it. Great. But, 9 days later, you get the review card:

Q: What is the capital city of Kazakhstan? A: Nur-Sultan

You immediately recall the answer; the card goes from a 100 day interval to a 250 day interval. But there's a problem! The only reason you knew this answer was because of the new card that came up last week; without that reminder, you would have (appropriately) failed this card and re-learned it.

If only the new card had been buried until after the old card was reviewed (and failed, then relearned). This add-on does just that: buries all new cards that have siblings due in the next N days.

This is ported from a personal (unreleased) Anki 2.0 add-on. Damien is dropping support for Anki 2.0 as of Jan 1, 2020. My hand is forced.

Additional behavior

You can set Anki to always show your new cards first (which of course will only those that remained unburied from the prospective bury process). This is nice if you want to get a head start on your new cards for the day while knowing that they won't "preview" any info from your due cards. This is disabled by default, but I originally had it hard coded into the add-on so I preserved the option for my own use and for anyone else who likes it.

Compatibility

Anki 2.1.15 tested. I suspect that this should work with the updated v2 experimental scheduler, but I have not tested this yet. If you are feeling brave, feel free to do so and report back to me. Legacy version for Anki 2.0 is included here if you want to manually download and install it. Ankiweb support for 2.0 ceases on Jan 1, 2020 so you can only find the legacy version here.

Default config values

These can be changed in the config file:

  • ahead: how many days ahead do you want to look? Default 21. Anki natively sets this to 0. You can go negative if for some reason you want to only consider overdue cards.
  • newsAlwaysFirst If true, the new cards will always be displayed first. Why not just set your real Anki settings to do this? Because sometimes I have to do reviews on iOS/web where thre are no add-ons. If this is the case, I want my new cards last so the siblings will at least be buried after I review any due cards. That way my new cards won't tip me off to my review card answers. Thus I have my deck set to "new cards last" but this add-on can override that when you can *prospectively * bury the new cards. Default is false because I doubt most users need this nuanced behavior.
  • shortcut: keyboard shortcut if you don't want to use the menu option (which appears under Tools).
  • onStartup: future functionality, too bug-ridden for the initial release. Eventually will allow you to have the add-on run automatically when you first open Anki each day.

Changelog:

  • v2.1.001 initial port from my personal (unreleased) Anki 2.0 add-on. onStartup disabled.

anki-bury-future-sibs's People

Contributors

rjgoif avatar

Stargazers

 avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

Forkers

rwmpelstilzchen

anki-bury-future-sibs's Issues

Does Not Work With V3 Scheduler

Title.
There doesn't seem to be any error message pop up, but this doesn't seem to be working with the version 3 scheduler. Any plans to update it? This is a very beneficial add-on for me. I could pay for your time if necessary.

Compatibility with the current version of Anki (23.10.1)

I’ve just updated Anki from 2.1.65 to ⁨23.10.1 (fac9e0e)⁩ and now the add-on doesn’t work. The debug info has this error message:

When loading bury future new sibs:
Traceback (most recent call last):
  File "/usr/lib/python3.11/site-packages/aqt/addons.py", line 245, in loadAddons
    __import__(addon.dir_name)
  File "/home/foo/.local/share/Anki2/addons21/930365039/__init__.py", line 25, in <module>
    from . import bury_ahead
  File "/home/foo/.local/share/Anki2/addons21/930365039/bury_ahead.py", line 52, in <module>
    import anki.sched
ModuleNotFoundError: No module named 'anki.sched'

Anki 2.1.45 compatibility (special case)

Hi,

Thanks for this plug-in! It has changed the way I learn new stuff with Anki and IMHO a similar option should be incorporated as a built-in feature.

I use this trick for automatic volume control.

Yesterday I have installed the new version of Anki (2.1.45) and now I get this error message when hitting shift+b:

Error 
An error occurred. Please start Anki while holding down the shift key, which will temporarily disable the add-ons you have installed. 
If the issue only occurs when add-ons are enabled, please use the Tools>Add-ons menu item to disable some add-ons and restart Anki, repeat until you discover the add-on that is causing the problem. 
When you've discovered the add-on that is causing the problem, please report the issue on the add-ons section of our support site. 
Debug info:
Anki 2.1.45 (355e66e8) Python 3.8.1 Qt 5.15.1 PyQt 5.15.1
Platform: Linux
Flags: frz=True ao=True sv=2
Add-ons, last update check: 2021-08-03 17:02:19
Add-ons possibly involved: ⁨bury future new sibs⁩

Caught exception:
Traceback (most recent call last):
  File "/home/me/.local/share/Anki2/addons21/930365039/bury_ahead.py", line 97, in buryNewSibsMenu
    conf = mw.col.decks.confForDid(did)
  File "anki/_legacy.py", line 55, in __getattr__
  File "anki/_legacy.py", line 37, in _print_warning
  File "anki/_legacy.py", line 33, in print_deprecation_warning
OSError: [Errno 5] Input/output error

If I run Anki without the said PulseAudio trick everything works fine.

Bury new siblings of learning cards with separate intervals / exclude them

Thank you so much for making this public! I wonder if I can use it in a specific way.

I have long learning steps that span over weeks (this is the rationale). Now, the problem is that, if new siblings are issued on the same day, they will have exactly parallel learning steps until they progress from "learning" to "young". So, what I want to do is automatically bury learning siblings – learning siblings of today's seen new cards, while these are still in the learning state.
What I want to avoid is burying new siblings on the day that their siblings are first seen – this would impede my learning.

For example, yesterday I saw two siblings for the first time: Kazakhstan – Nursultan and Nursultan – Kazakhstan. Both are still learning cards. Both are due today. Then today, I see the learning card Kazakhstan – Nursultan. I don't want to see the learning card Nursultan – Kazakhstan until tomorrow.

This will create sibling spacing for siblings that are both in the learning state but neither new nor young nor mature.

Additionally, I'd like to use the add-on just the way you described. With one additional feature: I'd need to postpone new card siblings of young and mature cards separately from new card siblings of learning cards. The reason for separation is that I want to use a different interval – something like 28 days for the first category, 1 day for the latter.

In my example, imagine I have a third sibling Point on Map – Nursultan. It's very old and I know it well. I see it during today's reviews. What I want is to bury both of its siblings until 28 days later.

In any case, I really want to avoid one thing: Burying new and learning siblings of a learning card for 28 days. This would be okay for vocabulary, but it's bad for the most important topics I learn because I have granular but thematically closely connected cloze notes. If it's not possible to bury siblings of learning cards separately, maybe it's possible to exclude them from burying altogether.

If it's not possible with your add-on, I'll try to figure out if I can do it with the add-on Trigger and actions: change one card depending on what occurs on another card.

I see that this is a complicated idea, so please ask for any clarification needed.

Also, I read on reddit that you're porting your other add-ons. Take your time.

Deck-specific burying

Hi, awesome add-on!

Is there any way to make the add-on not apply to certain decks or card types?

I'm wondering because I have certain cards, like anatomy for example, where one card type asks for the attachments of a muscle, and the other card type asks for the nerve supply of that muscle. I don't want one card to cause the other card to get buried when I review it. Have you come across a problem like this or do you have any ideas about how to make this work?

Thank you!

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.