Danbooru

Danbooru 2

Posted under General

So Rails 3 is around the corner and I thought this would be as good a time as any to rewrite the site.

I don't plan on adding or removing any features, or changing the layout significantly. The rewrite will mainly focus on refactoring and designing the site in a more idiomatic style. But now is a good time to ask for some blue sky features, things that would require a major migration that could mean hours of downtime. I'll start by listing some stuff that has been on my wishlist for awhile.

  • Switching to Ruby 1.9. The micro-benchmarks are impressive and it seems most of the tools and libraries are offering better support.
  • Switching to HTML5. My hope is that I can write more semantic markup that doesn't have ugly Javascript blocks everywhere.
  • Using ActiveResource/named routing extensively. I don't expect this to affect the API that much, but the URLs will change, and instead of just GET/POST the site will use GET/POST/PUT/DELETE. I also want to break up large controllers, ideally restricting them to CRUD actions only.
  • More idiomatic testing, including usage of factories and stubs. The goal would be independence between test suites and eliminating fixtures.
  • Refactoring stylesheets, likely breaking them up into individual files like how Javascripts are currently organized.
  • Denormalization of favorites, pools, and uploader. They will now be treated like tags. I will still maintain join tables for favorites and pools for custom ordering, but you will be able to find the intersection between two favorites, exclude an uploader, find all the related tags for a pool, etc. If there's anything else you think might be a good target for denormalization let me know.

Things I'm debating over:

  • Using sampling to calculate related tags. That is, loading N random posts for a tag and calculating related tags based on that sample. The goal is to eliminate the posts_tags table. Related tag by type would probably be harder. But the join table is at 7 million records now and has all sorts of indexes and triggers associated with it. It'd be nice to eliminate this table entirely.
  • Switching to jQuery. jQuery is gaining mindshare over Prototype and I think it's better architected. This will involve rewriting most of the Javascripts however. But it remains to be seen how good Rails's integration with jQuery will be, and I'm not sure what switching gains me.
  • Internationalization. I'm not sure how useful this would be since tags would still be in English, but it would be easy to translate the rest of the site.
  • Switching to git. I'd like to host the site on github and not worry about backing up my Subversion repository all the time. I also hate merging in Subversion.

As you can see there's a lot on my plate, most of it of intangible benefit to site users. None of this will be deployed anytime soon. If you have any ideas or comments let me know.

Updated by StriderTuna

If internationalization involves being able to run the website in multiple languages at the same time. I'm for it.
Otherwise I support the keep it simple principle in the hopes that re-written Danbooru will make it out without bogging someone down too much to make it happen.
I like the stylesheet breakdown, HTML 5 is a nice thing to hear, maybe I'll think of something clever after some sleep.

I think I'll leave this one up to you... but if it was me? I'd go for a little something more roomy, more like a home, you know with signatures and avatars. Danbooru the home of homes...

OH! and a better forum please ._. not complaining, just more like home...

Feature requests, in descending order of importance (and ascending order of practicality):

  • A "translation mode" for posts, in which clicking and dragging on the image automatically creates a new note and opens it for text entry. I don't think I can put into words how amazingly helpful this feature, or something like it, would be.
  • If that's not doable, then at the bare minimum, a keyboard shortcut for "Create new note". There is a bookmarklet linked in howto:translate that does this already, but it's such an essential feature for translating long images that it should be a feature of Danbooru proper. (Although the "translation mode" would be better.)
  • A better pool ordering interface and for pool order changes to be reflected in pool history, as discussed in forum #33944.
  • A way to link to users using DText, as discussed in forum #33926. (I favor <<user>>, personally.)
  • A version of order:favcount that counts all users, not just those above Member-level.

And my two cents regarding the changes you're uncertain about:

albert said:
Using sampling to calculate related tags.

Go for it. I, for one, wouldn't be too terribly sad if the feature itself wasn't there; it took me a while to think of where it was actually used, and I don't think I've ever used it.

albert said:
Switching to jQuery.

Meh. jQuery is quite nice, but I say don't fix what isn't broken, and I've certainly never seen any problems with any of the DOM-manipulating/AJAX features of Danbooru.

albert said:
Internationalization.

Never a bad idea, especially considering that l18n libraries seem to ship default with Rails.

albert said:
Switching to git.

Obviously, this is a matter of your preferences, not mine, but I've always thought of git's in-place branches as "too clever by half"; I like my branches in multiple directories. That said, merging bugfixes into the development copy is a huge pain in the ass.

Volaju said:
I think I'll leave this one up to you... but if it was me? I'd go for a little something more roomy, more like a home, you know with signatures and avatars. Danbooru the home of homes...

OH! and a better forum please ._. not complaining, just more like home...

The forum software could use some tweaking, but by and large we are trying to DISCOURAGE excess...socialization, so to speak, on the forum.

A feature that I would like to see implemented would be able to "group" attachments of tags, or perhaps have the ability to nest tag attachments within other tag attachments. This is not important, the desired effect is.

Let me first demonstrate the problem that this will solve:
Currently, doing a search for "izumi_konata cat_ears" would return posts depicting both izumi_konata and cat_ears, but not necessarily a nekomimi-clad konata.

In order for this problem to be solved, there needs to be a way to associate one tag with another, along with additional search syntax to support searching. Perhaps something along the lines of "[ izumi_konata cat_ears ] yuri" as opposed to "izumi_konata cat_ears yuri".

This is something I have wanted to add to my own Danbooru-like webapp, but never got around to coding something like this (I figured it would require re-coding of the tagging engine and search). I hope you add this functionality to Danbooru 2 so that I can observe your implementation.

Also, for the love of science, tag-auto-complete! I use it on my own Danbooru-clone and it is extremely useful.

Yeah, the forum and comments are nice and neat the way they are now. Even if we do get avatars by some chance, I would hope that they are tiny (100x100 max) and please, please no signatures. All they do is take up space.

Kitsu~ siad:
A feature that I would like to see implemented would be able to "group" attachments of tags, or perhaps have the ability to nest tag attachments within other tag attachments.

Second this. It would make tagging a fair bit more difficult, but would also make finding the image you want almost absurdly easy.

Volaju said:
I think I'll leave this one up to you... but if it was me? I'd go for a little something more roomy, more like a home, you know with signatures and avatars. Danbooru the home of homes...

OH! and a better forum please ._. not complaining, just more like home...

Good God, no. Try Gelbooru's forums if you want that stuff. I looked at the first few topics and they literally made me wince; I'm sure you'll fit right in.

Kitsu~ said:
A feature that I would like to see implemented would be able to "group" attachments of tags, or perhaps have the ability to nest tag attachments within other tag attachments. This is not important, the desired effect is.

We have discussed this before and it just can't be done because it would require retagging every single image on danbooru.

Soljashy said:
Yeah, the forum and comments are nice and neat the way they are now. Even if we do get avatars by some chance, I would hope that they are tiny (100x100 max) and please, please no signatures. All they do is take up space.

fine no signatures, and 100x100 is all I need.

Fencedude said:
The forum software could use some tweaking, but by and large we are trying to DISCOURAGE excess...socialization, so to speak, on the forum.

Well you're right on the forum software, starting look like the 1990's on this website... but I might add a superb 1990's website... It's just like one giant wall of text.

glasnost said:
Second this. It would make tagging a fair bit more difficult, but would also make finding the image you want almost absurdly easy.

Good God, no. Try Gelbooru's forums if you want that stuff. I looked at the first few topics and they literally made me wince; I'm sure you'll fit right in.

I do go to Gelbooru, and Sankaku Complex, and many hentai sites, and porn, and... well just about anything, been to most of the chan's to =\

I like this site and iichan the best though, mainly because it's not just hentai or porn

Soljashy said:
Yeah, the forum and comments are nice and neat the way they are now. Even if we do get avatars by some chance, I would hope that they are tiny (100x100 max) and please, please no signatures. All they do is take up space.

No. NO NO NO NO

We do not need avatars or anything of the sort. The forum is only here as an administrative appendage to the site.

1 2 3 4 5 13