Earlier quoted context omitted.
Sourcegraph had to have known GitHub would do this if they didn't accept the offer. Since this should be expected, the launch of this feature shouldn't change what their decision should have been.
Sourcegraph CEO here. Just to be clear, so internet rumors don’t get started, there was no “offer” here. We started Sourcegraph with the intent of remaining independent because building really good code search and intelligence means working across all code (not just on GitHub), all devs, and all code intelligence sources (code nav plus every dev tool you use that knows stuff about code, not just the ones in the GitHu…
The technology behind GitHub’s new code search
181–187 of 187 posts
Re: The technology behind GitHub’s new code search
#182> Just use grep? First though, let’s explore the brute force approach to the problem. We get this question a lot: “Why don’t you just use grep?” To answer that, let’s do a little napkin math using ripgrep on that 115 TB of content. On a machine with an eight core Intel CPU, ripgrep can run an exhaustive regular expression query on a 13 GB file cached in memory in 2.769 seconds, or about 0.6 GB/sec/core. But you don't…
Re: The technology behind GitHub’s new code search
#183Earlier quoted context omitted.
It's simple enough that most IDEs implement it. Take from that what you will.
The fact that most IDEs implement it doesn’t mean it’s trivial. I believe most IDEs leverage “language servers” written ~once per language and used by many IDEs. It’s possible GitHub could also leverage those language servers (which would be super cool) but doing it at GitHub scale is certainly not trivial. Poor man’s version using the new GitHub search would be to construct a regex that matches one but not the other…
Re: The technology behind GitHub’s new code search
#184https://grep.app
Re: The technology behind GitHub’s new code search
#185The sparse grams solution to deal with stupidly common ngrams such as for or tes is very interesting. I’d love to see more discussion on how they are dealing with the false positives though. It looks like a positional index is being used to achieve this, but that usually blows out your index size. Additional information about deduplication would be especially interesting to me as well. It seems to solve this quite we…
> What I find really interesting about all the code search engines I know of is that each one implemented its own index I mean GH got a long way using ElasticSearch until now.
I'm not sure that's true. It used ES for a long time, but the search was also terrible, at the edge of complete uselessness.
Re: The technology behind GitHub’s new code search
#186I’ve been using the new code search for a couple of months and I like it, but the UI is kind of antagonistic to how I typically want to search for things. For one, the new experience doesn’t actually load code onto the page, it does some sort of lazy loading thing as you scroll around, so ⌘F doesn’t work. I understand that there’s a custom search box to try to get around this but it’s pretty slow and fiddly and I don…
Hey saagarjha, thanks for the feedback. It's our goal to make the experience as good as possible, and we're aware of shortcomings with cmd+F and `t`, among other things. We're working on it, and your feedback helps us a lot. We read all the feedback on the forum here: https://github.com/orgs/community/discussions/38692 , so please keep providing it. Videos and screenshots are super helpful too. Thanks for bearing wit…
Re: The technology behind GitHub’s new code search
#187I'm curious if they'll open source Blackbird, it does not seem mentioned in the post.