In the books there's no annulment and actually not even any talk of annulment. LF is just banking on Tyrion either being dead or likely to be killed soon or too scared to ever return so their marriage is basically irrelevant.
Besides, it's harder to get an annulment in the books. It's a legal process and the High Septon and the Crown have to approve it.
In the TV series it was just "Errr... I wrote a letter and hey presto! Congrats! You're free!" even though you are a presumed conspire in Regicide and the High Septon sent people to the cells for far less
The fact that its never been questioned by anyone means its unlikely to be debunked and therefore is probably just TV Plot Bollocks in order for her to have that Ramsey storyline. I can't see any time being devoted to OMGTheAnnulementWasFakeY'all when there's only a few episodes left.
But you'd have to be blind not to see the writing on the wall. They are going to remarry or something. Or at least a promise of it.
And she basically told him flat out the way to her hand - "divided loyalties" being the problem. If that's not foreshadowing that he's ultimately going to choose the welfare of the North over Danaerys, I don't know what is. And thus proves himself trustworthy to Sansa and the marriage is a go.
I always suspected a Stark/Lannister postwar generation was a possibility, ever since they got married in the books. People said it was just an arbitrary and ultimately meaningless subplot but it seemed like a bizarre plot choice for just 3 weeks of drama, never to be mentioned again.