The founding of Chengdu is traditionally attributed to the ancient Shu Kingdom and later the State of Qin. Historical accounts suggest that in the early 4th century BC, Kaiming IX, the ninth king of the ancient Shu state, relocated his capital from Pixian to the city's current site, naming it Chengdu, which translates to "become a capital." Following the State of Qin's conquest of the Shu Kingdom in 316 BC, the Qin general Zhang Yi is credited with founding the "Chinese Chengdu" by building a new, fortified city at the same location. Zhang Yi's city was modeled after the Qin capital, Xianyang, and included protective walls that established Chengdu as a vital administrative and commercial hub. While earlier prehistoric cultures like the Jinsha and Sanxingdui inhabited the region, the formal establishment of the city under its current name and location is rooted in these successive developments by the Shu and Qin leaders.