Human: When was the Hagia Sophia (znik) built? Assistant: 
The Hagia Sophia was built in the 6th century. It was originally built as a church, but was converted into a mosque during the Ottoman Empire. It was later converted back into a church in 1935.