Hongmu Notes

❎ Keyword batch deletion

According to the word list, delete the entire paragraph of the hit keywords in the text.

Keyword batch deletion

Instructions for use

  • Paste the text and keywords separately, and click "Process" to delete the hit content.
  • Keywords are matched according to regular rules. If they contain symbols such as . * ( ), they must be escaped first.
  • It is recommended to arrange the word list according to "longest first and then shortest" to avoid long words being chopped into pieces.

Check the number of deleted words

After word deletion is completed, divide the word length by "number of characters in the original text - number of characters in the result" to estimate the number of hits and quickly determine whether there are any omissions.

📌 What does it mean if the difference is not equal to an integer multiple of the word length?

There may be multiple keywords that are hit (the difference is the sum of multiple paragraphs), or it may be that part of a certain keyword was deleted by a longer word; it is recommended to verify the vocabulary list one by one in small batches.

📌 delete rule

Read the keyword list line by line, skip empty lines, and then perform "global replacement with empty" on the text: every hit keyword is deleted, and the characters before and after it are directly connected. Replacements are accumulated in order, so after the previous keyword is deleted, the text will become shorter, and the next keyword will continue to match on the shortened text; regular expressions are used for matching, and special symbols have special meanings.

🧭 Common uses

It is common to clean up advertising words and irrelevant tags in the text, remove redundant suffixes and suffixes from the exported data, delete internal code names or watermark text in batches, and remove recurring descriptions in a paragraph before doing statistics. Because only deletions are done without adding, the number of characters in the result will only be reduced, making it easy to use the "difference in word count before and after deletion" to quickly check.

All keywords and tutorials 12

❓ FAQ

Can the word count be displayed?
The status line will show "number of valid keywords/number of vocabulary entries", and the number of words can be counted using other tools.
Can it be checked automatically?
This page does not provide it and requires manual work or the help of character statistics tools.
The order of word deletion verification
Look at the number of status lines → calculate the character difference → spot-check the hits.