I'm porting a 28k page Wikidot wiki to mediawiki. As wikdot is case insensitive, I'm generating lots of broken links to "SF fandom" as the mediawiki page is created as "SF Fandom".

Now I could try creating case-changing redirects, but the pywikibot script capitalize_redirects doesn't do what I want, as it would create a redirect "Sf fandom", which is no use, and would create vast numbers of redirects I didn't need.

What I really need is a tool that spots a broken link "SF fandom", realises there is a page "SF Fandom" that would match if case insensitive, and changes the link to be [[SF Fandom|SF fandom]]

Does such a script exist? With so many pages it would have to be automatic, and I could cope if it picked the wrong one of 2 capitalisation choices.

John