added more comments to library script