Implement categories

It will close #28