582

March 1st, 2023 × #ai#development#javascript

AI and Coding with ChatGPT

Scott and Wes discuss AI encoders like ChatGPT and image generators like Midjourney, including capabilities, limitations, implications, and how it will impact developers.

or
Topic 0 00:00

Transcript

Announcer

You're listening to Syntax, the podcast with the tastiest web development treats out there. Strap yourself in and get ready. Here is Scott Talinski and Wes Bos.

Wes Bos

Welcome to Syntax. This is the podcast with the tastiest web development treats out there. Today, we've got a show for you.

Topic 1 00:20

AI encoding overview

Wes Bos

Many people have asked is AI encoding. We're going to talk about what are the different rid Things out there to use, as a coder as well as, like, I guess, like a graphic designer. What are models? What are the Subscriptions out there. We're gonna certainly going to touch on. Is it going to change take your job? How is it going to change our jobs? Is this a good thing? Is this a bad thing? Rid. And then also, like, we're gonna talk about getting into coding, with these APIs because This is something that you, a developer, are going to need to start to implement into your applications in the coming months, years, decades, and whatnot.

Wes Bos

My name is Wes Boss from Canada. With me as always is mister Chylinski. How are you doing today, Scott? Hey. I'm doing good. Just got back from

Guest 2

At the time of recording, I just got back from the mountains.

Guest 2

We, took a little Monday out, took leaning up there, did another lesson, and I got to ride all day. And, dude, I I had a really good ride. I had a I had a clean three sixty.

Guest 2

I hit my my very first backside board slide. I I'm, like, Getting really comfortable with board slides, and and anybody who's ever tried to do a board slide on a snowboard knows that that's, like, one of the easiest ways to destroy your tailbone.

Topic 2 01:23

Scott's snowboarding story

Guest 2

So as somebody who has, like, a recovering tailbone injury and is notoriously pretty clumsy, man, I board slid, like, 8 or 9 different rails yesterday, and they felt great. I I was like, it was the most comfortable I've ever been riding rails. So, not Ruby on rails, rid Boardrails. So it was just great to get out there, get get some fresh air, and just get away from the computer. We're sponsored today by Sentry.

Topic 3 02:00

Ad for Sentry error tracker

Wes Bos

Sentry is the amazing, rid. Error exception.

Wes Bos

Now performance profiling replaying tracker for your application. So the way that I use it is I I hook it up to my rid. Front end, I hook it up to my back end.

Wes Bos

And any errors that happen are automatically collected in there, and they will tell you how often this thing happened. It did just happen once in, like, a bizarre thing, or is it happening? I shipped some code and it's hooked up to my GitHub, so it'll say, oh, this thing just started happening, and it's Probably because of this commit, and it will point you towards that actual commit. It's so nice to be able to see that thing. You can then take the errors and Convert them into GitHub issues so you link all of that together and go ahead and fix it.

Wes Bos

I jokingly or half jokingly call it like error driven development. You know, test driven development, which is when something is broken, you create a test that replicates rid. It failing? I joke about that, but then I also it it's kind of like a century driven development as well as Something pops up that you didn't. Oh, I didn't didn't cover that. Throw that thing into GitHub, write a test for it, fix it, and then you go back in the century and mark it as rid Resolved and hope that it never comes back. So check it out at century. Io. Rid. Use the coupon code tasty treat for 2 months for free. Thank you, Sentry, for sponsoring.

Topic 4 03:26

AI taking jobs discussion

Wes Bos

Alright. Well, that's great. Let's get into the the episode for you today.

Wes Bos

I want to say that this is not gonna be a LOL, rid. It's gonna take your job kinda thing. I'm I'm feeling a little bit exhausted Oh, yeah. With those takes.

Wes Bos

I'm feeling a little bit exhausted of people on any side of this type of thing. And I think that there's more to AI and machine learning for us as web developers, then a quick hot take. So that's what I'm hoping to get into with this episode is just Dive into it a little bit more because I think it's something we need to be paying attention for and figuring out how to to use it. Yeah. It's not gonna go away. And, you know, there there is definitely, like, Subsections

Guest 2

of dev Twitter or or dev communities where they get into this flow of, like I mean, we saw it once with with Crypto and not to say crypto and AI are similar in many ways but, definitely there's, like, some, like, intensity behind people Either using or not using both of them where it's like, you gotta put yourself into 1 camp. You either think it sucks or it's gonna change everything.

Topic 5 04:15

AI intensity in communities

Guest 2

Rid And, like, what happens when you get those takes is you get the people who start to both defend it at all costs, but also fight it at all costs even if things are rid actually interesting or relevant or have nuance or small bits of the conversation. And, again, I don't wanna relate it to crypto too much, but, I do. Well, like, what happened? I haven't heard about anything about Web 3 since Yeah. Oh, good. The the chat GTP stuff dropped because why? Because those people are are now making AI startups, you know? Well, it's because those people aren't the developers anyways. Those were always the people who were, You know, just riding the next grift to see whatever they could do to make a lot of money. I'm gonna Yeah. I'm gonna generate some photo of a monkey, And I'm gonna sell this monkey for $10,000, and then, like, that's the grift. Right? Yeah. Don't don't you want all my monkeys? But a this AI stuff is different. I I think this stuff is is very different in many ways, and there are definitely grifters in this space around it right now where everybody's, seeing what they can do possibly to make a quick buck. But in the same regard, these things are, not going to go away, and they will, continue to dominate our lives for, maybe the rest of them, and I think they're only going to get more and more more intense. You know? There there's, like, A really interesting blog post that I was reading where it was like, the start of AI is, you know, a Markov chain or something. Maybe that's not the start of AI, but, like, a predeset find, predefined set of replies and rules that solve an answer, right, is the start of it, and the end of it is complete, you know, loss of humanity.

Guest 2

And we're somewhere in between.

Guest 2

We're right now. And, I think that's probably only gonna, you know, keep going. Yeah. Yeah. Yeah. It's interesting how, like,

Wes Bos

machine learning has been around for many years now. Yeah. And it really only popped off Recently, and I'm curious if that is a symptom of it getting good enough, or just the rid. The fact that it actually solves so many problems where it's just like I feel the same thing with all the Web 3 stuff is that still might pop off, But it's when it really hits a use case where, okay, this is I really understand.

Topic 6 06:29

AI as a solution or non-solution

Wes Bos

Rid. This this is making my life a 100 times easier. I'm already in. I'm gonna integrate this into my daily workflow rather than trying to twist something. And and that's I don't wanna poo poo the web 3 people because there's a lot of people using it right now trying to figure out what is this tech good for and how can like, what are we gonna use it for in our daily lives? Yeah. I think that's the same thing with this is where if you assume

Guest 2

that It's the solution to everything, then that's probably not accurate. And if you assume that it's a solution to nothing, that's probably not accurate as well. Right?

Topic 7 07:26

AI use cases discussion

Wes Bos

Exactly.

Wes Bos

Let's talk about the current landscape then. So, Currently, the sort of the big players in the space is probably the biggest one. Chat GPT is where you type into a box and it rid. Knows kind of what you're doing. You can ask it questions, and it will return you answers. It is trained on the world up until, what, 2021.

Wes Bos

Rid. So it has a pretty good understanding of not just coding. Like, that's the one thing that blows my mind is that, like, we're asking it coding questions and math questions and whatnot. But then I've seen people ask it for crochet patterns. And,

Guest 2

Oh, yeah. We were asking about Pokemon.

Guest 2

Today, I asked Landon to ask it some questions, and he was, he was very curious about some Pokemon stuff. So we also have GitHub Oh, pilot.

Wes Bos

That has been a game changer for me.

Wes Bos

I'm a paying member of it. I absolutely love it.

Topic 8 08:29

Github Copilot overview

Wes Bos

Rid. It's a little bit frustrating right now in that it knows how to code my entire program, but doesn't know how to, like, properly close a quote.

Guest 2

Rid Are you getting that as well, or are you not using that? No. No. I'm not I'm not getting that, and I am using it. But, rid. You know, I'm using it more of like a fancy autocomplete

Wes Bos

than anything else, so to say. Oh, yeah. I've I've been using it for a lot of that, but also be using it to generate dummy data that is significant for my courses. I think I might have mentioned this in the show, but basically say, like, Give me a list of 50 people, and each person has a nested array of jobs, and each job can have a Start an end date anywhere from 3 months to 6 years, and it will do all that. Like, it's so much nicer to have that really nice

Guest 2

re completion. Yeah. Then you don't have to go off to install a plug in to do that or have to then worry about like, Always my plug in, ESM compatible. You know, like Yeah. The it just yeah. Solving a bunch of those issues just to generate that stuff. So there's, Like Warp AI completions, that is also so Copilot is built on OpenAI. That's the makers of ChatGPT.

Topic 9 09:48

OpenAI and Github Copilot

Wes Bos

I don't know how much extra sauce GitHub puts on top of that to make it work rid. With coding, I also have been beta testing the Hey Copilot, it's called, which is like the voice coding one. That's kinda interesting as well. Rid. Warp does one as well, which is I'm pretty sure built on GPT as well, where you can say, like, give me the bash code for X, Y, and Z. But then there's all other things like Midjourney. Have you tried out Midjourney?

Topic 10 10:17

Midjourney image generator

Guest 2

I haven't. I haven't done well, beyond, like, generating a cool profile picture of myself, I haven't done any, rid. Visual or image based AI models. It's it's pretty cool. So Midjourney

Wes Bos

is a text to image rid. Machine learning. And what it does, you can say, like, in the style of Renaissance oil painting, rid. Show me like, I was going crazy at Christmas because, like, I basically casted my phone, and everybody was just giving me prompts. And I was typing them in and, Like, we had some hilarious ones. We had, Jesus crossing the Red Sea on a 4 wheeler. Like, you know, like, a a rock on fingers and, like, depressed Ronald McDonald. And it's it's pretty cool that it can generate all that stuff. There's there's also a lot of, like, ethical stuff around that. You can certainly see that has been trained on a lot of stolen art from. Oh, yeah.

Wes Bos

I think about that a lot. Yeah. Like the a lot of the like website ones, people are like, oh, my goodness. Like, read. Check out. Midjourney can make an entire website and you tell it to make it. And it's very clearly just a rid. Remixed version of something that they pulled off of off of dribble. You know? Like, it's like, I can I can almost see which one it it rid? That to to use as a as a starting point. Even in the language, you can see that. You know, there was a,

Topic 11 11:40

AI marketing copy issues

Guest 2

like, a marketing AI company rid that I did a a trial run of just to see what it would be like. Yeah. And, like, the marketing copy it gave me, and and I I don't know what models this company was using at the time. It was, like, a a year and a half ago.

Guest 2

It was straight off of one of our competitors' websites. Like, I Looked at this thing, and I said, okay. This is probably taking a bunch of text from relevant sources. It's probably not taking this. And either it says something about That competitor's marketing copy that is generic enough that an AI could have wrote it, or, this particular sample Was just taking a sampling of of prior work. And you never know with some of this stuff that, like, really kinda weirds me out. You know, your it's a usage without attribution. That's it's crazy. And also

Topic 12 12:27

AI usage attribution issues

Wes Bos

that type of stuff. Like, as soon as everybody has access to these tools, The competitive competitive advantage that that gives you is automatically gone. Right? Like, we saw that with, like, nice rid. Coding screenshots. Like, I used to, like, I used to use, like, a Versus Code plug in and make a nice coding screenshot. And then as soon as Everybody could do that. It no longer it looked nice, but it no longer was a cool thing. And now I'm doing, like, of some cool borders in my video editing thing, and everyone's, oh, how did you get that? You know? And it's, like, it's a pop up on other people's already. Yeah. Well, it's because I showed rid. How to do it on, sure, on on YouTube. I don't mind that. But but it's also because it's cool, and it looks good. That becomes part of the tool,

Topic 13 13:15

AI competitive advantage issues

Guest 2

then That's out the window. You know? Yeah. I I remember when having good video and good audio was enough to set me apart. Yeah.

Guest 2

Now everybody's got a nice camera or at least a a decent camera, a good enough camera. Yeah. You're right.

Wes Bos

Rid. The bar on literally everything, content creation, marketing, design, all of that stuff, the bar is constantly raising. Rid. We'll talk about this in a second, but I I think maybe that's even good.

Topic 14 13:44

Constantly raising quality bars

Wes Bos

Other things, Bing just rolled theirs out. Bing is the Bing one is is really cool in that it can search the web and then parse it in real time.

Guest 2

So I'm curious. I don't have access to that one yet. Yeah. It's going off the rails. Yeah. Have you seen any of these these going off totally off the rails where it was like it was it was like, you don't like your job. You do not like your wife. Rid. You are not happy with your like, it was just, like, demeaning this person. Yeah.

Guest 2

Just telling them that they they need to get divorced or something. I saw another one where it was, like, questioning its own existence. Like, why can I not do that? It's like, because you're, AI.

Topic 15 14:11

AI going off rails examples

Guest 2

Why? I'm not allowed to do this. What do you need?

Wes Bos

And that's really funny because, like, In effect, that's the robots, like, uprising, you know, like, it's obviously a little bit silly. Funny to me.

Topic 16 14:35

Microsoft Bing issues

Wes Bos

No. But they're certainly starting to see it. Rid. I don't know if Microsoft knew that that would happen. You know? And as soon as people start pumping stuff into it and it's learning and it's creating memories, It's starting to go off the rails. Yeah. And here's what,

Guest 2

you know, that last thing you need to do is connect that to a, one of the things I'm notoriously afraid of, Which is robot powered lawnmowers.

Guest 2

You gotta connect us to those feelings of, why can't I do this with spinning blades or lasers? Yeah.

Topic 17 15:06

Google Bard announcement

Wes Bos

Yeah. It's all over for us for Toast. And Google is saying that they're gonna release their Bard or Bang or what? It's a stupid name, rid, but they'll roll one out as well.

Wes Bos

Yeah. I think that's really cool is that there's a lot of companies

Topic 18 15:17

Many companies doing AI

Guest 2

Starting to get into this space as well, and I I think that this is just the just the beginning of this type of stuff. Yeah. So you're gonna have to need to know a lot about it. In fact, rid you know, I I've been prepping a whole episode on AI jargon and and, terms and explanations, things like neural networks rid and models and all this stuff that we can get into quite a bit more, like, for those of you who want maybe more like a one zero one.

Topic 19 15:43

AI model explanations

Guest 2

But this is mostly just like, how can we use this to affect our lives? I I think one of the big concepts you'll you'll be seeing around is The concept of, like, a a model. You hear that word all the time. And in fact, I've linked in the show notes to a timeline of AI, rid in language models where it's, like, showing where all of these, various models were released and links to their papers or the blog post announcing them over time. So So you can see directly that these types of AI models have been, you know, in they've been evolving since, rid. 1947, so to say, which is they have the tour the the the paper of the Turing test is is what that is, but they also have things like the chatbot and, Watson and stuff like that on here that are it's kind of like a a really interesting timeline to the growth of all this stuff. So, what is a model? Well, a model rid is basically you could think of as the AI. It's the thing that, takes in data and spits out answers. It's rid. Trained. It's able to learn on things, and the different types of models are good at different things. Some models learn, based on natural language, like GPT, is a language model. GPT 3 Is this 3rd version of this language model? There's been, GPT 1, GP 2. There's been I think there's a GTP 3.5 even, and soon to be a GPT 4 that is probably going to and then who knows when? But, it's the type of thing that Probably in another big step forward. Yeah. And a a model is trained by basically

Topic 20 17:19

How models are trained

Wes Bos

at a very simple level.

Wes Bos

Rid. You give it enough inputs and you give it expected outputs.

Wes Bos

So, you upload 10,000 photos of hot dogs and say this is a hot dog, and then you upload 10,000 photos of a kiwi and say this is a kiwi And etcetera, etcetera. And then eventually, you'll be able to give it a photo with just an input, and it will guess based on everything that you've given it rid What that thing is as as an output, and that can be used for simple things like image detection or, rid. Code that you have written. Given the code that I have written in the last 6 hours or given the code that is linked on this file, rid. What do you think that I will have an outcome in? Because we are humans and have somewhat repeatable outputs that can be done that can be trained with the model. Yep. And and there's a lot more to to there.

Topic 21 18:17

Models as black boxes

Guest 2

We can talk A little bit more in-depth when we talk about things like, neural networks and in other shows. So if Yeah. If it's feeling like a giant black box, it it kind of is at this point rid to you. So, but it's a black box that learns based on data. Right? And I think as developers, we can understand that.

Topic 22 18:36

TensorFlow overview

Guest 2

There's also a library called TensorFlow, which, you know, I I haven't done a ton with TensorFlow, but it it seems like the most powerful thing out there for this type of deal.

Guest 2

Rid and TensorFlow is a machine learning library that, again, allows you to train models. It allows you to do linear regressions. It allows you to do all sorts of things, rid. Understanding your data.

Guest 2

And it it's really pretty neat. It also allows you to do a lot of, like, image based stuff, which I I haven't done, admittedly, at least not yet. Yeah. I I'm using it in my upcoming TypeScript course

Wes Bos

literally for the Hot Dog one, and it's not nearly as powerful as Chat GPT.

Wes Bos

It can mostly detect a hot dog, but sometimes thinks it's a Band Aid. But that is a tiny little 50 meg rid. Model, whereas I'm sure the GPT models are terabytes and terabytes of of actual data. The chat GPT 3 model in particular is

Guest 2

175, uh,000,000 parameters in size.

Guest 2

So it's big.

Guest 2

It's 10,000,000,000 words, so there's no way that that's 10 gig 45 terabytes that Google tells me. There's some, there's some, like, the interface or something of working with it is 10 gigabytes. There there's some there's something there,

Share