Multiple fixes to kwargs and class logic (close #30)