What is meta? ×
Meta Stack Exchange is where users like you discuss bugs, features, and support issues that affect the software powering all 130 Stack Exchange communities.

I've seen a lot of questions tagged with and no additional tags. These questions are often impossible to answer because regular expressions are so dependent on their engine's capabilities. Sometimes you can guess from the question or code sample which technology is being used, but often you can't. This reality is clearly recognized by the tag authors as the description practically pleads for users to add another tag with the tool or programming language implementing the regex:

There are many different dialects of regular expressions, all subtly different. Therefore, when asking questions, always include the tag for the specific programming language or tool (e.g., Perl, Ruby, Python, Java, JavaScript, vi, Emacs, sed, Lex, grep, etc.) you are using. Otherwise, you may get answers that won’t work for you.

Then I read the old blog post about the Death of Meta Tags:

Meta-tags are actually a subset of a larger problem that I usually call dependent tags. These are tags that don’t say anything by themselves – you can’t tell what the question is about unless they’re paired with some other tag (or several of them). These tags are a problem because people don’t realize this and will often use that as the question’s only tag.

While does, technically, "say something", it usually doesn't say enough to answer a given question.

See:

seems like a very problematic tag. While it can barely stand on its own (most often it can't), the only other solution I can think of would be to create dozens of [tool-regex] style tags (which is very ugly and presents its own set of challenges):

Is it worth splitting up the regex tag in multiple tool/language-specific tags? Or is it better to have a single tag which must nearly always be dependent on some other tag (whether supplied explicitly or via a comment)?

WHY BOTHER?
(Bringing some of the issues raised in the comments up to the question level...)

Questions tagged only with and no additional information in the question/comments about the tool being used are almost always impossible to answer without additional information.

In some cases, however, an answer is offered (often by someone with little knowledge of regex engine differences) and, by luck of the draw, the given regex works with the OP's implementation. In such a case, you have something even worse then a question with no answers: a question with an answer that is virtually worthless to future visitors. With such questions/answers, it's a crap-shoot: it'll either work with your regex engine, or it won't (which, to a "newbie", makes it look like the answer was wrong). In my opinion, the quality of the SO site suffers when such questions are allowed to proliferate.


From the discussion so far, it seems that there are four options:

  1. Split the tag into multiple tags by technology/tool
    The consensus on this option seems to be a fairly resounding "no":

    The difference between a .net-regex and a php-regex is microscopic. There's no need to have different “regex for phone number” questions in each of these. ...
    there's not nearly enough closing of duplicates — and if you split the tags, that'll only make it worse.
    ~ Gilles

    Taking this into account, I don't think it would be reasonable to undertake an insanely massive retagging of all SO questions (and I'm not sure it would even be deterministic). Also note that it would lead to a manifold increase in the total number of tags.
    ~ Lev Levitsky

    I think splitting the regex tag into multiple tags is overkill for a problem that already has a solution (add another tag). Splitting the tag would make matters worse for a large class of current questions tagged regex.
    ~ Bill the Lizard

  2. Make dependent on another tag
    In other words, require that a user include a "primary" tag along with "regex" (which, by implication, would be a "secondary" tag). This option has already been explored, somewhat: Could we make tags imply other tags?

    Jeff Atwood's response was, simply, "we will not be doing trees, in any way, shape or form". While the concept of primary/secondary is not exactly a tree structure, Jeff's "in any way, shape or form" would still seem to preempt this idea. (After all, would be a secondary tag?)

  3. Show a message to users tagging their question with encouraging them to include another tag
    I think this one carries merit. While not requiring users to include another tag (no tree structure!), it at least signals to new users that some additional information is typically expected. Perhaps tag wiki editors could set a couple well-defined flags (such as "Suggest user include another tag") for the tag without having to get too specific.

    People are already doing this in comments, so we might as well automate it to make it a little bit easier to answer these questions to begin with.
    ~ Bill the Lizard

    This is also already documented in the tag's info ("always include the tag for the specific programming language or tool"). The idea is to make the suggestion automatic and a bit more in-your-face (so that we don't have to constantly ask "what tool are you using" for OP's who don't ready the tag tool-tips).

  4. Do nothing
    Always an option. Admittedly, comments generally take care of the problem and the language or tool can often be inferred from the question. There is, as Gilles pointed out, quite a bit of overlap between major regex engines, so even when a language or tool is not specified there are some patterns which will work for the majority of users visiting the site. Perhaps this problem just isn't important enough to warrant much time or attention.

Personally, my vote is for #3.

share|improve this question
2  
Only 6.3% of questions tagged regex are unanswered. How big a problem is this really? Asking people to include more tags or otherwise provide the required information seems to be working. –  Bill the Lizard Feb 5 '13 at 18:27
2  
@BilltheLizard - It could be a problem for future visitors where a regex implementation was never identified. A answer was accepted because it happened to work with the regex engine the OP was using, but it won't work for all engines and there's no way for future visitors to know if it will work for them (without trial and error). In my opinion, it comes down to the quality of the posts more than anything. –  JDB Feb 5 '13 at 18:31
    
@BilltheLizard Is that for all questions? What about those where it's the only tag? –  Lev Levitsky Feb 5 '13 at 18:38
    
@LevLevitsky That's for all regex questions. I don't know how to do a search for questions with only one tag. –  Bill the Lizard Feb 5 '13 at 18:42
    
@LevLevitsky - Whether the question was answered or not seems irrelevant to me. The success of the site is dependent not just on questions being answered, but answers being useful to future visitors. A regex question with no additional info about the tool will likely have no value to future visitors. –  JDB Feb 5 '13 at 18:45
    
SQL has the same problem. Lots of crossover between engines but some questions are dependent on the engines capabilities leading to pro forma comments for the op to specify the RDBMS. People have tried this request. Perhaps if you included SQL in your request it might be more compelling to show that this could be shared in tags that have this problem. –  Some Helpful Commenter Feb 5 '13 at 21:57

4 Answers 4

You completely misunderstand the concept of meta-tag. A meta-tag is a tag that provides no information about the subject of the question, but only about the question itself — something like or . is not a meta-tag. It doesn't match the two typical telltale signs of meta-tags either:

  • can be the sole tag of a question. E.g. “Can I write a regex to match balanced parentheses?” Regular expressions are a mathematical notion which is independent of any programming language. Some languages allow only a subset of regexps, others allow a superset; if you're not interested in those languages specifically, there's no need for a language tag. While most questions should have a language tag (if only to recommend another approach), this is not necessary.
  • is not ambiguous. It explains exactly what topic the question is about.

The difference between a and a is microscopic. There's no need to have different “regex for phone number” questions in each of these.

There's a lot of dross in the tag, but spreading it around won't solve anything. It's rather the opposite: there's not nearly enough closing of duplicates — and if you split the tags, that'll only make it worse.

share|improve this answer
2  
He's not asserting that it's a meta tag, he's asserting that it's a "dependent tag", which is a category of tags that Jeff discusses in his blog post that focuses on meta tags. That said, you are saying that it's not even a dependent tag, so your first bullet still addresses it. –  Servy Feb 5 '13 at 18:51
    
@Servy It's not a dependent tag either, again, because it has a clear meaning independent of any other tag. –  Gilles Feb 5 '13 at 18:52
    
Yes, I stated that you addressed that. The second half of your answer applies and answers the question, but the first paragraph largely doesn't and should be either removed or substantially edited because you're arguing against a point the OP isn't making. –  Servy Feb 5 '13 at 18:55
2  
Then why does the documentation for the tag say "There are many different dialects of regular expressions, all subtly different. Therefore, when asking questions, always include the tag for the specific programming language or tool (e.g., Perl, Ruby, Python, Java, JavaScript, vi, Emacs, sed, Lex, grep, etc.) you are using. Otherwise, you may get answers that won’t work for you." –  JDB Feb 5 '13 at 18:55
    
And also: "Today, we still call these pattern-matching languages regular expressions (or regexes for short), even if they may no longer be regular in the computer scientific sense." –  JDB Feb 5 '13 at 18:59
    
@Cyborgx37 That does apply to many of the regex questions, and it's best to have too much information than too little, so it's good to have this advice. That's no reason to split one concept into thousands of tags. –  Gilles Feb 5 '13 at 19:01
2  
While I agree that, in theory, regex could be used as an independent tag and that there are some questions for which is really can be the only tag, in the vast majority of actual existing uses of the tag, it's not appropriate as the only tag and is used in a dependent context, so for the purposes of this discussion, it really is a dependent tag, unless you are proposing that only tags that really are engine independent be allowed to use this tag. –  Servy Feb 5 '13 at 19:03
1  
@Servy You could say the same for list, algorithm, etc. Even the language tags are often not enough for a question. regex isn't the odd one out here. –  Gilles Feb 5 '13 at 19:05
2  
@Gilles I agree, which is why I'm saying that even though it's a dependent tag, that's fine and things can stay as they are. –  Servy Feb 5 '13 at 19:07
    
For the record - Servy is correct - I understand that regex is not a meta-tag. See my comment to Lev Levitsky's answer: "I don't think that regex is a meta-tag..." I take a bit of offense to that opening sentence. –  JDB Feb 5 '13 at 20:13
    
There is too much closing of duplicates. New users should be able to ask (and answer!) beginner questions exactly like old users did in 2009. –  Andomar Feb 6 '13 at 16:34
    
@Andomar Stack Overflow is a questions and answers site, not a discussion forum. Not asking and answering the same old questions over and over again is very much a goal of the site. –  Gilles Feb 6 '13 at 16:50
    
@Gilles: SO is also not a Wiki. As long as people enjoy asking and answering (NOT discussing), I think that's great. –  Andomar Feb 6 '13 at 16:55

While I agree that this is indeed a problem (and especially with ), I don't think getting rid of the tag completely would be a practical approach.

The reason for this is the amount of tags that, like , cannot (shouldn't) be the only tag on the question. Consider , , , , , etc. Probably, the majority of SO tags fall into the same category (pretty much everything except the language tags).

Taking this into account, I don't think it would be reasonable to undertake an insanely massive retagging of all SO questions (and I'm not sure it would even be deterministic). Also note that it would lead to a manifold increase in the total number of tags.

What could be done in my opinion is implementing some sort of constraint that would prevent posting a question if it's only tagged with "secondary" tag(s). Then this attribute of a tag (primary/secondary) could be subject to editing as a part of the tag wiki, for instance, or maybe with its own reputation requirement.

Note that the necessity of this measure is highly debatable, I am not exactly positive that it is needed, but it is what seems to be a sensible approach in my opinion.

Edit: in response to your edit, I agree that solution #3 (a pop-up or some sort of hint when tagging) would be the best.

share|improve this answer
    
I considered the "force a second tag" solution as well, and +1 for bringing it up, but regex is a bit different from a data format. It is a mini-language unto itself, and the concept of "secondary tags" runs afoul of the "dependent tag" issue mentioned. Clearly a non-ideal, realistic solution is called for, though. –  JDB Feb 5 '13 at 18:05
    
@Cyborgx37 If the purpose is to have all [regex] questions have language information in them, then it seems to me that my approach would serve the purpose just as well. –  Lev Levitsky Feb 5 '13 at 18:10
    
According to Jeff Atwood: "If the tag can’t work as the only tag on a question, it’s probably a meta-tag." and "If the tag commonly means different things to different people, it’s probably a meta-tag." While I don't think that regex is a meta-tag for other reasons, the above litmus test does suggest that a dependent tag is less than ideal. I still prefer your suggestion, though. –  JDB Feb 5 '13 at 18:22
1  
@Cyborgx37 This is likely one of those times where we say that even though it's a dependent tag, the problem(s) that result from it are not beyond what the site/community are able to address, and that the tag is providing more value than the problems it's causing. Because of that, unless things get worse, it's acceptable to keep this tag as is as an exception to the dependent tag rule. –  Servy Feb 5 '13 at 18:48
    
@Servy - I can accept that. Just wanted to bring it up for discussion (and because I'm getting really tired of quoting the regex tag documentation in comments). –  JDB Feb 5 '13 at 20:10

I think splitting the regex tag into multiple tags is overkill for a problem that already has a solution (add another tag). Splitting the tag would make matters worse for a large class of current questions tagged regex.

In this case, a general answer is provided which works with most regular expression flavors, but it's impossible to know if it will work for your problem since you may be using some weird regex flavor. It has very little value for other visitors and may even be perceived as 'wrong' if the visitor knows little or nothing about differences between regex implementations.

If the general answer works for most regular expression flavors, then tagging the question with a specific flavor still isn't going to help the person using some weird regex flavor, and it may turn away people who are using one of those more common flavors.

The following argument doesn't hold a lot of water either.

In some cases, however, an answer is offered (often by someone with little knowledge of regex engine differences) and, by luck of the draw, the given regex works with the OP's implementation. In such a case, you have something even worse then a question with no answers: a question with an answer that is virtually worthless to future visitors.

Except for all of the people that it does work for. That's not worse, it's better. If someone using a different flavor of regular expressions finds that answer, they can ask a new question (tagged appropriately) about why it doesn't work for them.


I wouldn't be against suggesting that a user add another tag (or even forcing them to) if they try to post a question with only the regex tag. People are already doing this in comments, so we might as well automate it to make it a little bit easier to answer these questions to begin with. However, I think splitting 50,000 questions into many different tags would cause more problems than it solves.

share|improve this answer
    
I agree that splitting tags is undesirable. +1 for "People are already doing this in comments, so we might as well automate it to make it a little bit easier to answer these questions to begin with" –  JDB Feb 5 '13 at 19:49

The SQL tag is like regex in this regard. There are many SQL dialects and many queries are written quite differently in MySQL or SQL Server.

This is not much of a problem as most questions include an example query or client technology that gives away the dialect. (F.e. "top 1" vs "limit", and C# usually goes with SQL Server.)

You could reduce the number of missing dialect tags by adding a prompt or hint on the Ask Question page. But asking a question is already quite hard enough. IMHO the minor benefit of specifying the dialect does not justify additional complexity on the Ask Question page.

share|improve this answer

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .