TheCollector / README.md
Enutrof's picture
Updated README with new tasks.
8ea4b76

A newer version of the Gradio SDK is available: 6.4.0

Upgrade
metadata
title: The Collector
emoji: 🔥
colorFrom: gray
colorTo: red
sdk: gradio
sdkVersion: 5.31.0
app_file: app.py
pinned: true
license: mit

TheCollector

A Telegram Bot that downloads videos or video segments using yt-dlp.

Usage:

  1. Install necessary libraries: pip install python-telegram-bot yt-dlp
  2. Get a Bot Token from BotFather on Telegram.
  3. Replace "YOUR_TELEGRAM_BOT_TOKEN" with your actual token.
  4. Run the script: python your_script_name.py
  5. Send commands to your bot on Telegram: /download /download [START_TIME] /download [START_TIME] [END_TIME] (Time format: HH:MM:SS or MM:SS)

Notes:

  • Telegram has a file size limit for bots sending files (usually 50MB) but this works around that. This bot attempts to download a suitable format but might fail for extremely large videos.
  • Ensure ffmpeg is installed if yt-dlp requires it for merging formats or conversions. (yt-dlp often bundles it or can use a system-wide ffmpeg).

Tasks:

  • Deployment
    • Set up docker first. ✅
    • Deploy to the cloud
  • Switch to using a subprocess ✅
  • Test to see which argument for constraining size works for youtube videos. 🗑️
  • Fix name extraction from file info
  • get around size limit (https://stackoverflow.com/a/77654947) ✅
  • confirm that timestamped URLs do not break the bot
  • integrate cobalt as a fall back for short video download. Maybe replax instagram download altogether with it.