first version of the script and required libs