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

[Feature Request] Related tags page for HTML. #2750

Closed
BrokenEagle opened this issue Nov 1, 2016 · 3 comments
Closed

[Feature Request] Related tags page for HTML. #2750

BrokenEagle opened this issue Nov 1, 2016 · 3 comments

Comments

@BrokenEagle
Copy link
Collaborator

Seems like there's a demand to see related tags outside of editing a post.

See forum topic #13349 for the full conversation.

Plus, there's plenty of room in the Tags submenu for additional entries.

While we're on this topic, would it be possible to expand the results to more than 25, or are there performance reasons why this couldn't be done?

@evazion
Copy link
Member

evazion commented Nov 2, 2016

Thoughts on this:

  • Instead of a separate page (or in addition to I guess), I think the related tags list in the sidebar for searches should be divided into character/copyright/artist/general lists. The current sidebar is pretty useless, it's flooded with too many common gentags. It should be as simple as searching a copyright to see the related characters.
  • Looks like calculating related tags by category basically just finds 300 random posts and counts up the tags (see 1 and 2). So to include it in the sidebar would require caching the calculation. Also adding the sidebar would maybe have to be done in javascript, since doing it serverside could block the page load.
  • It looks like the results are just truncated to 25 after processing, so increasing that shouldn't hurt performance, although I don't know how good the results would be given the low sample size.

@BrokenEagle
Copy link
Collaborator Author

Maybe conditionally cache the results whenever a singular tag gets searched and set a value like "updated_at". Whenever a singular tag gets searched, it would check the "updated_at" value, and if it's been less than 24 hours, will pull from the current cached results. Otherwise, it would generate a new set of results and set the "updated_at" value.

@Type-kun
Copy link
Collaborator

Type-kun commented Jan 9, 2017

Maybe conditionally cache the results whenever a singular tag gets searched and set a value like "updated_at". Whenever a singular tag gets searched, it would check the "updated_at" value, and if it's been less than 24 hours, will pull from the current cached results. Otherwise, it would generate a new set of results and set the "updated_at" value.

It's already happening, related tags are stored in tag table and updated periodically.

Basic solution is in PR #2826, improvements are welcome.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants