The writing of official history under the Tʻang