The Constitution defines what to do when elections go haywire. Those running for office don't get to rewrite the Constitution and the law after the fact to decide who wins. This is a Republic, for as long as we can keep it that way, not a feudal society.
i’m not proposing any permanent change to the constitution. however, it could take the form of a one shot amendment. the key would be mutual agreement between trump and biden— all else could follow from that in some way (leave it to lawyers).
to my mind, the question would become, would biden be willing to admit a very big problem exists with the current election? or would he try to brute force his way from a broken election process?