TGuard Connect Bot
Security 8 min read

AI Spam Filter for Telegram: What It Catches That Keywords Miss

"Need 2 people for a warehouse shift tonight, 120 cash in hand, 6pm start. Reply + in DM." No link, no "earn from home", no crypto. No stop-word list stops that unless you ban the word "warehouse". An AI spam filter reads it as recruiting bait, because it looks at what the message is doing rather than which words it uses.


Local and neighbourhood groups get these in batches now, and they're well made. The pay sounds plausible, the time is specific, the tone is a neighbour's. There's a "reply +" where a link would be and nothing where a company name would be. It's recruiting for couriers and money mules, and it's written precisely so a keyword filter won't notice.

You could add "cash in hand" and "DM" to your stop list. Give it a day and you'll be deleting the neighbour who's offering twenty quid for help carrying a sofa.

The message there's no stop word for

A Telegram spam filter built on stop words is great against spam with a fixed tell: a casino link, the same paragraph about trading signals, "passive income". We run one ourselves, and for plenty of groups it's all they need. Where it breaks is the spammer who writes like a normal person.

Here's what slips past almost any word list. A channel ad with no link: "we cover cases like this on our channel, search the name". An invitation to "chat privately" from an 18+ profile picture. Crypto that never says crypto, only "50x this week, a few spots left". And the side gig, with a new amount and a new wording every day. You can't list all of that in words. The words change weekly; the intent doesn't.

A human moderator spots it at a glance. An AI Telegram moderator works in roughly the same way: it reads the whole message and judges what it's trying to do, not which words happen to be in it.

A stop word looks for a word. A neural filter looks for intent: to sell, to lure, to recruit.

Telegram's aggressive anti-spam, and where it stops

Telegram has a filter of its own. Aggressive Anti-Spam is a switch admins can turn on in supergroups over 200 members, and it's worth having: it costs nothing and clears out a share of the obvious junk. What it doesn't give you is a say. You can't see why a message went, you can't tell it that job posts are fine in your group, and smaller groups don't get it at all.

That's the gap a Telegram bot for spam protection fills. It's still an AI spam filter, but one you can read and steer: every decision lands in a log with a reason, and you describe in your own words what counts as spam in your chat. If all you need is a Telegram bot to stop spam with links and stop words, the regular rules already do that. The AI layer is for what they miss.

Where the AI spam filter reads, and what it looks for

In TGuard the AI spam filter is its own tab, "AI filter", on the anti-spam settings page next to "Stop words", "Rules" and "Log". It reads messages in the group and comments under channel posts. Comments come with the usual catch: they don't live in the channel but in the linked discussion group, so TGuard has to be added there. Do that and Telegram comment spam gets checked like any other chat message — which matters, because comment threads are where spammers prefer to go.

It looks for five things: ads, scams, crypto, recruiting and side-gig bait, and 18+. There's a sixth category you write yourself, more on that below.

Not everyone gets checked. Admin messages are never touched. A member already caught spamming is flagged straight away, without a second look. And someone who has been writing normally for a while eventually drops out of checking altogether, so the filter spends its attention on new and unfamiliar senders rather than your regulars.

Delete, or just log

The AI filter has three reactions: off, log only, delete. It can't ban, and that's a choice rather than a gap. Removing a message is one thing, shutting a person out of the group is another, and that second call stays with people and with the rules you configured yourself. Even on "delete", a message the filter is unsure about is logged rather than removed.

Everything it flags lands in the "Log" with a reason badge: "AI: ad", "AI: scam", "AI: crypto", "AI: 18+", "AI: recruiting", "AI: chat rule", "AI: spammed before", "AI: suspicious". Entries are kept for 30 days. Start on "log only". Read the log for a couple of days, see what the filter reacts to in your group, then switch on deleting. It's the same order we suggest for the regular rules against spam in a Telegram group, and it pays off the same way.

A rule in your own words

Spam is local. In a flea-market group, "selling a pram, 30 quid" is a normal message. In a school parents' chat it's an ad. The general rules can't know that, so the tab has a field called "Rules for your chat", up to 500 characters, where you write the way you'd brief a person:

  • any job offers and side gigs are spam;
  • selling personal items is not spam, this is a flea market.

That example comes straight from the interface, and it shows the point well: your note can widen what counts as spam or narrow it. Anything caught because of your note gets the "AI: chat rule" badge, so you can see which part of the work is yours.

Next to it is "Test on recent messages". It runs the group's recent conversation through the filter and shows what it would have flagged, before you've switched anything on. Change the note, press it again, compare. Five minutes of that is worth a week of watching a live group.

"Hi all" now, an ad an hour later

One trick beats any check that runs at the moment a message is sent. An account joins and posts "hi all, been reading for a while". The filters look: clean. A moderator looks: clean. The message sits there, people read it and scroll past. Then the spammer edits it, and the greeting becomes an ad with a link. There's no new notification, nobody scrolls back up, and the ad stays for weeks.

TGuard has a separate rule for this, "Late edit", under the "Rules" tab. It fires when a message is edited later than a set time after it was sent. The default is 10 minutes: a person fixes a typo right away, a spammer needs the message read and forgotten first. If your group has no use for edits at all, set it to 0 and any edit counts. You choose the reaction, as with every rule, and the log marks these with a "Late edit" badge.

What to leave to the ordinary rules

The neural filter doesn't replace the rest of the protection, and it isn't the first thing every group should turn on. If your problem is the same link pasted over and over, the link filter and the known-abuser rule do it faster. If waves of accounts with Arabic, Hindi or Chinese names keep joining, there's the "Country alphabets" rule: it covers Hebrew, Hindi, Thai, Chinese, Japanese, Korean and Arabic, in the message and in the sender's name. Where those waves come from is in our piece on blocking users from specific countries.

The layers work together. Stop words and links take the predictable stuff, the abuser database takes accounts that already spammed other channels, and AI spam detection covers whatever is written in plain human language. If you're still choosing a bot, we've compared TGuard with Combot and Group Help separately; those comparisons are mostly about the account layer rather than the text.

Turning it on

  1. Add @channel_guardian_bot to the group as an admin with the right to delete messages. For comments, add it to the linked discussion group.
  2. Turn on Spam Protection and open the chat's settings page from the bot.
  3. On the "AI filter" tab, write your chat rules if you need any and press "Test on recent messages".
  4. Set the reaction to "log only" and check the "Log" a day or two later.
  5. Happy with it? Switch to "delete". While you're there, turn on "Late edit" under "Rules".

For years a Telegram bot to remove spam meant arguing over which words to ban. A spam removal bot that reads intent ends that argument: you don't have to guess the spammer's next phrasing, you only have to say once what's normal for your group.

Frequently Asked Questions

Does the AI spam filter ban members on its own?

No. The AI filter has three settings: off, log only, and delete. There is no ban on the filter's decision at all, and messages it is unsure about are only logged. Bans stay with the regular rules — stop words, links, known abusers — and only if you set them to ban.

Is Telegram's Aggressive Anti-Spam enough, or do I need AI anti-spam too?

Keep Telegram's switch on, it costs nothing. But it only works in supergroups over 200 members, and you can't see why it removed a message or tell it what is normal in your group. TGuard's AI spam filter runs alongside it, logs every decision with a reason and takes rules written in your own words. It also covers channel comments, once TGuard is added to the linked discussion group.

Can I tell the filter what is not spam in my group?

Yes. The AI filter tab has a Rules for your chat field of up to 500 characters. You describe in plain words what counts as spam in your group and what does not — say, job offers are banned but selling personal items is fine. The filter applies that on top of its general rules, and Test on recent messages shows what changed right away.

Connect TGuard

Automatic bot protection, anti-raid, and subscriber analytics for your Telegram channel.

🛡 Launch @channel_guardian_bot
TGuard
Channel protection. Analytics. Audience quality.
TGuard Bot on Telegram
Contacts
Legal Information
© 2023-2026 TGuard — a service for protecting Telegram channels from fake accounts and bots.