Hi, sorry to hear about your problems. Try to find source of that bad noise as precisely as you can (left/right side). Last time I saw this engine with bad rattle it was broken timing chain guard:
http://www.xt660.com/showthread.php?t=25309&page=2
https://www.flickr.com/photos/andyellis161/
So I'd try opening also left side and check chain and everything what I can before removing from frame.
Good luck