Reworked the code and updated docs
updated docs