Oddbean new post about | logout
 Share more of your code with it. I've found it needs more of the full scope of the code to adequately help you. 

Also, it will try to answer a question even if it's illogical. For example, I asked it to help me do something that my server already did automatically, but I didn't know that. So instead of saying "your server does that automatically" it tried to answer the question with code and resulted in all kinds of bugs. 

It can't really think outside of the scope of your question right now. Still limited, but still useful. 
 I treat it the exact opposite. I do all of the design and planning and have it crank out code, syntax, and comments smaller pieces at a time.

My typical prompts look like this.

-Write me a function that takes these input params and has these returns. Remember to use functions x, y, and z that we wrote earlier in your solution.

-update this function to change it in this way.

I find asking it bigger picture questions or for bigger changes at once leads to more useless responses.

Also, try claude 3.5. I like the claude 3.5 code context in kagi far more than gpt 4o for code.

Forces me to not spaghetti everything this way and if you add it to your context it will comment as it goes. Both are nice bonuses. 
 Good tips, thanks!