Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use 'frecency' in the inserter? #5320

Closed
noisysocks opened this issue Mar 1, 2018 · 5 comments
Closed

Use 'frecency' in the inserter? #5320

noisysocks opened this issue Mar 1, 2018 · 5 comments
Labels
[Feature] Inserter The main way to insert blocks using the + button in the editing interface [Type] Enhancement A suggestion for improvement.
Milestone

Comments

@noisysocks
Copy link
Member

screen shot 2018-03-01 at 10 58 10

Currently, blocks in the Recent tab are ordered from most recently used to least recently used. This works, but fails to take into account how frequently a block is used. It might be worth exploring sorting these blocks by frecency.

I like this definition used by z:

Frecency is a portmanteau of ‘recent’ and ‘frequency’. It is a weighted rank that depends on how often and how recently something occurred. As far as I know, Mozilla came up with the term.

To z, a directory that has low ranking but has been accessed recently will quickly have higher rank than a directory accessed frequently a long time ago.

The sorting function that z uses looks like it might work well for us, as well:

function frecent(rank, time) {
    # relate frequency and time
    dx = t - time
    if( dx < 3600 ) return rank * 4
    if( dx < 86400 ) return rank * 2
    if( dx < 604800 ) return rank / 2
    return rank / 4
}

Thoughts? Is this worth trying? cc. @karmatosed @jasmussen @mtias

@noisysocks noisysocks added [Type] Enhancement A suggestion for improvement. [Feature] Inserter The main way to insert blocks using the + button in the editing interface labels Mar 1, 2018
@jasmussen
Copy link
Contributor

I think this will make @folletto happy :)

Recency is good because it sorts blocks according to those you actually use, so blocks you rarely use aren't on top. But at the same time this can mess with spatial memory. If you're used to always having the Image first and the Gallery 2nd, you might stumble if they suddenly switch place. So anything to improve that spatial memory is a win in my book. Does this help that?

@karmatosed
Copy link
Member

karmatosed commented Mar 1, 2018

This is so awesome! I am really excited about exploring this and it's something extra that will make this magic. I think this solves some spatial issues we have now but keeps the usefulness.

@karmatosed karmatosed added this to the Merge Proposal milestone Mar 1, 2018
@danieltj27
Copy link
Contributor

I really like this idea of having most used blocks. Working out how to approach the per post and per user most used will be interesting though. I can imagine having a most used per page such as text may not be the most used per user such as image for example. Great idea though 👍

@folletto
Copy link
Contributor

folletto commented Mar 1, 2018

I think this will make @folletto happy :)

VERY happy, as it's something I suggested when we did the first design #888 (comment) :D :D :D

But at the same time this can mess with spatial memory. If you're used to always having the Image first and the Gallery 2nd, you might stumble if they suddenly switch place. So anything to improve that spatial memory is a win in my book. Does this help that?

Yes. It's not perfect for spatial memory, but it's a "sweet spot" between purely short-term memory based approaches and spatial memory based approaches. As it makes the list recent but not too quickly changed. :)

I like this definition used by z:

I had no idea of that elaboration and that algorithm. I think it's a great starting point, and then we can tweak the weightings as we find it's better through testing. :)

@noisysocks
Copy link
Member Author

noisysocks commented Mar 2, 2018

I had a go at implementing this over in #5342. Play with it and let me know what you think!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[Feature] Inserter The main way to insert blocks using the + button in the editing interface [Type] Enhancement A suggestion for improvement.
Projects
None yet
Development

No branches or pull requests

5 participants