Questionable content, possibly linked

More thoughts on coding with ChatGPT

It’s funny yesterday I was looking around for videos about coding with ChatGPT from a “no code” perspective (or rather for people who don’t already know how to code – no know code?), and it was funny to me that two month old videos on the topic are already hopelessly out of date. Seeing those, it’s like thanks for the tips grandpa.

Also of note in that pile of search results is in casual skimming, it seemed like almost every one of the videos I watched was by somebody who already has somewhat advanced knowledge of coding/programming/engineering/computer science. There was no one I could relate to from my now decades old base of antiquated hand-crafted HTML & CSS knowledge.

The single thing I probably find the most frustrating in the coding with ChatGPT experience is actually not the errors or small harmless mistakes it makes. It is instead its habit of accidentally removing blocks of your code when it spits back out “corrected” versions of things.

If you’re chasing down a solution to a (different) specific bug, it might go unnoticed by you for some time that a couple of buttons have been removed. By then the content of your functions may have been changed, and references to them removed. Then you have to (gently) berate the model until it brings back the functionality you had before that was working perfectly fine but was removed for some inexplicable reason… The circle goes round and round.

I’m not sure how to correct for that, but it’s a major issue for my current learning process….

Integrated coding assistant

Through this experience, I’ve started to visualize in my mind’s image diffusion model what it might look like, how it might function, to have a chat assistant integrated into a coding program/development environment. I’m not that up to date on all the preferred terminology and technology and methods in all this stuff. In a way, that’s what’s appealing to me about using ChatGPT as a non-coder to code different creative production utilities: I don’t have to be. If I want to learn about any specific aspect of it, I can drill down on a problem, ask the model questions, etc. But I don’t have to know how it all works, just know that it works. As I gain experience working with it, anyway, I know the rest will come.

So what would a coding app with a chat assistant look like? I figure, broadly, a pane on the left with the chat conversation, and a pane on the right with the code. I tried getting ChatGPT to build it already, but it looks like it will take a little leg work. I’m up for it now though. I don’t know how it all works, but unlike before with “pure” coding, I never felt like it was possible to break through all the bazillions of road blocks to doing the thing I wanted to do. And hence it stunted my ability to visualize in that direction. But now, I know if I plod along, and am patient with all the errors and code drops, I can probably kinda sorta get there in a relatively short time. A few days of tinkering – but the fun kind of tinkering, not the horrible torturous kind.

Functionally, you could describe in chat what you want to build and how it should look & work. It would render the code right into the code pane, with comments & a chat explanation. You could manipulate the code yourself directly, or ask it to change in chat. It would highlight what it is changing & why, ask for permission, and keep prior versions. It could also optionally offer suggestions for improvements or warnings if it looks like your code might have an error.

The chat assistant, to make it more explicit, would always have access to an up to date version of your code, so you’re not constantly having to cut and paste back and forth. And it’s not making suggestions to you based on code that’s now out of date. I think this is part of the cause of (some of) the code bits getting dropped in transition.

Anyway, then you could preview the code in a browser, and the chat assistant would also have access to your error messages without having to copy paste those back and forth too. Really, all the copy pasting is the most annoying bit of how it all works with them as separate tools right now.

An advanced version might also let me select items in the preview, and say “make this work like this” in chat, and then code would be updated to reflect that.

It sounds like a big project with a lot of moving parts for a total novice, but I might at least try to carve off parts of it until someone else can do it better. It seems like a no brainer set of tools to have!

Previous

Truth, Lies & APIs

Next

Content Labeling & Magritte

1 Comment

  1. Tim B.

    looks like copilot x from github is going to be basically what i was saying, the chat baked right into the development environment

    https://github.com/features/preview/copilot-x

    im ready to try when avail

Leave a Reply

Powered by WordPress & Theme by Anders Norén