Separate private tags from public tags in API

This solves the problem of private and public tags having the same
name. While we were at it, we also introduced ways for users to
optically distinguish them from each other. And the tag selector enables
only the tags a user can write.

The new query for the tag selector will also (hopefully) solce the
problems we had with PostgreSQL.

Some other issues with private tags and tags in general were fixed.