Live data from Hacker News

Improvements to searching for special characters in programming languages

blog.google

1–10 of 30 posts

Re: Improvements to searching for special characters in programming languages

#2
Only very slightly related:

When I was a teenager I made music under the name shark^^bait

The ^^ is what made it stand out from others.

The issue is there is no efficient way to search for that phrase with the special characters.

I have no idea if I can still find the absolutely god awful music I made back then.

Using the phrase match in google just searches for sharkbait which doesn't help at all.

It doesn't help that years later a little movie called Finding Nemo came out.

Re: Improvements to searching for special characters in programming languages

#5
I can now find the C+@ programming language. So it's not heavily special cased for common programming languages.

Google Code Search (2006-2013) [1] was more useful. I miss that. Its search allowed regular expressions.

[1] https://en.wikipedia.org/wiki/Google_Code_Search

Re: Improvements to searching for special characters in programming languages

#7

To make this change at Google's scale is a triumph. Even dealing with this type of tokenization on our vastly smaller document set can be challenging.

Genuine question: why should this be any more difficult than searching for any other type of character? I've long found it hard to understand why Google is so bad at searching for non-alphanumeric characters.

Re: Improvements to searching for special characters in programming languages

#8
This is great. I feel Google has slowly become too user friendly. My mobile results are always way less technical than my desktop results. If I'm in the car (passenger) and want to look up a problem I'm having while programming, I get mostly related queries that are a simplified version of what I'm looking for.

I really believe that the technical crowd drives what becomes popular (app recommendations for family and friends). I feel a lot of the "Google hacking" queries have become less obvious and the search bubble stuff was getting bothersome. This is definitely a step in the right direction. Hopefully I'll be a little less frustrated with results in the future.

Re: Improvements to searching for special characters in programming languages

#9
post #8

This is great. I feel Google has slowly become too user friendly. My mobile results are always way less technical than my desktop results. If I'm in the car (passenger) and want to look up a problem I'm having while programming, I get mostly related queries that are a simplified version of what I'm looking for. I really believe that the technical crowd drives what becomes popular (app recommendations for family and f…

I don't think the term user friendly is the right term. More like they have been targeting a different user over the years (also the content on the web has exploded).

Although most of the time Google will give me technical results if I can coax it.

Re: Improvements to searching for special characters in programming languages

#10

To make this change at Google's scale is a triumph. Even dealing with this type of tokenization on our vastly smaller document set can be challenging.

Genuine question: why should this be any more difficult than searching for any other type of character? I've long found it hard to understand why Google is so bad at searching for non-alphanumeric characters.

When indexing documents (and querying for them), there is a process the terms go through, to split them up and then normalize them so they can be found easier. A trivial example is you want to find "can't" when someone searches for "cant". Typically special characters are removed for several reasons: the vocabulary of terms becomes smaller and saves space and time, you can ignore punctuation (like searching things that jut against parenthesis), you can remove accent marks and diacritics, and a host of other things.

This is hard because (a) you have to have contextual awareness of punctuation in certain places, like the '&' character in john&jane vs the logical &&. (b) your vocabulary of terms becomes larger - which is probably not a big deal for most folks but if you are Google then a 0.0001% increase in the vocab is a killer in space.

--EDIT-- The vocab increase is probably not as much as I noted above - but even adding a dozen terms can have an impact at Google's scale.

Post reply on HN