That's far more advanced than what I did! I just opened the file in Notepad++ in the Search interface went to the Mark tab. Make sure the bookmark line box is checked and that regular expression is selected. Then I marked lines like the following:
>You gained \d\d\d experience points and
<You gained \d\d experience points and
<You start to harvest.
<You start to dig.
<You've got some
<You hit
That sort of thing. I leave some system messages (storing/dropping/etc) as they can be useful in tracking down items. If you don't mind clearing all sytem lines, you'll note that they all start with the timestamp and the a '<'. I think you can mark all of those lines with this:
\(\d{2}:\d{2}:\d{2}\) >
That will mark every line that comes into the system tab. That includes /who results, the standard emotes like greets, transactions, etc.
Once you've bookmarked everything you want to delete, just go to Search-Bookmarks-Remove Bookmarked Lines
May want to make a backup, just in case.
EDIT: Ah, you posted while I was typing. In that block above, I'd just mark lines containing the following:
\[NPC] .* casts .* to Gonger
\[NPC] .* thinks Gonger
\[NPC] .* attacks Gonger
Doing those manually is terribly slow, but shouldn't deleted quest text. You can try this, which will deleted all NPC lines that don't contain the word "says"
^\(\d{2}:\d{2}:\d{2}\) \[NPC] (?!.*says).*$
NPCs use emotes though, and those could be relevant.
Other useful lines to bookmark and delete:
<You've gained some practice points
<You are too far away
<You made
Sarras
hits you