Convert engine code to Many2many with tags