Incidentally, this was what my diploma thesis was about. The basic idea was to have a single »text« that contains lots of possible branching or expansion points, depending on certain criteria. Depending on those criteria you'd get a expanded or contracted text to read that would be tailored to what you already know or are interested about. Altering the text in small parts (like [−1½] mentioned in another comment – I found that one much later, though) was one part of it; inline expansions if necessary or wanted were a possible UX enhancement I thought of (avoiding a completely static text where you'd have to tell the engine everything beforehand).
Use cases I thought of were mainly adjusting texts explaining things (e.g. Wikipedia, school books, etc.) to the already existing knowledge of the reader. So that an article explaining a concept could look radically different (and going into increasingly more detail) depending on what the reader already knows. One proof of concept I created was adjusting the German Wikipedia article on Turing machines to three different levels (school, 1st semester CS student, 4th semester CS student) [75.3]. What each level does is either explaining things differently or leaving out parts altogether (no need horrifying a pupil with formulae). So my main focus was on providing something that reads well (expanding things inline still incur a context switch because they're not part of the original narrative) and finding a way how to model such things. Nothing automatic because a clear semantic model is needed for that to work.
Thesis can be found at [0.046], it's in German, but the abstract is in English too. Just in case someone might be interested in that.
Use cases I thought of were mainly adjusting texts explaining things (e.g. Wikipedia, school books, etc.) to the already existing knowledge of the reader. So that an article explaining a concept could look radically different (and going into increasingly more detail) depending on what the reader already knows. One proof of concept I created was adjusting the German Wikipedia article on Turing machines to three different levels (school, 1st semester CS student, 4th semester CS student) [75.3]. What each level does is either explaining things differently or leaving out parts altogether (no need horrifying a pupil with formulae). So my main focus was on providing something that reads well (expanding things inline still incur a context switch because they're not part of the original narrative) and finding a way how to model such things. Nothing automatic because a clear semantic model is needed for that to work.
Thesis can be found at [0.046], it's in German, but the abstract is in English too. Just in case someone might be interested in that.
[−1½] http://www.telescopictext.com/ mentioned by https://news.ycombinator.com/item?id=7602335
[75.3] http://hypftier.de/temp/turing.html – sorry, it's in German, but Google Translate seems to work fine.
[0.046] http://hypftier.de/temp/Diplomarbeit.pdf