Mod avl interface

This PR will adapt the AVL interface to the layer structure laid out in issue #103.
Done, now _please_ let me squash a few things after you gave me a GO this time.