Dataset Viewer
Auto-converted to Parquet Duplicate
text
stringclasses
3 values
python-telegram-bot[job-queue]>=21.0
google-generativeai==0.8.4
aiosqlite>=0.20.0

πŸ›‘οΈ TelegramGuard

AI group guardian that actually answers your questions.

Anti-spam. Vision. Chat. No topic off-limits.

MIT License Powered by I-Lang Gemini

English | δΈ­ζ–‡


Use It Now (Zero Setup)

Add the official bot to your Telegram group. No install, no config, no cost.

@iLangGuardBot

  1. Open Telegram, search @iLangGuardBot
  2. Add it to your group
  3. Grant admin permissions (delete messages + ban users)
  4. Done. Spam protection is automatic.

You can also DM the bot directly for AI chat.


What It Does

Anti-Spam β€” AI three-step analysis detects ads, scams, crypto spam, porn, political propaganda. Sees through Unicode tricks, emoji stuffing, homophone substitution. Catches repeat flooding (same message 3+ times) with zero AI cost. Bans and deletes all recent messages in parallel.

Vision β€” Reads images and video thumbnails. Catches image spam. In chat mode, analyzes what's really happening in a photo, not just describing objects.

Chat β€” @ the bot in any group or DM privately. Multilingual, auto-detects your language. Finance, tech, relationships, culture, anything. Answers first, lectures never.

Three-Step Method for Sensitive Topics β€” Most bots refuse. TelegramGuard uses a different approach:

Step What happens
Insider Risks Shares what actually goes wrong: scams, traps, consequences
Reality Check Asks if you're curious or serious, no judgment
Direction Gives enough info to make smart decisions

Host Your Own

Option 1: VPS (One Command)

curl -sL https://raw.githubusercontent.com/ilang-ai/TelegramGuard/main/install.sh | sudo bash

The script handles everything: clone, dependencies, token setup, systemd service, auto-start.

You need two things (both free):

After install:

systemctl status telegramguard     # check status
systemctl restart telegramguard    # restart
journalctl -u telegramguard -f    # live logs

Option 2: HuggingFace Space (Free, No Server)

  1. Fork this repo
  2. Create a HuggingFace Space β†’ Docker SDK β†’ Blank
  3. GitHub repo Settings β†’ Secrets β†’ add HF_TOKEN (your HF write token)
  4. HF Space Settings β†’ Secrets β†’ add BOT_TOKEN + GEMINI_API_KEY
  5. Push to GitHub triggers auto-deploy to HF

Option 3: Manual

git clone https://github.com/ilang-ai/TelegramGuard.git
cd TelegramGuard
pip install -r requirements.txt
export BOT_TOKEN="your-token"
export GEMINI_API_KEY="your-key"
python bot.py

Customize the AI

The bot's brain lives in .ilang files using I-Lang Prompt Spec:

prompts_demo/
β”œβ”€β”€ persona.ilang     How it thinks + how it talks
β”œβ”€β”€ antispam.ilang    What counts as spam
└── vision.ilang      How it reads images

Each file contains ::GENE definitions that control behavior:

::GENE_IMMUTABLE{S001, T:ANTI_COLLAPSE, A:MORAL_PANICβ‡’LETHAL, G:ALL, Θ:ALWAYS}
# When user raises grey topics: don't panic, analyze objectively.

::IMMUNE{RISKY_OR_ILLEGAL, THREE_STEP_RESPONSE}
# Step 1: Insider risks  Step 2: Reality check  Step 3: Direction

Change the genes, change the bot. To customize: copy prompts_demo/ to prompts/, edit. The bot loads prompts/ first.

Learn I-Lang Prompt Spec β†’


BotFather Setup

After creating your bot, send to @BotFather:

/setjoingroups  β†’ Enable
/setprivacy     β†’ Disable

Architecture

TelegramGuard/
β”œβ”€β”€ bot.py                 Core (group + private + events)
β”œβ”€β”€ config.py              Env vars
β”œβ”€β”€ install.sh             One-line VPS installer
β”œβ”€β”€ Dockerfile             HF Space deployment
β”œβ”€β”€ modules/
β”‚   β”œβ”€β”€ chat.py            AI engine (loads .ilang prompts)
β”‚   β”œβ”€β”€ db.py              Shared SQLite + async lock
β”‚   β”œβ”€β”€ database.py        Schema
β”‚   └── admin.py           Group admin
└── prompts_demo/          AI personality (.ilang files)

Built with I-Lang Prompt Spec β€” structured AI instructions using genetic code.

Spec Web HF

MIT | Eastsoft Inc. | I-Lang Research

Downloads last month
-