Moderation

The moderator, Bouncer, is silent until a violation. It works in two lines.

Line one: rules#

Rules cost nothing to run.

  • Captcha for new participants: a button they must press. Until then they are muted, and on timeout they are removed. They can come back.
  • Flood control: too many messages in a short time.
  • Links and forwards from newcomers are deleted with a warning.
  • Streaks of stickers or GIFs.
  • Forbidden patterns that you define.

Line two: the model#

A message that looks suspicious but is not obvious spam, such as capital letters, trigger words or a link from a new member, goes to the model. It returns a verdict (spam, toxic or ok) with a confidence.

VerdictAction
spam, high confidenceDelete and warn.
toxic, high confidenceWarn. The third warning mutes.
medium confidenceNothing in the chat. The admin gets a report in the private chat.
low or okNothing.

A ban comes only after repeated warnings (five by default) or by an admin's command. The model never bans.

Admins from the allowlist are never punished. Posts that the channel auto-forwards into the chat, and messages sent on behalf of the group, are not moderated. A message addressed to the bot is not moderated either.

Admin commands#

Send these in a private chat with the bot.

CommandWhat it does
/warns <tg_user_id>Shows a person's warnings.
/unwarn <tg_user_id>Removes a warning.
/ban <tg_user_id>Bans a person.
/rules_set <key> <value>Changes a setting.

Settings#

KeyDefaultMeaning
flood_max_messages7Messages allowed within flood_window_seconds.
flood_window_seconds10The flood window.
sticker_streak_limit4Stickers or GIFs in a row.
novice_min_messages10Messages after which a member stops counting as new.
novice_hours48Hours after which a member stops counting as new.
captcha_enabledtrueCaptcha for new members.
captcha_timeout_seconds180Time to press the button.
ai_high_confidence0.85Confidence treated as high.
ai_medium_confidence0.6Confidence treated as medium.
mute_after_warns3Warnings before a mute.
mute_hours4Length of a mute.
ban_after_warns5Warnings before a ban.
banned_patternsPatterns that are always removed.
trigger_words, complaint_wordsWords that send a message to the model.
service_languageruLanguage of warnings and service text.

If the moderator is too strict, raise ai_high_confidence, for example /rules_set ai_high_confidence 0.92, or leave the bot in draft.

Every action is recorded in the moderation log with the reason, and can be revoked. Through MCP, read it with moderation_log and the rules with get_moderation_rules and set_moderation_rules.