This only lead to a contributed file, this is neither robust nor fast.
But maybe throwing the existing code into a contrib file
will make someone come up with an idea.
In this file I will implement interactive modifications of tags/todo
queries. This is code from Christopher League which still needs some
work before it will become either CONTRIB or even core.