Qi was founded shortly after the Zhou overthrow of Shang in the 11th centuryBC. Its first marquis was Jiang Ziya, minister of King Wen and a legendary figure in Chinese culture. His family ruled Qi for several centuries before it was replaced by the Tian family in 386BC. In 221BC, Qi was the final major state annexed by Qin during its unification of China.