5 ms·
If you look at the code, I filter all titles that are substrings (including identical) of real ones. Sometimes the Markov chain will simply add a single word to
by gamegoblin 13y ago
If you look at the code, I filter all titles that are substrings (including identical) of real ones. Sometimes the Markov chain will simply add a single word to it, though, so it gets through the filter. Any suggestions on how to improve it?
- BoppreH 13y agoFunny, I'm sure I google'd a few of them and got a perfect match, but now I can't find any more. Probably my fault, sorry.
- sillysaurus2 13y agoThe straightforward solution is: For each fake title, compute its Hamming distance to every real title. Filter titles whose distances are very close to real titles. It's O(N^2), but if you write it in Python and run it with pypy, performance may be acceptable. Maybe. But I think this is a classic example of a Problem That Doesn't Matter. No need to spend time solving it (unless you're having fun!)
- kps 13y agoAnother suggestion: terminate unmatched open delimiters at the end, and strip unmatched close delimiters (parentheses, quotation marks, etc.