This honestly reminds me of my blind fish, Bahari. We assume his blindness was caused by genetics, his lethargy and chronic SBD also. I've had him since November and haven't expected him to live near this long. He has good and bad days. Most of the time he floats near the surface (SBD) and moves occasionally. He needs to be assisted in finding his food. But sometimes he sinks to the bottom, and sometimes seems reluctant to move. He floats vertically or stands on his tail at times (a bad sign that the end is usually near as it has something to do with the swim bladder not being regulated) and also at times seems to be gilling and gasping for air. I have not been able to diagnose anything specific (he is not that old) and have decided it must be bad genetics.
It seems like your guy has been given both a good home AND good genetics. My guy has been like this for awhile. We're both expecting the end to come soon but he could hold on for quite a long time like my guy has. In clean, warm tanks with good food, all we can do is adapt to what is now their "special needs". He will go when it is his time.
You've been blessed with many years with your betta and now you've been given time to say goodbye. I know it's hard because you don't know exactly how long that is, but I know you're still doing the best you can for him. They deserve it, even if they may not have much time or (like my guy) have special needs and are unlike other bettas.
I know that some day, soon or not, both of our boys will be swimming together under the rainbow bridge. Although they can't be replaced, it will make for two new opportunities for two other fish to have good homes.