Added TagDatabase class and database initialization method