Political parties in Egypt have agreed on how to select the panel that will write the country's new constitution, ending weeks of deadlock.
The deal was reached after talks between representatives of 22 political parties and military ruler Hussein Tantawi, officials said.
Panel members from the parliament are expected to be elected next week.
The previous panel was dissolved after liberals and secularists walked out, saying it was dominated by Islamists.
The 100-member body will include a range of politicians, members of the army, the police, the judiciary and trade unions, as well as Muslim and Christian religious leaders.
The agreement came after the military council set a 48-hour deadline on Wednesday, threatening to propose an arrangement themselves if a deal was not reached.
According to delegates cited by AFP news agency, 39 seats will be allocated to representatives of parties in the lower house of parliament, which is dominated by Islamist parties.
Six members will be given to judges, while nine will go to experts in law, with one seat each for the armed forces, police and the justice ministry.
Thirteen seats will be given to unions, while 21 public figures chosen at a meeting on Tuesday will also be appointed.
The Cairo-based Sunni authority Al-Azhar will be given five seats and Christian churches will get four, delegates added.
The talks also concluded that any decision by the panel must be endorsed by 67% of members.
The old constitution was suspended after the former President Hosni Mubarak was overthrown last year.
Correspondents say one of the debates during the drafting process will be the extent to which it should follow the principles of Islamic law.
The new document will also determine the rights of Egypt's religious and ethnic minority groups and the balance of power between the president - previously the supreme authority - and parliament.
The last panel was suspended on 10 April amid a boycott by groups who claimed they were under-represented, including liberals, moderate Muslims and the Coptic church.
Egypt is to hold a presidential election runoff on 16-17 June, where voters will be asked to choose between Muslim Brotherhood candidate Mohammed Mursi and former Prime Minister Ahmed Shafiq.