> The good thing with DSTM, especially with Spotty is, that the
> recommendations are based on the previous song, I don't want a song of a
It's picking up several songs. Spotty would use 5 random tracks
previously played:
my $seedTracks =
Slim::Plugin::DontStopTheMusic::Plugin->getMixableProperties($client, 5);
> Also, I have looked into the sourcecode of the Spotty DSTM plugin
> (https://github.com/michaelherger/Spo...topTheMusic.pm)
> and in line 37 it sets the seed limit to 25 which is what I presume the
That's the number of tracks the plugin is requesting from Spotify. It's
requesting more than the five it would add, as sometimes there are
dupes, or tracks which had been played before etc.
I actually had to look into my own code again to better understand what
it's doing there... still not 100% sure about it :-).
I'm not sure there's an easy solution to your problem. I think there's
no way to figure out whether a track had been added by DSTM or your
guest (#2).
#1 you could achieve by implementing your own mixer, which would
basically call Spotty's instead, then remove all but one track from the
resulting mix. At the same time you could set DSTM's "newtracks"
preference. It's defaulting to two tracks and tells DSTM when to add new
tracks ("two left"). You could set this to one, to further limit the
time your friend has to wait for her track. ("newtracks" currently isn't
exposed in any UI - you'd be the only one using it :-))
#3 you'd only need to keep track of the last added, right? DSTM's would
be all after that one. You could find your track's position and remove
all remaining tracks (those added by DSTM) before adding the next user
track. I wouldn't sconsider this "unclean". DSTM is doing similar things.
#3 might be easier to do than #1. #2 you'd depend on the user having a
specific LMS version.
> recommendations are based on the previous song, I don't want a song of a
It's picking up several songs. Spotty would use 5 random tracks
previously played:
my $seedTracks =
Slim::Plugin::DontStopTheMusic::Plugin->getMixableProperties($client, 5);
> Also, I have looked into the sourcecode of the Spotty DSTM plugin
> (https://github.com/michaelherger/Spo...topTheMusic.pm)
> and in line 37 it sets the seed limit to 25 which is what I presume the
That's the number of tracks the plugin is requesting from Spotify. It's
requesting more than the five it would add, as sometimes there are
dupes, or tracks which had been played before etc.
I actually had to look into my own code again to better understand what
it's doing there... still not 100% sure about it :-).
I'm not sure there's an easy solution to your problem. I think there's
no way to figure out whether a track had been added by DSTM or your
guest (#2).
#1 you could achieve by implementing your own mixer, which would
basically call Spotty's instead, then remove all but one track from the
resulting mix. At the same time you could set DSTM's "newtracks"
preference. It's defaulting to two tracks and tells DSTM when to add new
tracks ("two left"). You could set this to one, to further limit the
time your friend has to wait for her track. ("newtracks" currently isn't
exposed in any UI - you'd be the only one using it :-))
#3 you'd only need to keep track of the last added, right? DSTM's would
be all after that one. You could find your track's position and remove
all remaining tracks (those added by DSTM) before adding the next user
track. I wouldn't sconsider this "unclean". DSTM is doing similar things.
#3 might be easier to do than #1. #2 you'd depend on the user having a
specific LMS version.