Well, you've got to remember that Pompey never wanted hegemony over Rome. Sure, in his younger days he flaunted his ability to basically be the ruler of Rome without any official title or command, but in later years he calmed down. Due to Caesar's expert conquest of Gaul with few legions and in only ten years, Pompey was a bit scared of Caesar, and probably would have reconciled with him had it not been for warmongers Cato and Bibulus, who hated Caesar literally to death.
Now, if Caesar dies during or just after the battle (which Pompey wins), I see his legions yo-yoing between ending the war and joining Pompey, or following their better known commanders (like Antony, Calvinus, Decimus Junius Brutus Albinus, Gaius Trebonius, etc.) who will unite and try to continue the war at all costs, as they know that Pompey and the Senate won't be merciful.
Octavian is a complete non-entity at this point. He's a skinny 16 year-old living with his mother and stepfather in Rome; he has no political or military experience, and he isn't even preparing to join the legions yet. His success depends on whether Caesar's named him heir in his will.
A lot also depends on the masters of Rome and Italy. If whoever is in control at that time (I don't know who) is very pro-Caesar, he'll continue the fight. If he's not so concrete in his convictions and Pompey and the Senate grant him complete amnesty, he'll probably turn against his erstwhile fellow Caesarians.