qnli question: Who painted their mansions red during the Song and Tang dynasties? sentence: When the Manchu rulers of the Qing Dynasty conquered the Ming and took over the Forbidden City and Imperial Palace in Beijing, all the walls, gates, beams and pillars were painted in red and gold.