How do I replace unicode characters that look like latin characters with ASCII equivalents?
Trying to make a chat filtering program, but people can circumvent it by using unusual characters that are still human readable.
I have tried libraries like unidecode or anyascii, however they seem to prioritize phonetically similar characters instead of visually similar ones.
Example
Ideally it should take care of all kinds of different zalgo or "font" characters, but here is an example with cyrillic letters:
s = "FRЕЕ DISСОRD NIТRO" # contains some cyrillic letters (Е,С,О,Т)
print(unidecode(s)) # FREE DISSORD NITRO (phonetically transliterated)
This obviously again would break chat filters since it would look for "DISCORD" instead of "DISSORD".
Potential solution?
VSCode seems to use a really effective library to detect these characters, but I was unable to find out how exactly they do it. I only found that vscode uses textmate for syntax highlighting. As you can see it can highlight these "ambiguous unicode characters" and also suggest a replacement character:
Can I use this VSCode library to filter my own strings?

The technical term you're looking for is a confusable. Unicode provides a nice sample app (along with a Java implementation) in their utilities, and a data file describing the official list of confusables.
Looking at the VSCode source, it looks like Microsoft uses a package vscode-unicode-data to generate a dictionary of ambiguous characters from the Unicode data, along with a few hand-written additions.