• (disco)

    That's some awesome regex abuse.

  • (disco)

    Names are notoriously hard to connect to genders. Ask Chris, Sam, Alex, Morgan, Tracy and about 100 other names.

  • (disco)

    Maybe they average 50% accuracy. They'd return the correct result for me. But fail for females that have a suffix with my name.

  • (disco) in reply to Nprz

    The start of the "female" regex is particularly awesome: (a|i|

  • (disco)

    Where is the WTF? This is bulletproof code!

    yours, Conchita Wurst

  • (disco)

    Obligatory "But what about asian names and their unicode characters"-comment. This function does NOT return an empty message when Unicode is involved. This is so wrong!

    Maybe the function is only used as a suggestion to preselect a field?

    Also: Where are the Commenters who always do everything better? I need to see WTF-Code-Comments :cry:

    Filed Under: And what about people who don't want to be put into a gender category! Clearly WTF!

  • (disco) in reply to Kuro
    Kuro:
    Filed Under: And what about people who don't want to be put into a gender category! Clearly WTF!

    What about those people who fit in multiple gender categories? hmm?

    ;-)

  • (disco)

    Brent's co-worker then went on to solve the halting problem. (Turns out you just need to use regex to analyse the program's code, Alan.)

  • (disco)

    Fixed it to pass all of my test cases:

                  var regex = "";
    
                  regex = "(ua|pher|andy|elijah|keith)$";
                  if (REFindNoCase(regex, Arguments.name)) {return "male";}
    
                  regex = "(a|i|y|ah|ee|et|ette|elle|fer|ine|lyn|ie|anne|een|en|er|yn|ynn|kim|rachel|lind|pam|sue)$";
                  if (REFindNoCase(regex, Arguments.name)) {return "female";}
    
                  return "male";
    

    It's easily extensible at least.

  • (disco) in reply to Keith

    umm.... you would have fallen into the male case anyway. the female regex doesn't match your name.

  • (disco)

    I like the fact that the 'female' regex looks for fer$ and then later for er$ And how a f*ckton of nicknames and diminutives are going to come out as female regardless of the name they're derived from. And all the almost-unisex names that are differentiated by ending in -y or -i.

    @Keith the original would have returned 'male' for Keith anyway.

  • (disco) in reply to accalia
    accalia:
    umm.... you would have fallen into the male case anyway. the female regex doesn't match your name.
    CarrieVS:
    @Keith the original would have returned 'male' for Keith anyway.

    Pesky dollar sign...

  • (disco)

    There was a ruby gem called sexmachine that gave you a gender based on a name (with a very extensive database). It was renamed gender_detector after feminists complained. Go figure.

  • (disco)

    CF is constructed out of sin and unicorn tears

    :sagittarius: LMFAO :cancer:

  • (disco) in reply to anonymous234
    anonymous234:
    There was a ruby gem called sexmachine that gave you a gender based on a name (with a very extensive database).
    At least it seems to handle dual-gender names correctly (by returning “i don’t know”)
    anonymous234:
    It was renamed gender_detector after feminists complained. Go figure.
    In fairness, `gender_detector` seems a bit more descriptive to me...
  • (disco)

    ...|sue)$"; if (REFindNoCase(regex, Arguments.name)) {return "female";}

    https://www.youtube.com/watch?v=WOHPuY88Ry4

  • (disco)
     regex = "(a|i|y|
    

    Hey @Remy.

  • (disco)

    Congratulations: this must be the worst idea of 2014.

  • (disco) in reply to YellowOnline
    YellowOnline:
    this must be the worst idea of 2014.

    What about using Discourse for TDWTF and the new Sitedesign?

    Filed Under: We need a focus group to decide on the worst idea ever... and this idea is a participant!

  • (disco) in reply to YellowOnline
    YellowOnline:
    Congratulations: this must be the worst idea of 2014.

    hmmm without knowing whether it was used for (in roughly least to most WTF order)

    1. Filling gender field when user declined to answer (with appropriate notation of course)
    2. Filling gender field when user declined to answer (without appropriate notation)
    3. Filling gender field with a default value that user can override
    4. Filling gender field and not allowing user to override
    5. Deciding what gender the user is without asking them at all

    it's hard to say if it is the worst

  • (disco) in reply to Maciejasjmj

    And Andrey|Andrei (depending on how you spell it), Larry, Bobby.

  • (disco)

    It's not often that bad code makes me twitch. I twitched this morning.

  • (disco)

    Tried this on the top 100 baby names of 2013. Female names categorized as male (all by the default case):

    madison london scarlett peyton lillian alexis vivian alice reagan penelope addison grace charlotte taylor chloe zoe abigail elizabeth allison claire

    Male names categorized as female:

    parker noah aiden eli tyler hunter brayden isaiah alexander brody asher carter bentley jeremiah oliver micah camden caden riley anthony josiah zachary henry owen levi cooper jayden charlie xavier

    Male names actually caught by the first regex:

    christopher elijah joshua

  • (disco) in reply to accalia
    1. It's quite fragile, as others have pointed out -- there are cases that can fall through both regexes (loads of pseduonyms and foreign names) or get trapped by the wrong regex (Warrens and Walters get made out as ladies by this, which'd insult at least one multibillionaire on this planet!)
    2. What sort of demented business "requirement" spawned this idea in the first place? Many systems shouldn't care about gender, at least not directly. For instance: if you want the proper honorific for addressing someone, just ask them for it instead of guessing based on gender!

    Filed under: your CEO just walked into your office to report a bug

  • (disco)

    Maybe they are located somewhere where everyone's name is Elijah, Joshua and Christopher?

  • (disco)

    Some people, when confronted with a problem, think "I know, I'll use regular expressions." Now [spoiler] That's Sexist! [/spoiler]

  • (disco) in reply to tarunik

    well even in the least WTFy case it is pretty WTFy

    as for why it's abusiness requirement? Marketing. turns out marketers want to know gender as that actually turns out to affect how one responds to marketing in a huge way (good luck categorizing me!)

    we actually do this in our code base for that. users are asked gender but are given an option to decline. if they decline the system will take a variety of factors (name, interaction history, birth date, purchase history, etc) and guess a gender (it is marked as such so marketers know not to rely on it if they interact with the customer directly)

    all guessed genders are recalculated once a month as user interactions continue and the guess can be refined (usually) after a year the guess has either settled down to +98.5% confidence or the user is permanently marked undeclared.

  • (disco) in reply to accalia
    accalia:
    good luck categorizing me

    Google used to have a page where you can check what data they think they know about you. It had me down as male. I was not surprised.

    Aha! Found it again: https://www.google.com/settings/u/0/ads?hl=en&sig=ACi0TCh69_tuf-Y72cXyHhgWY21WyU1zY_JLM9KoSmukS_8ryX1KpIX_VJze8HVhePHzfIoMlI5JnQfhBfumhKkmteWyqLNhpV231X6lBX44ISZ-ujKcdomle3h4ZISyuBEkoU5AowuFfsvyl_rs6AqyzU8A_PID8vOhS0qdin4bAd_YneI31-6qr0GOT7Ej4Kos4kVi3d7v

    (You'll want to be logged into a google account to see it)

  • (disco)

    My name is Andyelle, you insensitive clod!

  • (disco) in reply to Yamikuronue
    [image]

    :laughing: even google can't figure me out! awesome!

  • (disco) in reply to BobbyTables
    BobbyTables:
    Larry
    And Curly, too. Thankfully, Moe is still male.
  • (disco) in reply to accalia

    To be fair, it had me as male back before Google+ existed, so it didn't have my gender from me at all. Now it says I'm female based on my Google+ profile that says I'm female, and it has my age correct as well.

  • (disco) in reply to Yamikuronue

    i never told G+ my gender. it does have my age though so i'm surprised the range of age is so wide.

  • (disco) in reply to accalia

    I think the age is one of several preset categories for marketing reasons.

  • (disco) in reply to Yamikuronue

    You gave google correct information out of your own free will? Not thats TRWTF here!

    Filed Under: We should totally find out what algorithm google uses for guessing the gender. It's probably stereotypical and sexist

  • (disco) in reply to Kuro

    It's definitely sexist. I think it had me as male due to my interest in IT topics. It's certainly not sports, and I don't google beauty or child-related products often either.

  • (disco) in reply to BobbyTables
    BobbyTables:
    And Andrey|Andrei (depending on how you spell it), Larry, Bobby.
    Don't forget the Italian version of Andrew: Andrea. (Doesn't help that in English, that's the correct spelling of a girl's name that sounds at least similar to the way Italians would pronounce Andrea (for them a boy's name).)

    And of course this would class me as female, which I'm not. (In my case, "Steve" is "Stephen", and names ending in "en" are female names according to this code.)

    There are also many inconsistent treatments of variants of the same name. "Anne" gets "female" but "Ann" gets "male". In the same way, "Susan" is male while "Susanne", "Suzanne" and "Sue" are female. And "Kate" and "Cathy" are male, while "Katy", "Katie", "Katherine" and "Catherine" are female, while "Katyusha", of course, is a Multiple Rocket Artillery system. Joshua is correctly categorised, but Jeremy is not and nor are, say, Mandy, Peter, Ken, Kim (when short for Kimball), Lee (when Lee is a man).

    7/10 Would WTF again.

  • (disco) in reply to Yamikuronue

    hmm.... actually apparently i did answer the question at some point...

    [image] Linky

  • (disco) in reply to Yamikuronue

    Google thinks I speak Polish. [image] I doubt and if I do it won't be very polished.

  • (disco)

    According to the WTF code, my given name Timothy is female.

  • (disco) in reply to mott555
    mott555:
    my given name Timothy is female.

    Maybe it's time to let that inner female out?

  • (disco)

    As a guy who has been using Cold Fusion for 10 years, I can say that CF is like any other language, you can do powerful elegant things with it, but it will not stop you from doing cringe worthy things either. BTW Cold Fusion is all Java underneath.

  • (disco) in reply to Yamikuronue
    Yamikuronue:
    I don't google beauty or child-related products often either.

    Maybe, but you google for cupcakes a lot.

  • (disco) in reply to Yamikuronue

    http://i.imgur.com/3GD7oUH.png

    Damn, do I really look that old?

  • (disco) in reply to faded
    faded:
    BTW Cold Fusion is all Java underneath.

    Yeah, but it doesn't write like Java at all. It's highly bastardized.

  • (disco) in reply to accalia
    accalia:
    as for why it's abusiness requirement? Marketing. turns out marketers want to know gender as that actually turns out to affect how one responds to marketing in a huge way

    Marketoids. I'd rather deal with a tailoring algorithm that simply looks at my purchase and interaction history than have the systems WAG genders for the purposes of tailoring marketing.

    accalia:
    we actually do this in our code base for that. users are asked gender but are given an option to decline. if they decline the system will take a variety of factors (name, interaction history, birth date, purchase history, etc) and guess a gender (it is marked as such so marketers know not to rely on it if they interact with the customer directly)

    all guessed genders are recalculated once a month as user interactions continue and the guess can be refined (usually) after a year the guess has either settled down to +98.5% confidence or the user is permanently marked undeclared.

    At least you're able to make it so that the guesswork a) isn't completely fragile, and b) is *marked as such*. I can only imagine the torrent of WTFs that'd pour forth if people used the guess as gospel...
  • (disco) in reply to tarunik
    tarunik:
    torrent of WTFs that'd pour forth if people used the guess as gospel...

    we're talking about marketers.... they only see what they want to see...

    we lost a few contracts because of that. that's why we stopped showing the guessed genders to front end marketers....

  • (disco)

    Did anyone click on the word "Discourse" in the article ???

  • (disco)

    "Sandy is a boy's name." -- from the html comments... True unless you're Sandy Duncan e.g. When Sandy is the abbreviation for Sandra.

  • (disco) in reply to deadman
    deadman:
    Did anyone click on the word "Discourse" in the article ???

    No, given that it isn't there. Now, if you'd said “ColdFusion”…

Leave a comment on “Genderize”

Log In or post as a guest

Replying to comment #:

« Return to Article