emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
* Drill mode for org-learn
@ 2010-07-30  5:26 Paul Sexton
  2010-07-30 16:20 ` Dan Davison
  0 siblings, 1 reply; 2+ messages in thread
From: Paul Sexton @ 2010-07-30  5:26 UTC (permalink / raw)
  To: emacs-orgmode

I have nearly finished a basic "drill mode" for org-learn. It works a bit 
like Anki/Mnemosyne.

When invoked, it scans files for topics which either have the tag :question:,
or have the LEARN_DATA property (set by org-learn), and which are either 
unscheduled (ie new) or are not scheduled in the future.

It shuffles them, picks a random subset if 
'org-learn-maximum-items-per-drill-session' is set, and presents them one
by one. The user presses a key, then presses a key 0-5 to rate their 
recall. 'org-smart-reschedule' is called for every reviewed item at the
end of the test.

Example topics which it understands:

1. The body under the heading tagged :question: is shown, with the :back: 
(ie "back of the card") subsection hidden.

* Greeting Q1                                   :question:
What is your name? (informal)
** Answer                                           :back:
¿Cómo te llamas?

2. A card with both a front and a back. One side will be shown at random, 
with the other hidden.

* Noun                                          :question:
** Front                                           :front:
el gato
** Back                                             :back:
the cat

3. Cloze deletion. Text within SINGLE square brackets is obscured
with a special font.

* Grammar rule                                  :question:
To form an adverb from an adjective, add [-mente] to 
the [feminine] (gender) form of the adjective.

I have a slight problem however. I don't know how to "record" headings so I
can revisit them later. I need something like:

(org-map-entries
  (lambda () (push (org-save-this-heading) headings))
  "" files)

(dolist (heading headings)
   (jump-to-heading heading)
   ...)

Saving the buffer position does not work because each call to
org-smart-reschedule alters the contents of the buffer.

If/when I solve this problem, I should be able to release this code. 

Paul

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2010-07-30 16:20 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-07-30  5:26 Drill mode for org-learn Paul Sexton
2010-07-30 16:20 ` Dan Davison

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).