 Over the next two decades, the relationship between the Liao and Song continued to deteriorate. The Liao were continuously informed of Song attempts to create military alliances with other groups sharing a border with the Liao, and minor border skirmishes were common. Beginning in 999 Emperor Shengzong of Liao led a series of campaigns against the Song that, while generally successful on the battlefield, failed to secure anything of value from the Song. This changed in 1004 when Emperor Shengzong led a campaign that rapidly worked its way to right outside of the Song capital of Kaifeng by only conquering cities that quickly folded to the Liao army, while avoiding protracted sieges of the cities that resisted heavily. Emperor Zhenzong of Song marched out and met the Liao at Chanyuan, a small city on the Yellow River. In January 1005 the two dynasties signed the Chanyuan Treaty, which stipulated that the Song would give the Liao 200,000 bolts of silk and 100,000 ounces of silver each year, that the two emperors would address each other as equals, that they would finalize the location of their disputed border, and that the two dynasties would resume cordial relations. While the sums (referred to as gifts by the Song and as tributes by the Liao) were later increased to 300,000 bolts of silk and 200,000 ounces of silver per year out of Song fears that the Liao might form a military alliance with the Western Xia, no major wars were fought between the Liao and Song for over a century following the signing of the treaty. By signing the treaty the Song dynasty functionally ceded its claim over the sixteen prefectures.
