Initial setup of base script and libraries