tests and docs for multi-label and some bug fixing