Moved the implementation of Notebook to Tags, Fixed Identation issue
Refactored code, removed unused variables