5.14.4. Isn't it hard to create an HTML filter?

No, it is very easy, because a class, html_input_filter, to do exactly this is standard in Interscript. This class uses the Python standard library module htmllib to parse the input.