I've been turning some TFP ideas around while my brain is too cooked from the heatwave for my serious stories, so please consider:
A Mystery Bot is found out in the middle of nowhere, no clue about who he is, where he is or what he's doing. Underneath all the grime of living alone in the wilderness he's clearly a civilian frame meant to specialize into some high-skill job, so they conclude that he must be a newspark who wandered off from the hotspot. It happens every now and then and while the bot is pretty scratched up—they can't even read his serial number when they try to identify where he might be from; it appears that all the numbers have been rubbed off except for the 13 at the very end—he's in very good shape overall, so they estimate that he can't be older than a few months.
Off they send him to Iacon where he's immediately snatched up by the Archives and then goes on to live his life as expected: Orion Pax, completely ordinary archivist.
Things go down the way they do in canon: he seeks out Megatronus, first for his writings, then his friendship if he starts falling in love with the most dangerous mech he has ever met, it's only between Primus and him, finally as a primary supporter of the Decepticon movement and during the meeting with the Council, he accepts the Matrix when offered. It rebuilds him into his warrior- frame and reawakens his old memories: he has always been Optimus Prime, reduced to that small form and sunk into slumber after he gave up the Matrix eons ago as a kind of demigod retirement. He was awakened in the modern age by Primus' divine call, although if their god gave him any explicit instructions on what he was supposed to do, he can't remember (in fact, Primus trying to directly communicate with him is likely why his memory banks were wiped).
The Council was banking on the Matrix rejecting Orion, so they are predictably not thrilled by this turn of events, but what can they do? They go shouting from the rooftops that the Thirteenth Prime, an ancient and wise demigod from the dawn of their species, has been reborn. They refuse to publicly admit that a Prime was living as a rebellious little archivist before, so they treat Orion Pax as if he was dead, even publishing a eulogy to avoid any questions about why he disappeared (and maybe to slander Megatronus a little more, not so subtly blaming Orion's death on him). Between the reformat and Optimus' body language changing quite drastically (and his personality to a lesser degree) due to the memories that returned to him, he is practically unrecognizable as the same mech as Orion Pax.
What is Megatron supposed to think except that the Matrix overwrote "Orion" with "Optimus" and essentially erased his beloved friend (who he was very mad at for falling for the Council's trick, but now he's also mourning him and his grief is bigger than his anger) so he could be replaced by this ancient relic the Council can manipulate and puppeteer any way they want to?
He and Soundwave bribe their way through the city borders to attend Orion's wake. It's a singularly unpleasant experience, just the two of them surrounded by all of Orion's old friends and colleagues, most of whom blame Megatronus for getting Orion killed and feel safe in the heart of Iacon to tell him so in no uncertain terms, but it cements his impression that Orion is truly dead and has been replaced by the Prime. He was already planning on tearing down the Council, but now he also has personal vengeance to add to his motivations.
This, for understandable reasons, makes Megatron violently opposed to meeting up with Optimus to talk things through, flying into a rage every time Optimus tries to bring up Orion during their clashes, until Optimus comes to the conclusion that Megatron must have been using him all along and stops trying to resolve things peacefully altogether.
This remains the state of things until the amnesia incident. Optimus, haunted by the uncertainty of not knowing what happened in the months he spent as "Orion", arranges a private meeting to confront Megatron. He finds Megatron in a worse mood than he ever remembers seeing him (little wonder; Megatron is in mourning again and he's not one to handle that kind of emotional turmoil with grace) and during their argument he finally finds out that all this time Megatron has believed him to be a parasite that took over Orion's body. He's more convinced now than ever, since Optimus has reverted to Orion Pax in the absence of the Matrix.
Nothing gets resolved, but somewhere in his incensed shouting Megatron mentions the wake, which sticks with Optimus. After he gets away he asks Ratchet about it, because he certainly didn't know about any kind of wake or eulogy. Ratchet almost off-handedly confirms that yeah, that happened, but it was fine because only bots who weren't important enough to be in the know attended and everyone else was busy with more important things. Optimus is not usually given to dramatic gestures, but he just barely stops himself from grabbing and shaking Ratchet because why would they do that without telling him, that was a horrible idea.
This is how he learns, 4 million years too late, that the reason why he couldn't track down all his colleagues and work friends who went neutral was because they thought he was dead and they obviously wouldn't answer the summons of the demigod Autobot leader.
Oh, and also there is the not insignificant revelation that Megatron made the jump from a "violence if needed, but talk first" approach to vowing to kill "Optimus" and burn the whole world down because he wanted to avenge "Orion".
4 million years of war, all over a misunderstanding. The desolation of Cybertron and countless lives lost, all for nothing. Optimus goes from distraught to hopeful and back to distraught over this knowledge over the course of a week which may or may not confuse and greatly concern his Autobots, until he comes to a decision:
At the start of the war, he failed to get Megatron to hear him out and thus gave up on ever resolving the conflict peacefully. Now he has been handed the perfect means to tempt Megatron back to the negotiating table and make him listen. This is the first glimmer of hope he has seen since the start of the war that this conflict can end any other way than one side eradicating the other and then slowly dying out and he refuses to let this chance slip him by.