When I read one of these articles or posts, I usually expect to see concrete prompts, their output, and how they can be used to speed up development. Instead all I see is generic vagueisms; "it helps me write unit tests", "it helps me code faster", or in the case of this article "it’s taken over how I plan, design, and implement software." with little to no real examples of how this works. It almost feels like people want to brag that they've discovered "the secret sauce" rather than help others understand how to use it.
I've tried multiple times now to use ChatGPT. In every case ChatGPT has produced code that has bugs, needs to be double checked, or simply straight up doesn't work. It IS impressive how it's able to create code that seemingly does what you ask, and it's lightyears ahead of other products, but in no way have I found it to be a gamechanger. IMHO, at best it might steer me in the right direction, and at worst it completely wastes my time. Seems pretty overhyped to me.
In several occasions it has produced code that took me longer to fix than just reading the documentation and in almost all of those cases it couldn't help me find the issue and I actually had to read the documentation anyway (it took just seconds to pinpoint the missing clue).
Something it seems really good at is unix commands (regexes, awk expressions, pipes and bash intricacies) so I do use it a fair bit for that.
I don't use it to write anything concrete, i have not found it to be good at that. I also use FastGPT (Kagi's GPT) as a .. faster search frontend. FastGPT fails to find stuff frequently but it also is so damn fast it feels faster than me searching+clicking_link+skimming_page.
I also like ChatGPT for exploring APIs which i may not know, but can easily validate. It's wrong often, but when i can validate it's not a big deal, and what i get out of it is the ability to Q&A. I find API documentation frequently frustrating because while i prefer documentation, i frequently don't know how to get to my answer. Documentation often feels like i need to read the entirety of everything before i can reliably get any answer, and frankly i'm impatient. GPT gives me a more interactive exploration of content. It either knows the answer, or can often point me in the direction to find it myself.
All this is to say ChatGPT & friends have not revolutionized my work. Hell during my day job i rarely use it because it's a domain i know well. But i do have the belief that it helps me enough to justify the cost, currently.
There really isn't any magic bullet I don't think, every case is unique and involves a lot of trial and error. The original prompt was something as simple as "You're going to help me build a plugin for figma that draws Lissajous Curves". It starts with telling you how to setup the Figma plugin folder structure (which Figma makes super easy), installing all the dependencies / npm etc. From there, it was just a lot of going back and forth with ChatGPT fixing the bugs until it compiled cleanly (files we worked with: code.ts, manifest.json, tsconfig.json, ui.html), then going through the bugs that would be thrown in the app console when you actually ran the plugin.
Eventually though, everything worked great and Figma even approved the plugin to be published publicly.
My best piece of advice is that when I feel really far off where I want to be, I just start over from scratch and rework my prompts to more accurately guide ChatGPT in what I want.
And lastly, now that I have a basic "baseline" of how I want ChatGPT to help me with these plugins, I give it all that information up front and try it keep it in that predefined scope.
So GPT 3.5 is great for doing trivial things I already know how to do AND describe accurately, things I'd ask a junior engineer to tackle, but GPT 4 seems to be able to do things I struggle with. I'll probably subscribe now.
I feel the same way, and my (maybe a bit paranoid) take is that many of those posts are also written by ChatGPT. After all, if someone is excited about the tool, of course they'll also use it as much as possible. In that case it also makes sense that there are never any practical examples since the training data is from pre-GPT times.
Things it has helped with, that are now part of a codebase I work in and get paid for.
Generated example css to center a text element onto a sibling image. I'm decent at css, but I didn't know I could do this easily. This definitely saved me a decent amount of time
Write some boilerplate react hook wrapping over an axios request. Something along the lines of "Write a React hook to make a request to ..., using these parameters ... Return ..."
The one that I've probably used most is "Write a MySQL query to ..., these are my schemas: {COPY PASTE RELEVANT TABLE SCHEMAS". I can write MySQL queries just fine, but getting one with some decently complex calculations takes me some time. GPT-4 gets very close most of the time. For exploring the database GPT really has helped save me quite some time. I just don't now MySQL as well as I do my primary languages like TypeScript, PHP and Python so this is a godsend.
Otherwise, I also use it a decent amount in some other scenarios. The Phpstorm plugin I have gives me a right-click menu that pastes my code in a chatGPT window. It has stuff like
1. Refactor
2. Explain
3. Write docs
4. Write a custom prompt
I use these a lot. They save me a decent amount of time. They're super quick to access right in my IDE. In some cases using the "Refactor" command, GPT-4 gives better results than myself. I found that it doesn't really make typos in making sure variable names and stuff stay the same, and it also doesn't mess up control flow which I sometimes do. And yes, this is an admission that I do sometimes refactor without tests, I'm working on it :x
The main constraints I see right now are around 1) complex projects that don't fit into the token context, and 2) keeping up a "base prompt background info" to describe the general purpose of your program and the technical stack.
Issues I've run into:
1) Sometimes it will do things in a "bad" style and you need to correct it. For example overusing callbacks in code that should use async/await. for JavaScript.
2) Subtle errors around types that the vs code compiler can catch and enable you to fix
3) It doesn't seem to consider execution time, so I've seen it produce wildly inefficient code
This is actually not intuitive but should not be surprising since the perfect specification for code is well... code
Copilot has also made it easier to actually know in what situations I should actively reach for ChatGPT or Copilot Chat and they are way different than the ones I thought it would be.
https://github.com/ferrislucas/promptr
The README links to example PR’s comprised of commits written by GPT4. The prompts used to produce the code are noted in the commit messages.
To be clear, it's still really impressive. Being able to ask an AI assistant to implement e.g. a Fourier transform in Rust and getting an answer that is correct or quite close is pretty damn impressive. That's something that a lot of programmers would struggle with. But, in a lot of other ways, GPT-4 feels very skin deep, and the illusion is pierced when you realize it has just made a bunch of shit up in its impressive-sounding answer.
It makes for a decent rubber duck and it can aid you in exploring the space of unknown unknowns when approaching a new subject, but that's about it in my experience.
As a weekend project I did a DSL for helping to interact with LLM's called Prompt (prlang.com), kinda like an declarative LangChain. The language is unimportant, what is important is that syntax highlighting is just one of those things that people expect a language to have now, and every editor wants to do it differently. Figuring out syntax highlighting is one of those super tedious things that makes writing a DSL very boring. ChatGPT4 is very good at translating from one language to another though, and so I could use it to help me write the vim syntax file (I don't know VimScript at all) and then translate it to other editors as necessary.
To get specific, it helped me write this vimscript file:
https://github.com/PromptProgrammingLanguage/prompt/blob/mas...
and then with almost no editing from me turned it into another syntax highlighting file (for hljs) that's used on the website.
https://github.com/PromptProgrammingLanguage/PromptProgrammi...
I don't know how long that would have taken me to figure out on my own, but diving into VimScripts docs, and then the HL.js docs, and fully reading and comprehending them would have been a total slog. Doing it with ChatGPT4, I could keep open the docs for Vim, ask it questions about how to do something, then quickly reference the docs to cross check if it was telling the truth, write, and then test the syntax in a very quick loop. Then the process of translating what I had to another library was incredibly fast, if I recall it misplaced one line while translating, which was thankfully obvious, and that was it. I didn't read the docs for hl.js at all.
ChatGPT is definitely better at some tasks than others. Anything that takes shallow knowledge of your specific code base, but broad knowledge of the wider languages ecosystem, is a good fit for it's use.
I could give a more impressive example of where it helped me tackle a super specific bug in my code that had to do with the wider Rust ecosystems libraries, it really blew me away with that one, but the above was easier to document. You wanted specific though, so there ya go :).
And of course ChatGPT4 is leagues ahead of ChatGPT3.5, so if you're not getting good results you really want to pay for the better model.
If I'm doing something using a language/tool I'm not familiar with then chatgpt is useful because it is better than searching the docs since a lot of documentation is usually a wall of text with no usage examples.
Other than that, all the examples people provide regarding how much of a 'game-changer' chatgpt is always fall into the same google/stackoverflow use case at best or the vague planning/designing/unit-test which tells nothing at all.
One indicator of low credibility is that he keeps saying “this saved me weeks of work” for things that look like they might take a few minutes to do with a spreadsheet, or else could be Googled, or for which there are already free tools, or frankly don’t even need to be done.
I have a bias about his project that I will admit: he seems to be yet another one of those smug entrepreneurs who’s goal in life is to contribute nothing creatively or intellectually to the world. A parasite. Fills me with loathing.
> ...
> So you could use ChatGPT to identify activity trends of an individual to get a statistically high likelihood of reaching them online. Imagine this audit history
> [dataset of login and logout timestamps] `Return a json object with a "sendAtTime" property in ISO-8601 format that has the highest likelihood of reaching the person the next time they are online.`
This feels like it is slightly conflating the strengths of LLMs and AI as a whole.
There are certainly machine learning models that would assist in predicting when a user will be next online, and using an AI assistant to assist in writing such an implementation would likely be helpful.
However, passing JSON into an LLM, asking it to emulate a program to perform this functionality, and then parsing the response to extract other JSON doesn't feel like a stable approach (for example: I was unable to recreate their successful execution under ChatGPT v3), especially given this technique, if widely adopted, may end up including user-controlled fields that would make the system vulnerable to prompt injection.
Whatever combination of the nixlanguage being obscure but also concise, but also, one of the largest github repos seems to have left ChatGPT with a fantastic understanding of the language.
Often you can just paste the error message in unprompted and it will guide you on your way, suggesting missing package names or bad assumptions.
* https://chat.openai.com/share/3b554aa0-5f1b-49e2-bce7-cfe60b...
* https://chat.openai.com/share/dfd30c49-505f-4b95-b6cb-759b7f...
* https://chat.openai.com/share/55dfcbed-2f9d-457f-b1ca-5486fe...
Generating code seems worse too. I agree that you don’t need “perfect,” software if you’re building a blog for your local soccer team. Maybe you want more precaution if you’re initiating trades in securities. And definitely a lot more scrutiny if you’re building real-time control systems for helicopters. Verifying that code is correct with regards to its specification first requires a precise, formal specification; and second, is still a lot of work.
Eyeballing every line of code to catch errors ChatGPT introduces into your code isn’t going to work. You’re not a compiler or theorem prover and you’re bad at finding errors in code. Really bad. It’s not your fault; code becomes incredibly complex quickly.
At best, right now, it’s a curious toy and maybe useful for some folks as a “smart” autocomplete. But beyond that ChatGPT seems to struggle. And I struggle to find a use for it myself.
And when you're an expert in an area, you find ChatGPT presents folk opinion rather than expert opinion.
It's very much a journalist of the internet
What happens if OpenAI decides to increase the price on you? Now you are losing massive amounts of money and have no where to go.
What if OpenAI decides they don't like how your company is operating and bans you from using OpenAI APIs. Where do you go?
What happens if OpenAI changes their model over night and now you are getting bad responses from your prompt. What do you do?
What happens if OpenAI's API goes down?
Unlike most services you use to build application there is no alternatives to OpenAI's API. You can't simply switch to another LLM API and expect the same results.
I mean sure, if it keeps things fresh and keeps you moving it's better than nothing but that's not a good structure if you want to progress past a year of training or do anything serious.
Literally just doing a random program like the reddit recommended BWF routine is vastly superior and doesn't require chatgpt or serverless or anything..
class A { @SomeDecorator() x: string }
const value: A = {x: "foo"};
I was surprised that it compiled at all and structural typing applied to classes, even though '!(value instanceof A)'. But it worked! I asked ChatGPT for more information about this, and basically it just told me that it wouldn't compile, which was obviously wrong.
“”” If you routinely pass in a dataset to AI, it can identify anomalies and watch to see if it settles or even reason why the anomaly occurred in the first place. “””
This is not a great use for LLM’s. AI? Sure. But not this type of it.
it’s not very good at writing code, but can write code in small well defined chunks.
i’m working on a game with blender, cpp, physx, and wickedengine.
it writes a lot of python for blender with prompts like:
blender. python. apply transforms to every object unless X.
these tend to work, if scoped small enough, and any exceptions or failures are put as followup prompts.
writing python for blender is more annoying than hard, so this is great.
the other type of prompt i use a lot is like this:
blender. did X. expected Y. got Z. why?
i use prompts like these a lot, for cpp, physx, and wickedengine. often i ask for code, but not to copy it verbatim, but because i’m thinking in code.
these types of prompts usually output a list of possibilities. almost always the list contains what i’m looking for. usually it’s the first item.
a gamedev prompt might be:
wickedengine. code. how to rotate normal 90 degrees right on y in world?