Converted revelib functions pla format to xqs