feat: discover YT recommendations and tune the radio
yt-dlp now feeds mood discovery. Queries come from the free-text hint, seed artists and genres; they run in parallel, are filtered to music-length videos, matched against library songs by normalized title and artist, scored, and stored as review candidates. Refresh, accept and reject endpoints are added: accepting a library match adds a seed immediately, while accepted tracks that are not owned wait for the future downloader. Decisions survive refreshes and stale undecided candidates are pruned. A background pass refreshes stale moods every hour, and the image ships a pinned yt-dlp binary (YTDLP_PATH, also added to the Nix shell and chart). Radio now avoids tracks played in the last 7 days when the pool is large enough, spaces artists and albums across a batch, and weighs skips three times as heavily as completions. The chart moves to 0.2.2.
This commit is contained in:
1 parent
67eed8d262
commit
c5aa000d1a
18 files changed
+1061
-37
No files matched your search
@@ -16,6 +16,7 @@ import win.taptap.musicmanager.api.UserDto
|
||||
import win.taptap.musicmanager.config.LibraryConfig
|
||||
import win.taptap.musicmanager.config.UsersConfig
|
||||
import win.taptap.musicmanager.db.ApiTokenRepository
|
||||
import win.taptap.musicmanager.discovery.DiscoveryService
|
||||
import win.taptap.musicmanager.radio.RadioService
|
||||
import win.taptap.musicmanager.scanner.CoverArtService
|
||||
import win.taptap.musicmanager.scanner.ScanStatus
|
||||
@@ -33,6 +34,7 @@ fun Route.apiRoutes(
|
||||
coverArtService: CoverArtService,
|
||||
transcoder: FfmpegTranscoder,
|
||||
radioService: RadioService,
|
||||
discoveryService: DiscoveryService,
|
||||
startScan: () -> Boolean,
|
||||
scanStatus: () -> ScanStatus,
|
||||
) {
|
||||
@@ -125,7 +127,7 @@ fun Route.apiRoutes(
|
||||
}
|
||||
|
||||
libraryRoutes(users, library, coverArtService, transcoder)
|
||||
moodRoutes(users, library, radioService)
|
||||
moodRoutes(users, library, radioService, discoveryService)
|
||||
sessionRoutes(users, library, radioService)
|
||||
}
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user