parse labels method added