OUAGADOUGOU, Burkina Faso (AP) — The nation of Mali, which lost half its territory last year to rebels, has agreed to sign an accord with Tuareg separatists who still control the country's northernmost province, officials said Tuesday.

The agreement is to be signed Tuesday afternoon in Ouagadougou, the capital of Burkina Faso, where the two sides have been holding talks, according to a statement from the communications office of Burkina Faso's presidential palace. Once signed, the proposed agreement will remove the last major obstacle ahead of Mali's planned presidential election in July and will put in place a process through which Mali's military will be able to return to Kidal, the capital of the occupied province in northern Mali which has become a de facto Tuareg state.

Malian politician Tiebile Drame, who is representing the government of Mali at the talks, said that the toughest part of the negotiations is behind them.

"I think we can say that the biggest task is finished. We have agreed on the essentials. There is an international consensus as well as a Malian consensus on the fundamental questions, which include the integrity of our territory, national unity, and the secular and republican nature of our state," he said.

According to Drame, the rebel National Movement for the Liberation of the Azawad, or NMLA, had agreed that Malian would exercise its sovereignty "over every centimeter of its territory" and that the Malian military will be allowed to return to Kidal.

Moussa Ag Attaher, a spokesman for the NMLA said that the Tuareg separatists are on board: "The NMLA and the High Council for the Azawad have given everything for peace and so we accept this accord."

It's unclear how quickly Mali's army will be allowed to return to Kidal, and whether they will do so gradually, over an extended period of time, as the rebels had demanded. The talks had reached an impasse last week over a number of issues including the speed of the army's deployment, and whether or not rebels who committed atrocities during the invasion would face trial.

Story continues

The traditionally nomadic Tuareg people, who consider northern Mali their hereditary homeland, have long agitated for their own nation. To that end, Tuareg rebels have picked up arms against the state numerous times going back to the 1960s. The NMLA, founded in late 2011, is the most recent movement claiming greater autonomy for Mali's Tuaregs. They began inching into northern Mali in early 2012, taking a string of small towns and villages.

After an unexpected coup in Mali's distant capital of Bamako in March of 2012, they took advantage of the ensuing chaos to push into the major cities in the north, taking Kidal, Timbuktu and Gao in the seizure of what amounted to a France-sized territory.

But on their coattails came a trio of rebel groups allied with al-Qaida, and within weeks the jihadists had yanked down the NMLA flags and replaced it with their own dark symbol, proclaiming that the only God is Allah. The Islamic extremists set to work creating their own Islamic state, imposing Shariah rule, flogging women for dressing immodestly, shuttering bars and discotheques, and banning music and soccer. In punishments that shocked the normally moderate Islamic nation, they amputated the hands of over a dozen thieves, sentenced to death one accused murderer who was publicly shot and stoned to death an adulterous couple.

In January, France scrambled fighter jets over Mali in order to beat the Islamic radicals back, flushing out the extremists from the three major towns in the north. While the Malian army was quickly able to return to Timbuktu and Gao, they did not immediately return to Kidal, a Tuareg stronghold. The French are accused of standing by and allowing the NMLA to re-enter Kidal, where they quickly established a shadow administration.

As the Malian military advanced on Kidal last month, many feared a clash. The hastily-convened talks in Ouagadougou aimed to avoid a direct confrontation.

___

Callimachi contributed to this report from Dakar, Senegal. Associated Press writer Baba Ahmed also contributed to this report from Bamako, Mali.