Hacker News new | ask | show | jobs
by nomel 1168 days ago
I don't see any iterations. I can sometimes get it to improve the code just by telling it that there's a problem, or to identify any problems.

> it's not clear if GPT will have sufficient attention to handle the more complex cases.

I think this could be helped with some tooling, by giving it smaller pieces of code to digest, in a new prompt and a somewhat smaller prompt. These LLM can't seem to dive into cracks if the context isn't constrained to that crack.

2 comments

Do you have access to the code interpreter alpha? You can upload larger chunks of code and have it perform different tasks. One of the interesting features is that chatgpt will sometimes have some issues with its own code (python) and try to automatically correct itself.
I wish I had access to the plugins, both as a user or developer. I hate the feeling of being on the outside of the latest developments, nothing feels open about a OpenAI.
Aside from the fact you can access it at all you mean?
> just by telling it that there's a problem

how will you identify that there's a problem?

Well in a lot of cases the model is writing code that can't even be run (the red dots). Feeding it the compilation error can be done automatically and it will usually be able to at least get it running.
The last time I asked ChatGPT to write a function that I needed, it was syntactically correct right off the bat. I thought that even if it had logical errors, it would be easier to fix them one by one. It seemed like a plausible approach to take when dealing with writer's block.

However, after spending about 20 minutes fixing the details, I realized that the core logic was missing. I had only wasted precious time that I could have spent figuring it out myself.

[This comment brought to you by ChatGPT - I asked it to write a second draft of my original comment]

To answer your question from a practical perspective, you can try to run it, and feed back errors. See: https://news.ycombinator.com/item?id=35446171

But that's actually not what I meant. You can often just tell it "there's a problem, please fix it", or "do you see any problems" and it will be able to identify it without additional input. There no requirement that you've identified a problem, it's more of a "double check that" type of prompt.

especially as a new developer that now thinks they will never have to write any code