Get an LRC format (synchronized) lyrics for your music with aiohttp support
Project description
syncedlyrics
Get an LRC format (synchronized) lyrics for your music with aiohttp support.
Installation
pip install syncedlyrics_aio
Usage
CLI
syncedlyrics_aio "SEARCH_TERM"
By default, this will prefer time synced lyrics, but use plaintext lyrics, if no synced lyrics are available.
To only allow one type of lyrics specify --plain-only
or --synced-only
respectively.
Available Options
Flag | Description |
---|---|
-o |
Path to save .lrc lyrics, default="{search_term}.lrc" |
-p |
Space-separated list of providers to include in searching |
-l |
Language code of the translation (ISO 639-1 format) |
-v |
Use this flag to show the logs |
--plain-only |
Only look for plain text (not synced) lyrics |
--synced-only |
Only look for synced lyrics |
--enhanced |
Searches for an Enhanced (word-level karaoke) format. If it isn't available, search for regular synced lyrics. |
-d |
The duration of track in ms. Keep default if unknow. Only for netease and tencent |
-m |
Max deviation for lyrics in ms, ignore if duration is default |
Python
import syncedlyrics_aio
loop = asyncio.get_event_loop()
lrc = loop.run_until_complete(syncedlyrics_aio.search("[TRACK_NAME] [ARTIST_NAME]"))
if lrc:
print(lrc)
Or with options:
syncedlyrics_aio.search("...", plain_only=True, save_path="{search_term}_1234.lrc", providers=["NetEase"], duration=213000)
Providers
- Musixmatch
Deezer(Currently not working anymore)- Lrclib
- NetEase
- Megalobiz
- Genius (For plain format)
Lyricsify(Broken duo to Cloudflare protection)- Tencent
Feel free to suggest more providers or make PRs to fix the broken ones.
License
Citation
If you use this library in your research, you can cite as follows:
@misc{syncedlyrics,
author = {Momeni, Mohammad},
title = {syncedlyrics},
year = {2022},
publisher = {GitHub},
journal = {GitHub repository},
howpublished = {\url{https://github.com/moehmeni/syncedlyrics}},
}
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
syncedlyrics_aio-1.0.1.tar.gz
(15.2 kB
view hashes)
Built Distribution
Close
Hashes for syncedlyrics_aio-1.0.1-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | ebbca7b6e0e6bb9cfc27be07270d084af5012dc7ac917c0d47c6f89de7fb8b24 |
|
MD5 | c79e2dec529efeb6fafa30d18f03d8cc |
|
BLAKE2b-256 | a70ff617e7aecc41f1292d0fd6b5697884f71364f8179bbac3ea2c357ceb05d2 |