You will get this achievement for just initiating the fight but this guide will show you how to win aswell for the other achievements.
I started off by raiding the islands and normal pirate ships then I thought lets see what these legendary pirates are all about. So I moved from island to island to pirate boat to cities and nothing. Then I noticed you can move around the entire map even the bits that are not uncovered and the 4 legendary ships are all there, but the level is 1000! There may be a way to lower this but I wasn't really wanting to waste more time after I found this way.
So I went in all my crew except one got murdered but I found a neat little glitch to win easily.
You should have at 40-50 vitality
and the rest in dexterity
. Then you need pistol, I used the flintlock pistol but it may work with the mini pistol and you could potentially do it without a pistol but it would take longer. You also must have your player know how to swim!
Anyway, start up any of the four legendary ships. Don't worry about a crew they aren't any help. Head over to the ship and get the attention of the many pirates. Gather them all right next to where you can move back to your own boat, they will attack you but with 50 vitality I was healing quicker than they could damage me. Then walk up and grapple back to your boat and you should notice one or more pirates climb up to the raised block you grapple from. Now if you hold the left stick right while you are on the rope it will just instantly teleport you back to the ship among the pirates and sometimes one who clmbed up will just fall into the water and die but you can then ram the A button and hold aim up to any still there and try shoot them off. It won't work everytime but if you just keep doing this you can clear them all in about 10-15 mins once you get the hang of it. Once you get down to the final few you can just shoot them to death but it will take a minute or two.
Hope this helps and please ask if you need a hand.
Managed to get the clip up! Here it is...