small changes

small changes, added count for attributes, changed a few things, added a
few todos and stuff like this...