Beijing on Sunday said it is “ready to work” with Southeast Asian nations on a code of conduct in the South China Sea, where it is accused of bullying fellow claimants and building up military installations.

China claims most of the resource-rich waterway, a major global shipping route and long a source of tension among claimants in Southeast Asia.

The 10-member Asean has been locked in talks for a code of conduct for the sea, where China is accused of deploying warships, arming outposts and ramming fishing vessels.

The agreement, set to be finished in 2021, will set out conduct guidelines for the sea along with conflict resolution parameters.

On Sunday, Chinese Prime Minister Li Keqiang said the first reading of the document – a chance for all members to comment on the draft terms – was “a very important landmark”.

“We stand ready to work with Asean countries building on the existing foundation and the basis to strive for new progress” on the guidelines, he said.

He added that China wanted to “maintain and uphold long-term peace and stability in the South China Sea”.

Chinese state-owned Xinhua News Agency reported Li as saying that the agreement was completed ahead of schedule, with the Chinese side proposing that the talks be completed in the next two years.

Tensions have flared in recent weeks between China and Vietnam, one of Beijing’s most vocal critics over the sea.

Hanoi hit back at China after it sent a survey ship into waters inside its Exclusive Economic Zone and around islands claimed by both Hanoi and Beijing.

The ship left after several weeks in the area.

The Philippines, Taiwan, Malaysia and Brunei also have overlapping claims with China in the sea.

The agreement would see the region develop a code of conduct for the disputed area, which has increasingly become regional flashpoint since 2015, drawing in foreign nations to intervene.

The US has accused China of bullying behaviour in the sea, and US Secretary of State Mike Pompeo said last week the US has been too easy on China.

“We hesitated and did far less than we should have,” he said, referring to China’s disputes with Vietnam and the Philippines.