Prepare to move tagging code to separate package.
Move code to tagging package.