Implemented TAG handling