Spaces:
Running
Running
metadata
title: testbot
emoji: π¬
colorFrom: red
colorTo: yellow
sdk: docker
app_port: 7860
pinned: false
π₯ ANGRY BIRD File Serve Bot (Premium Edition) π₯
A premium, high-speed Telegram File Search and Direct Browser Download bot powered by FastAPI, Pyrogram, and Neon PostgreSQL. Designed for seamless 24/7 deployment on HuggingFace Spaces (Docker) and Render.
π Core & Premium Features
π Premium High-Speed Streaming Gateway
- π Direct Browser Streaming: High-speed browser file downloading directly from Telegram CDNs using custom-engineered asynchronous chunk streaming.
- β‘ Concurrency Optimized (100 Slots): Supports up to 100 simultaneous parallel downloads/streams without any queuing or delay bottlenecks, utilizing
workers=100parallel client connections. - π Practically 0 MB Server Overhead: Streams block-by-block using Pyrogram's
client.stream_media(...)async generator, avoiding local file caching and RAM out-of-memory (OOM) failures entirely. - ποΈ Auto-Clean Token Verification: Automatically cleans up authorization alerts, expiry errors, and incoming user query messages after a 10-second delay, ensuring clean private chats.
- β Dynamic Help & Guide Integrations: Renders a dynamic administrative control setting button (
how_to_downloadguide URL) across/startkeyboards.
π Advanced Database Search Engine
- π₯ Weekly Trending Tracker (
/trending): Automatically monitors and tracks movie search query frequencies over a 7-day rolling cycle, presenting the top 10 most popular movies directly to users on start keyboards or inline buttons. - π Newly Uploaded Monitor (
/newuploads): Displays a real-time list of the 25 most recently indexed movies/files, making it easy for users to check recent releases instantly. - π Trigram pg_trgm Fuzzy Search: Implements fuzzy title-matching leveraging PostgreSQL GIN trigram indexes to suggest and correct spelling mistakes.
- π― Precise Mode Search Option: Toggleable precise-matching mode to target exact word hits or perform general query containing searches.
- π Multiple File Formats Supported: Fully indexes and handles Documents, Video files, and Audio file formats with complete metadata logging.
- π Multi-Format Result Output: Dynamically outputs search query results in button layouts, list structures, or hyperlink lists.
βοΈ Channel Indexing & Operations
- π Automated Live Indexing: Real-time listening and automatic indexing of files uploaded directly to DB channels.
- π¦ Manual Indexing (
/index): Forward-based administrative channel scanning to easily batch-import files into database records. Works based on original file captions to prevent duplicate quality skip issues! - ποΈ Dynamic Database Deletion: Quick inline administrative file deletions (
/delete) directly inside chat threads. - β³ Auto-Delete Schedule: Automatic scheduled file purge settings to clear files after configured time thresholds.
π§Ή Bulk Delete Mode
- Smart Bulk Deleting: Standalone
/deletecommand turns on a powerful state-based bulk delete mode. Forward multiple files at once, and the bot will automatically delete them all from the database, deactivated with/done.
π‘οΈ Administration & Controls
- π‘οΈ Multi-Channel Force Subscribe: Blocks all search queries, keyboard commands, and downloads until users join all configured update channels. Supports a comma-separated list of public/private channels in settings.
- π Dynamic Invite Link Generation: Automatically resolves usernames (even without
@prefix) or creates private invite links for each configured channel dynamically. - π Instant Resumption Handshake: Saves blocked queries in the database and automatically executes them once the user joins and clicks "Try Again". If a token shortener is enabled, the query is passed seamlessly to the token system and executed automatically upon returning from the browser via
/start tok_xxxx.
- π Instant Resumption Handshake: Saves blocked queries in the database and automatically executes them once the user joins and clicks "Try Again". If a token shortener is enabled, the query is passed seamlessly to the token system and executed automatically upon returning from the browser via
- ποΈ Spam & Double-Click Protection: Instantly removes verification buttons when clicked to prevent duplicate execution, and edits prompt messages in-place with popup alerts to prevent user chat spam.
- π
Filename Release Years: Automatically extracts movie release years from filenames (e.g.
1900-2030) and appends them to search list buttons (e.g.,Odyssey (2026)) for a cleaner UX.
- π
Filename Release Years: Automatically extracts movie release years from filenames (e.g.
- π·οΈ Custom File Captioning: Setup custom headers/captions (like adding usernames or watermarks) to all dispatched files.
- β Member Ban/Unban System: Block unwanted users instantly using
/banand/unbancommand strings. - π’ Massive Broadcast system: Send custom formatted alerts or messages globally to all registered bot users concurrently.
- π Live Server Stats & Logs: Get real-time stats and runtime log dumps directly inside the administrator's chat.
π Codebase & Setup
For full instructions, file structures, and advanced procedures:
- π Refer to the comprehensive deployment manuals at:
- documentation/render_deployment_guide.md (For Render and Local setups)
Quick Local Run
Activate environment & install dependencies:
python -m venv .venv .venv\Scripts\Activate.ps1 # Windows source .venv/bin/activate # Linux/macOS pip install -r requirements.txtAdd environment variables to a local
.envfile (API_ID, API_HASH, BOT_TOKEN, DB_URL, OWNER_ID, DB_CHANNELS, etc.).Launch the bot:
python -m mfinder
π License & Ownership
This software, codebase, and its implementations are fully owned, managed, and licensed by:
- π€ Angry Bird (Primary Maintainer: @ANGRY_BIRD22_bot)
- β‘ Team FireBolt
All rights reserved. Unauthorized redistribution or copying of these custom features is strictly prohibited.