added library validation