It sounds like maybe what you want is to have the "shuffle" mode play songs close to truly randomly while still penalizing songs that have been played too much recently. This gives us an optimization problem:
minimize KL(π || uniform) - β E_π[times played already],
where β is an inverse temperature determining how much you dislike repetition and π is your policy. Here I've arbitrarily chosen a reverse KL divergence because it leads to a nicer closed form:
π(song) ∝ exp(-β⋅"times song played already").
I wonder if anyone has implemented this before in a music playlist.
Easy version: Make a smart playlist whose criteria are 'last played is not in the last 3 weeks, last skipped is not in the last 3 weeks'. Randomize within that. Possibly add some other conditions like 'genre is not podcast'. I've been having iTunes/Music.app do this for... probably at least a decade, at this point, it doesn't track when you made playlists so this is just guessing.
I think the Spotify algorithm is weighted in the opposite direction because a lot of people, not me personally, don't have much diversity in their taste so they really just want to hear the same songs over and over like on the radio.
Last year I also had a rather similar idea, but dropped it before I went very far in working on it. I wonder if you and I had similar ideas?
1. Start with an LLM, so that your model understands natural language.
2. Replace RoPE with a tree embedding scheme, and causal attention with a sparse attention on the graph structure. (You could use full attention... but it's cheaper to use graph attention.)
3. Chop off the final unembedding layer, replacing it with a projection down to two scalars, one for logits and one for confidence.
4. Each option of a choice is represented by a number of tokens in leaf position; average these tokens' logit outputs to get the option's logit. Average all of the confidences from all of the options to get the choice's confidence.
5. Train the logits by KL divergence from a true distribution (or NLL on samples from a true distribution).
6. Train the confidences on a subset of the data in which you know the entire true distribution.
The hardest part is getting real world data for workflows, but I wildly speculate that you can get by with only ~50,000 documents if you first adapt domains using synthetic data.
Thanks for the early access! I was testing the Lisp idea out in the playground, but I don't think the model is smart enough right now to generate actual code. I tried having Jev finish generating the code for a Fibonacci number function, but it kept wanting to create a literal number instead of refer to a variable which is a number. This happened both when I gave Jev the current program as a string and when I gave Jev the program as structured data.
Maybe I'm just not doing a very good job at prompting Jev, but I think right now it's not quite capable enough to generate Lisp code.
reply