Rewrite the script for OCEF needs