5 ms·
Show HN: Captain Stack – a parody version GitHub Copilot
- hieu229 5y agoCopilot is trending and I thought I'd make something for fun. Captain Stack is a VSCode extension that mimics Copilot's code suggestion feature. But instead of using AI, it filter search results on Google and return a list of code suggestion option It was meant for fun. Though I realized this method is quite effective since that's just what devs usually do Feedback and question are welcome
- svantana 5y agoNice work! I would assume something like this would quickly run into rate limiting on google, does that happen or did you do something to mitigate?
- hieu229 5y agoI'm not entirely sure, I had a look but didn't find anywhere mentioned about it. The extension run in nodejs environment, and use fetch-node to get page content. I assume it's similar to how someone use google on broswer
- GistNoesis 5y agoThere is always the option of downloading a data dump from https://archive.org/details/stackexchange https://archive.org/details/stackexchange indexing it and querying it. You can even make your tool offline and private :) Add a few transformers on top, and you can have it generate dubious code. Though if you want to be competitive you'll probably need a few phd and M$ of computing resources or use some free tpu like https://colab.research.google.com/ https://colab.research.google.com/ and hope to not get rate limited :)
- deleted 5y ago[deleted]
- hieu229 5y agoGood suggestions. Another one to consider is Google and Stackoverflow offical API
- orionblastar 5y agoIn past jobs I used the Internet and MSDN and Google to research problems and debug them. Management didn't like me using the Internet even if it was job related and it would take longer to debug without looking stuff up. Captain Stack would search Google for me, racking up Internet time, which I would get in trouble for. It is a tool not a toy, I use the Internet instead of reading books because books are outdated as soon as they are published.
- quickthrower2 5y agoA dev job where you can’t use the internet :-0
- hieu229 5y agoThat's harsh. If you think you could use it and have suggestion, let's open a thread on Github and discuss
- orionblastar 5y agoIt was a law firm that knew nothing about design, research, debugging, etc. I might be able to use it if it pulls legit code, and not joke code.
- hieu229 5y agoThe results are actual answers from StackOverflow. The problem it has now is sometimes, answers can be the actual code. Or sometime, the answers is about explaining something (the code on those answers are not whole). Besides, VSCode isn't officially support inline-completion yet. So this extension can only run on VSCode Insider for now That said, the code is no joke
- quickthrower2 5y agoYou say “parody” I say “this could be actually useful!”
- mechero 5y agoHey this is great! It even checks if answers have the checkmark so it's not just a random code block. I think it would be even better if you insert also a comment line with the link to StackOverflow, so devs can check it to get the full context.
- hieu229 5y agoGreat idea. I'll add it
- slava_kiose 5y agoVery funny )