[HN Gopher] Show HN: ChatGDB - GPT-Powered GDB Assistant
       ___________________________________________________________________
        
       Show HN: ChatGDB - GPT-Powered GDB Assistant
        
       ChatGDB is a tool designed to superpower your debugging experience
       with GDB, a debugger for compiled languages. Use it to accelerate
       your debugging workflow by leveraging the power of ChatGPT to
       assist you while using GDB!  It allows you to explain in natural
       language what you want to do, and then automatically execute the
       relevant command. Optionally, you can ask ChatGPT to explain the
       command it just ran or even pass in any question for it to answer.
       Focus on what's important - figuring out that nasty bug instead of
       chasing down GDB commands at the tip of your tongue.  See it here:
       https://github.com/pgosar/ChatGDB
        
       Author : pgosar0514
       Score  : 67 points
       Date   : 2023-04-07 16:56 UTC (6 hours ago)
        
 (HTM) web link (github.com)
 (TXT) w3m dump (github.com)
        
       | eloff wrote:
       | Is there something like this for the command line in general? I'd
       | love to have a ? command that takes an optional prompt and feeds
       | my current shell history to chat gpt and gets a recommendation
       | for the last command that failed.
       | 
       | Something like https://github.com/nvbn/thefuck but with some
       | intelligence instead of hard-coded rules.
       | 
       | That's somewhat problematic if you have secrets in there, but you
       | could just not use it if you know you have sensitive things in
       | your shell history. You still need to be aware of that without
       | ChatGPT since most systems save your shell history to the file
       | system where it could remain accessible for much longer than
       | you'd think. IIRC they don't use things from the API for
       | training, but I wouldn't depend on that being safe.
        
         | atarian wrote:
         | Sounds like Copilot for CLI:
         | https://githubnext.com/projects/copilot-cli/
        
         | danielvaughn wrote:
         | Security isn't a problem if you're running the model locally. I
         | came across this project and would love to build an embedded
         | version: https://github.com/BuilderIO/ai-shell
        
         | mpeg wrote:
         | Warp Terminal has an AI command search built in, using natural
         | language. It's pretty nice, if you can get past the fact it
         | requires an account to use it and it's not OSS
        
       | [deleted]
        
       | jmmv wrote:
       | "ChatGDB, find me the memory leak!" is what I would want to say!
       | Not really dictate commands I don't know I may even need.
        
         | mathisfun123 wrote:
         | https://github.com/openai/triton/pull/1358#issue-1628393794
         | 
         | >One fun thing - after tracking down the code to the block of
         | C++ code, ChatGPT-4 is what actually found the memory leak for
         | me :)
         | 
         | although I can't imagine what the prompt was.
        
       | rgovostes wrote:
       | Seems like it would be very useful to feed it context about the
       | state of the program and ask it to decompile disassembly, explain
       | what kind of fault happened based on clues left in the register
       | state, etc.
        
         | pgosar0514 wrote:
         | Right, I was heavily considering adding that in, but at least
         | for now I elected not to since it would be rather unwieldy to
         | send enough information to output useful information. Not to
         | mention GPT-3 isn't the best at giving you correct information
         | on why your code is broken in most cases.
        
       | great_psy wrote:
       | Did anyone use this for an actual project. I am wondering how
       | those chatX applications actually help.
       | 
       | When I had to use a dissasembler the issue was not commands,
       | because those become muscle memory after a few hours of use. (LLM
       | solutions are anti muscle memory because for the same prompt you
       | can get diff results)
       | 
       | The issue I had was wrapping my brain around what is actually
       | going on, keeping track of pointers, addresses and so on.
       | 
       | Maybe this chat solution can help with some of that, but I often
       | am not sure what I actually am looking for so I can't ask for it.
       | Until I gets to "fix the bug/ find the overflow" I just don't see
       | the extra value.
        
         | eloff wrote:
         | I use gbd so rarely that I often forget the commands between
         | sessions. Then I use print debugging when it's not the best
         | tool just because I don't want to lookup the commands. I could
         | see the use for this kind of thing.
         | 
         | Same problem when coding shell scripts. It's like they tried to
         | invent the hardest to remember language. I often use python
         | instead of bash just because I can remember it and read it.
        
       | Buttons840 wrote:
       | GTP man pages would be awesome. This is pretty close to that for
       | GDB. Although I suspect this is a limited view of the
       | possibilities akin to thinking "the internet sounds neat, I can
       | use it to find new pen pals".
       | 
       | It also makes me wonder if the command line will return as the
       | premiere PC interface. Why would I want to use your web page with
       | all its lovely design and branding when I can just ask the
       | command line to show me the information the way I want?
        
       | winstonprivacy wrote:
       | Ok, this looks pretty slick! I'll try it out next week as I have
       | a few seg faults I need to figure out.
        
       | intalentive wrote:
       | Good looking terminal output. I like the font and color theme.
        
         | avargas wrote:
         | I believe it's Solarized Dark. The font I don't know
        
           | pyjamafish wrote:
           | I recognized the 'g' and 'r' from Fira Mono, but from the
           | slashed zero and ligatures (the raised x in 0x), I think the
           | font is Fira Code[1].
           | 
           | I don't think the color scheme is Solarized Dark. Looks
           | closer to Nord[2].
           | 
           | [1]: https://fonts.google.com/specimen/Fira+Code?preview.text
           | =(gd...
           | 
           | [2]: https://github.com/nordtheme/terminal-app
        
       | amelius wrote:
       | Also give me ChatAPT, the tool that helps you when your Debian
       | package manager is in a broken state. And similar tools ChatPIP
       | and ChatConda. Hell, just give me ChatAdmin.
        
         | aliasxneo wrote:
         | Feels like the dotcom phase all over again. Next is
         | ChatWithDominoPizza.
        
           | zamnos wrote:
           | Hilariously, one internal version of Bard really really
           | wanted to send you a pizza. My guess is it was trained on the
           | ositivity of /r/Random_Acts_Of_Pizza/, but who knows?
        
         | pgosar0514 wrote:
         | Actually, that might be a future project! I am a bit worried
         | about how much data I'd be sending on each request and how that
         | may eat into tokens though, especially for more troublesome
         | issues.
        
           | jazzyjackson wrote:
           | Yes I'm trying to catch up with the llama crowd - I wouldn't
           | mind giving recursive shell access to a locally hosted,
           | offline language model. On the other hand, hooking up a
           | networked LLM to your networked shell is essentially a RCE by
           | design
        
       | agentwiggles wrote:
       | Haha, that is really cool. However this is one of those things
       | where I have no idea how to tell if ChatGPT is bullshitting me
       | because I don't know how to GDB on my own.
        
         | furyofantares wrote:
         | It's also the type of thing where it's extremely unlikely to
         | bullshit.
         | 
         | And ALSO the type of thing where I think you can work out if
         | it's bullshitting you on your own; if it works, it's not
         | bullshitting.
        
       ___________________________________________________________________
       (page generated 2023-04-07 23:00 UTC)