added internal documentation to the scripts