add doc in typeclass, update some vars