A better example, and a suggestion that has been made before, is a scripting language like Kontakt has, although this may not be what the OP is suggesting.
I have suggested that such a scripting language be a part of a new Combinator, allowing all sorts of interesting note based scripting such as key switching, poly arpeggiators, intelligent/scale-based live transpose (aka "forcing all notes to a scale no matter which notes are played"), intelligent harmonization (also live), etc. :-)
Giles Reaves, aka 'selig'
Audio Illusionist, Musical Technologist
Selig Audio, LLC