Skip to main content

Notice

Please note that most of the software linked on this forum is likely to be safe to use. If you are unsure, feel free to ask in the relevant topics, or send a private message to an administrator or moderator. To help curb the problems of false positives, or in the event that you do find actual malware, you can contribute through the article linked here.
Topic: Dynamic playlists (Read 4568 times) previous topic - next topic
0 Members and 1 Guest are viewing this topic.

Dynamic playlists

view download

This script allows creating dynamic playlist based on selected track using echonest API: http://developer.echonest.com/docs/v4/playlist.html#static
It can be used by simply selecting some favorite track then running the script through foo_run:

Code: [Select]
wscript foo_echosong.vbs %MUSICBRAINZ_TRACKID%
  or
wscript foo_echosong.vbs "%artist%" "%title%"

or interactively by providing additional parameter argument - "interactive", in which case primitive inputbox control will allow more detailed tunning on playlist creation request:


Initially I thought to use comserver component, and do this task without making playlist file, but I must relieve my impression of this funny component. Despite uncommon installation, and playback controlling interfaces, it allows moving playlist around, renaming, even creating new ones, but it can't add items to newly created playlist!? Go figure. Then if you are persistent you can write playlist to a file and try to use playlist.load() method - exposed but disfunctional! Let it rot... or prove me wrong

So what to do with response data, then make XSPF and manually dig for it through foo_softplaylist component. And that's how it works: playlist echo.xspf is created in script's folder, which then through foo_softplaylist can be loaded by using "menu > library > load xspf playlist...". Alas

echonest api allows creating different types of playlists, and I selected what seemed flexible to me. Selected method can also return response with xspf playlist with low quality http preview tracks from some of it's buckets, like 7digital i.e., but I guess anyone can do that in browser already

Dynamic playlists

Reply #1
I extended above script, with a fancier UI. It's basically same script wrapped in html as application, and with a bit of logic for UI interaction and other small changes.



It can be called from foo_run, like [songecho.hta "%artist%" "%title%"] and after adjusting preferences or accepting defaults, it will create new playlist and load it in foobar automatically if COM server component is detected, otherwise XSPF playlist will be created, that can be loaded by foo_softplaylist component (Library > Load XSPF playlist...) as already mentioned

Because it tries to match tracks from remote playlist to user library, option is added to review XML response, which is rendered by default MS XML stylesheet:



Different controls are activated on different playlist types. When creating playlist the first step should be selection of playlist type, which defaults to "song radio" playlist. Also if seeded track and/or artist aren't indexed by echonest, some playlist types will be disabled as options.
I added tooltips for reference to most of text labels, but also echonest logo can be clicked for redirection to echonest documentation, describing all these parameters.

Source: link
Download: link

Dynamic playlists

Reply #2
Further tweaks...
This is new version, which instead optional raw XML response, offers optional embedded XSPF player with 1min preview from all tracks (tracks provided by 7 digital)
So exploring is not limited just to user library



Source: link
Download: link

Dynamic playlists

Reply #3
Works great, thank's. how to enable com server?

 

Dynamic playlists

Reply #5
Thanks

Dynamic playlists

Reply #6
Hi, I just tested your app.
I really like the idea. Unfortunately the chances that the generated playlist match your own library are pretty low.
So the preview feature makes sense and gives an idea how echonest is working. That's pretty nice.

Over the years I used to run genpuid/MusicDNS to analyze my files and build playlists from my lib. It was kinda similar, but unfortunately this technology is abandoned and their server doesn't respond anymore (right now).
I wish there was a fingerprint/sound characteristic playlist generator for foobar2000 but I guess with streaming services like spotify & co this is going to be obsolete.

I use Random Pool for foobar to generate an ongoing playlist after some criteria. It's nice to rediscover stuff from my lib... but I miss the selection of sound characteristics.

These were just some thoughts, sorry for the blubb ;-)