How can I quickly download audio from YouTube by URL or ID and send it to Telegram bot? I've been using youtube-dl to download audio, save it on hosting and after that send it to user. It takes 1-2 minutes to do that. But other bots (like this one @LyBot) do this with the speed of light. How do they do this?
As it says in their documentation "I send audio instantly if it has already been downloaded through me earlier. Otherwise, the download usually takes no more than 10 seconds."
They probably store a file the first time its downloaded by any user so that it can be served instantly for subsequent requests.
How can I quickly download and send audio from youtube?