The anti Gaddafi movement is just that. There rebels are made up of pro-democracy groups, maybe some Religious extremists who would like to see a stronger state, ex military officers who may wish to overthrow any fledgling government and install themselves, Communists - who knows?
The various groups will come to a head when their goal has been achieved as they did after the liberation of Iraq when rival tribal groups rediscovered their old dislike for one another. This too could happen in Libya.
Any restructuring will have t be well thought out and if they are going to have democracy then a "Provisional council" will have to be exactly that - Provisional and hold elections within a year – Not carry on like Kerenski’s Russian Provisional Government, indefinitely with out a real mandate which was ultimately one of its reasons for downfall.
As for Foreign intervention in the creation of government- I fear this must be kept at a minimal as it could be argued, quite successfully in some cases, that a puppet regime has been installed - especially if there is still a counter revolt underway. This is the main reason why NATO foot soldiers haven't been on the ground and only air support levelling the playing field. If any single state goes in and helps with the rebuilding (however noble their original aims) will be accused of moulding the new state in its own image and for its own benefit. Western aid will have to be completely in an advisory capacity, the UN would be the best bet for this rather than any individual state.
2. Removal of heirs.
If Gaddafi is caught or commits suicide then the pro Gaddafi forces will rally around his successor, whether it is Saif or one of his other sons, or even a loyal officer with similar ideals. This may either be an overt continuance of the civil war, establishing an "alpine redoubt" defence and proving a thorn in a democratic government's side OR covertly, going "Werewolf" and carrying out terrorist strikes and vengeance attacks on a new government.
All heirs must be caught or go into exile to maintain the legitimacy of any successor state.
3. Problems of War crimes.
When Nazi Germany collapsed there were many people who responsible for crimes against humanity, war crimes, taking part in the regime's oppressive nature or worked for organs of the state. Himmler had said that the Allied forces would need the SS to provide order in the post-war power vacuum and that he as their head would be needed to help with the rebuilding. Although slightly delusional he was right. Post-war it would have been impossible to arrest and try everyone who had taken part in all of the above crimes and organisations. Germany needed civil servants, Police officers, bank managers, captains of industry even soldiers. The ring leaders were indeed rounded up and executed or put in prison. However many were not. All those soldiers who were in Einsatzgruppen and police battalions, executioners in the legal system, civil servants and even the SS officer who served at Auschwitz and worked out how much a single prisoner cost the state (from arrest to Gas chamber) and the net profit for the state, was only in prison for five years before release as he was an excellent bank manager and economist!!!
When Gaddafi's regime does collapse, many people are going to get away with crimes. There is no way to avoid it. The ring leaders, including Gaddafi and his sons, top military officers, Police/ secret Police officers will be caught and face justice but many will get away with it. The day after the civil war ends people will want their streets crime free, anarchy to a minimum, a working economy etc...
These things will need to be undertaken by organs of the state that already exist.