Edit script for correct terminology
Fix issue 554 and fix other errors