Add revert tpg script (draft)