So one day I was stumped in how to make this signal useful and Amit suggested, hey why don't you take the square root. I was like, why a square root, it doesn't make much sense, nothing is getting squared ever, and he went up to the whiteboard and just drew a square-root-ish-wiggle-arc-shape and said look you just want something that looks like this. Square root, log, whatever.
I was like, oh... am I allowed to write code that doesn't make any sense? I thought I wasn't supposed to do that. And he was just like, well, just don't worry about it, you are overthinking it, you can take all the square roots you want, multiply by 2 if it helps, add 5, whatever, just make things work and we can make it make sense later.
At that point I realized that real world software engineering was much different than research had been, and also that this was going to be way more fun.
A few years later I did a PhD in Information Retrieval doing the same kind of things, like it was an art and always exploring new metrics and ideas. I do miss those days, but it is hard to find remote work in this area (IR/NLP)..
LOL. I can TOTALLY hear his voice in my head.
"Here's how you solve it: the angle of the pendulum from vertical is sin(x), which will always be small, so substitute x..."
"Wait, you can't do that! sin(x) isn't equal to x."
"For the purposes of this problem set it is..."
I had a lot of trouble with this when I first started physics. I was used to thinking of mathematics as Platonic Truth, the eternal mysteries of the universe rendered absolute. But it's not - it's just a model, and it's a model that we use because in most cases it approximates reality pretty well. Contrary to the advice of many primary-school math teachers, sometimes it only matters whether you get the right answer rather than whether your reasoning makes any sense.
http://nlp.stanford.edu/IR-book/
A quick glance through it made me think there's a lot of tricks that are commonplace at Google but not mentioned in the text, but I'm not sure how many of them are proprietary, so I think it's safer for me not to mention them. TF-IDF, however, has a whole Wikipedia article about it: