YouTube2Text

Session 1 - How To Start (Almost) Any Project — Transcript

by Underfitted · 27,487 words · 3,927 segments · language en · Watch on YouTube

Full transcript

  1. 0:04Hello. Hello. Can you guys hear me?
  2. 0:07Okay.
  3. 0:14Let me make sure.
  4. 0:24Can anybody say something to see if my
  5. 0:27audio is working?
  6. 0:40Let me see.
  7. 0:44Actually go here.
  8. 1:14Hello everyone.
  9. 1:19Sorry, for some reason the meeting here
  10. 1:23is not configured correctly. So I have
  11. 1:26to admit every single one of you one by
  12. 1:29one.
  13. 1:32So weird.
  14. 1:37Let me make sure that doesn't happen
  15. 1:39next time.
  16. 1:43Hey,
  17. 1:47>> morning everyone.
  18. 1:49>> Good [clears throat] morning.
  19. 1:51Hey folks.
  20. 2:00What's the thing on your arm, Santiago?
  21. 2:03Are you getting like notes of your
  22. 2:05vitals during
  23. 2:08>> Christmas?
  24. 2:10Yeah, this is a whoop. I don't know if
  25. 2:12you've seen them.
  26. 2:13>> No,
  27. 2:14>> but I always wear them in my bicep. It's
  28. 2:18a little bit uh more accurate. You can
  29. 2:21also wear them here like just a regular
  30. 2:24wristband,
  31. 2:25>> but in my bicep is is a little bit
  32. 2:27better. And when I'm wearing like short
  33. 2:30sleeves, it tail
  34. 2:31>> people ask questions. Yep.
  35. 2:33>> They usually pick Yeah. Everyone has
  36. 2:36asked me and some people think is some
  37. 2:38kind of biohacking
  38. 2:41where they cut circulation to the
  39. 2:44muscle. So when they're working out, I
  40. 2:47don't know, stimulates the muscle. No,
  41. 2:49nothing like that. It's just just a
  42. 2:51regular whoop count my steps and does
  43. 2:55you know stress monitoring things like
  44. 2:58that.
  45. 3:01Sorry, I'm I'm updating here really
  46. 3:03quick the meetings because for some
  47. 3:06reason when I configured this
  48. 3:11I have to manually accept every one of
  49. 3:14you admit everyone into the meeting
  50. 3:17which is a pain in the neck because I'm
  51. 3:19talking and people are trying to join
  52. 3:22and I have to just click admit admit
  53. 3:24admit
  54. 3:26uh and yeah I don't think there is a way
  55. 3:28to change that after the meeting is
  56. 3:30going.
  57. 3:33Let me see settings.
  58. 3:35Can I just say everyone please join?
  59. 3:40Let me see. Reactions, video, audio,
  60. 3:44general.
  61. 3:48No, I don't think there is a way to do
  62. 3:50that.
  63. 3:53Uh, yeah, I don't think there is a way
  64. 3:57to do that.
  65. 3:58At least I don't see it here. Let me let
  66. 4:01me see
  67. 4:03settings.
  68. 4:06I apologize about this. I should have
  69. 4:08known this before.
  70. 4:14>> It's just painful.
  71. 4:17Santgo
  72. 4:19al quite a few names sounding like south
  73. 4:23of Europe, Spain, maybe Italy, Portugal,
  74. 4:27right?
  75. 4:28>> Yeah.
  76. 4:30>> Did I get it right?
  77. 4:32>> Yeah, it's uh usually I get people from
  78. 4:36all over the world. I've had people from
  79. 4:40Asia here.
  80. 4:43uh they don't go to sleep and they just
  81. 4:45take the class which is just crazy to
  82. 4:47me.
  83. 4:48>> Uh obviously all from Europe especially
  84. 4:51at this time I used to teach this class
  85. 4:55at this time and then later in the day
  86. 4:57but this time it's perfect from people
  87. 5:00in in Europe uh Latin America you know
  88. 5:04Mexico uh Honduras Argentina all of
  89. 5:08those countries are really popular. the
  90. 5:10class is really popular there. Uh
  91. 5:13anyway, it's uh yeah, well, first of
  92. 5:16all, welcome everyone. I'm sorry I'm a
  93. 5:20little bit still settling. I usually
  94. 5:22spend my summers outside the United
  95. 5:24States. Uh we like to spend my uh our
  96. 5:27summers in Europe. And I just came back
  97. 5:31two days ago, so I'm still settling in
  98. 5:34after three months out. Uh we went to
  99. 5:36Japan and we went all over the world.
  100. 5:38It's super cool. But anyway, I'm back
  101. 5:41and this is uh I think I mentioned this
  102. 5:43already on this course. This is going to
  103. 5:45be my last time teaching this. Uh what
  104. 5:48that means is that you guys are going to
  105. 5:50still obviously uh have access to all of
  106. 5:53the materials. I'm not taking that down.
  107. 5:57Uh I'm just not going to be running the
  108. 5:59classes anymore. Uh the reason I'm not
  109. 6:01running the classes anymore, um it's
  110. 6:04it's two reasons actually. Uh number
  111. 6:07one, I want to do something different.
  112. 6:09I've been doing this for three years
  113. 6:10now. So, I think it's time for me to
  114. 6:12just, you know, do something different.
  115. 6:15Don't have the class in my the back of
  116. 6:17my mind. Oh, in a month I have to fix
  117. 6:19this because the class is coming. I want
  118. 6:21to just dedicate my time to something
  119. 6:23else. And number two is a general trend
  120. 6:26that is not only happening with this
  121. 6:28class, but it's it's all over the place.
  122. 6:31Like people, they just don't want to
  123. 6:33learn anymore. It's anything that's
  124. 6:35educationally
  125. 6:37uh oriented. It's it's just huge dips.
  126. 6:41Uh just to to give you some perspective,
  127. 6:45I've been teaching this for three years.
  128. 6:47And for two of those years, I think
  129. 6:52every single session of this class,
  130. 6:54every single cohort had about 200 people
  131. 6:58joining every class. That's just to give
  132. 7:01you an idea of how popular it was. Now
  133. 7:06we have right now and this is going to
  134. 7:08be the class with the most amount of
  135. 7:09people. So this is going to go down from
  136. 7:11here. Always happens. We have 34 people.
  137. 7:14So that gives you an idea of just the
  138. 7:17tip. Uh I know a lot of other people who
  139. 7:21also teach something and everyone is
  140. 7:24seeing the same thing across. uh like
  141. 7:27people are not going to classes anymore.
  142. 7:30They're just asking Chad GPT to do stuff
  143. 7:32for them. So I understand I understand
  144. 7:34why why that's happening. So anyway,
  145. 7:36perfect opportunity for me to just
  146. 7:37dedicate my time to something else. So I
  147. 7:40decided to teach this one for the last
  148. 7:42time and have fun with it. Uh so what
  149. 7:45are we going to be or let me just give
  150. 7:47you a little bit of background and a
  151. 7:49little bit of a how this class is going
  152. 7:51to go. So, we're meeting three times per
  153. 7:54week for three weeks. Two of those times
  154. 7:58are sessions, meaning I'm just going to
  155. 8:00be showing you slides and talking. Uh
  156. 8:04the other which is going to be on
  157. 8:06Wednesdays, that's what I call office
  158. 8:08hours. That is just time for whoever
  159. 8:12wants to join join and we're going to
  160. 8:15talk about anything.
  161. 8:18We can talk like literally anything. It
  162. 8:20doesn't have to be related to the class.
  163. 8:22It's it's whatever. I usually usually
  164. 8:24that time we talk about what's going on
  165. 8:27in the world of of development and AI
  166. 8:30and how to make money online and how to
  167. 8:33build a business that where you can sell
  168. 8:35software. Things like that are usually
  169. 8:38the topics that come up during office
  170. 8:40hours. So, they're kind of fun. Okay?
  171. 8:42But you don't have to be here. It's it's
  172. 8:44okay.
  173. 8:46During the sessions, uh I'm there are
  174. 8:50six sessions. I'm going to show you
  175. 8:52slides in four of those sessions. Okay?
  176. 8:55So, sessions one through four, I'm going
  177. 8:58to have slides. I'm going to go through
  178. 9:00the material with everything that I want
  179. 9:02to teach you and we can talk about it.
  180. 9:05You can ask questions, etc. For the last
  181. 9:07two sessions, starting with the last
  182. 9:10cohort, I stopped showing slides and
  183. 9:13instead in session five, I'm going to
  184. 9:16talk about code. I'm going to show you
  185. 9:18some code, some specific agents that
  186. 9:21that I built for this class. So, we can
  187. 9:24talk about how the agents work and what
  188. 9:27I built and you can ask questions about
  189. 9:29the code, etc. So, the whole session
  190. 9:31five is going to be looking at the code.
  191. 9:34The whole session six is going to be
  192. 9:36talking about agentic coding. No
  193. 9:39sessions. So basically the goal of
  194. 9:42session six and session six I'm not
  195. 9:44going to be the teacher. I'm going to
  196. 9:46tell you what I know about agentic
  197. 9:48coding but me like all of you we're all
  198. 9:52learning here. Okay. So I hope that
  199. 9:54during session six you guys can
  200. 9:57contribute as well and teach me and
  201. 10:01everyone else in the class what are you
  202. 10:03guys doing with your codeex or clock
  203. 10:06code or whatever you're using because
  204. 10:08we're all we pretty much have the same
  205. 10:10experience all of us right there's
  206. 10:12nobody with uh with a decade of
  207. 10:15experience in agentic coding yet so
  208. 10:17that's the goal of this class okay
  209. 10:21bottom line is I hope that after three
  210. 10:24weeks you guys go out there with a few
  211. 10:28new things. So, number one, hopefully
  212. 10:30some experience
  213. 10:32gained by listening to me because I made
  214. 10:35the mistakes before. I'm going to show
  215. 10:36you those mistakes and hopefully you get
  216. 10:38some ideas off of those mistakes so you
  217. 10:40don't make those mistakes. Number two,
  218. 10:42maybe you're going to learn a few
  219. 10:43techniques that you're going to be able
  220. 10:44to apply later on on your job. And
  221. 10:48number three, and this is the most
  222. 10:50important thing for me, uh I want you
  223. 10:53guys to be motivated, more motivated
  224. 10:55than you were today. So hopefully you go
  225. 10:58out there, you're motivated to make a
  226. 11:01difference, uh to make money. That's
  227. 11:04what's about to be honest with you. I'm
  228. 11:06very practical person. I don't think
  229. 11:08people do this because this is the love
  230. 11:10of my life. All of us, this is a
  231. 11:12business. We have families. So hopefully
  232. 11:14we give you some ideas on how to make a
  233. 11:16little bit more money. uh with this
  234. 11:18knowledge. Um with all of that being
  235. 11:21said, any questions before I show you
  236. 11:23slides.
  237. 11:33Okay, let me let me open Google Drive
  238. 11:36because
  239. 11:38maybe me I don't have that in front of
  240. 11:41me now obviously. So,
  241. 11:43>> so Santiago, maybe not a question, but a
  242. 11:45ch ch ch ch ch ch ch ch ch ch ch ch ch
  243. 11:46ch ch ch ch ch ch ch ch ch ch ch ch ch
  244. 11:46ch ch ch ch ch ch ch ch ch ch ch ch ch
  245. 11:46ch challenge or a favor if you spend a
  246. 11:48moment at the end of you know the cohort
  247. 11:51tell us a little bit more about your
  248. 11:53plans. This would be entertaining
  249. 11:56or like
  250. 11:56>> okay what are my plans uh going forward?
  251. 12:01>> Uh so yeah so the the short answer to
  252. 12:04that is I just don't know yet. Okay. So,
  253. 12:08it's I I don't have anything settled. Uh
  254. 12:12so, I I'm I'm lucky. I don't I I don't
  255. 12:16have a job. My job is is is just doing
  256. 12:19this and and working with different
  257. 12:20companies, reviewing things and
  258. 12:23consulting for them. So, that's what my
  259. 12:24job is. That's my my own business. So, I
  260. 12:28don't need from the money point of view,
  261. 12:32I don't need to replace the cohort. So,
  262. 12:34I'm not in a rush. Hey, I just need to
  263. 12:36do something else because the cohort I'm
  264. 12:38not going to be teaching it anymore.
  265. 12:40That's not that's not my my
  266. 12:43that's not a problem for me. What I'm
  267. 12:46going to do, I want to do something
  268. 12:48obviously. I just don't know what that
  269. 12:51is going to be. talking to students and
  270. 12:54talking to people that I know. A lot of
  271. 12:57people have suggested that I do
  272. 12:59something that I've been doing for a
  273. 13:01long time which is uh just basically how
  274. 13:06to create a business where you can be
  275. 13:10your own thing is you know lifestyle
  276. 13:13business let me call it like that. Uh
  277. 13:15not a business to raise money on a big
  278. 13:18company or anything like that. That's
  279. 13:19not my thing. That's not who I am. But
  280. 13:22mostly something that you can do, live
  281. 13:24off of it. Um, live very well. Um, don't
  282. 13:27worry about anything else. Some people
  283. 13:29have talked to me about doing that. I
  284. 13:32have some advice there based based on
  285. 13:35what I've learned.
  286. 13:37The problem for that is that I find that
  287. 13:40yucky. I don't like to be talking to
  288. 13:44people how to make money because that's
  289. 13:48nine out of 10 people that do that.
  290. 13:50They're just trying to scam you out of
  291. 13:52money. I don't want to be that person.
  292. 13:54Uh so I don't know. I don't know yet
  293. 13:56what that's gonna look like. We'll see.
  294. 13:58We'll see. Uh but yeah, not sure.
  295. 14:02Mansour, what's up?
  296. 14:04>> Yes. Hi, Santgo. How are you? Hello
  297. 14:06everyone. Um yeah, thank you. Thank you
  298. 14:08very much. Um just just one question. I
  299. 14:11joined a long time ago. I think it was
  300. 14:12at the very beginning of um when you
  301. 14:14created I'm joining by from Sagal by the
  302. 14:16way, West Africa. So yeah, perfect time
  303. 14:19for us. Um so um I don't know a long
  304. 14:22time ago and I know in between um the
  305. 14:26content has changed a lot I think.
  306. 14:28>> Yeah.
  307. 14:28>> And I had maybe two questions, right? So
  308. 14:32it was about machine learning at the
  309. 14:34beginning. Is it really still about
  310. 14:36machine learning? Second one, do you
  311. 14:38suggest that we also go back to the
  312. 14:41previous material that you had somehow
  313. 14:43or will this one be like self-contained
  314. 14:46and no need to actually go back in time
  315. 14:48and look at some of them? What would be
  316. 14:50your advice based on on that? Thank you
  317. 14:52very much.
  318. 14:52>> Yeah. So, uh, great questions. Let me
  319. 14:54just share with me here the slides. Just
  320. 14:57one second. I'm going to answer those.
  321. 15:01>> All right. So, great question. So when I
  322. 15:03started this cohort, I started teaching
  323. 15:06uh
  324. 15:08same principles, same ideas,
  325. 15:11uh a lot of the same examples that
  326. 15:13you're going to see during the class,
  327. 15:15but the code portion of the cohort was
  328. 15:18100% focused on building everything
  329. 15:21using Sage Maker, AWS SageMaker. So I
  330. 15:25was using AWS APIs, AWS uh SDK,
  331. 15:30everything was focused 100% on
  332. 15:32SageMaker. Over time I changed that and
  333. 15:35I migrated the whole codebase to
  334. 15:39opensource tools because there were a
  335. 15:41lot of people that they came to my class
  336. 15:44but they were Ashure users or Google
  337. 15:48Cloud Platform users. They did not care
  338. 15:50about AWS. So the class was still still
  339. 15:53helpful but they couldn't take advantage
  340. 15:55of the code by migrating everything over
  341. 15:59open-source tools. Now everyone had
  342. 16:02access to the core to the code and you
  343. 16:04know they were able to take advantage of
  344. 16:06it. That was the big big change that
  345. 16:09happened after that.
  346. 16:12uh little by little I've incorporated
  347. 16:16new ideas that have come out since then
  348. 16:19like AI more specifically and LLMs and
  349. 16:23how to uh we went we spent time at some
  350. 16:26point talking about training LLMs and
  351. 16:29now we're not talking about that we're
  352. 16:31more about in agents and stuff like that
  353. 16:34those are new concepts that have
  354. 16:36happened since the beginning of the
  355. 16:38class I've introduced those here they're
  356. 16:42are useful material
  357. 16:44back in the previous cohorts that I've
  358. 16:48removed just because I had to add new
  359. 16:52materials. But it's hard for me to point
  360. 16:54you to, hey, just go to cohort 15 or
  361. 16:57cohort 14 because the transition has
  362. 17:00been gradual and it's it's it's just
  363. 17:03really hard for me to tell you when we
  364. 17:04talked about what. But bottom line, you
  365. 17:09don't need to go back. This is not not
  366. 17:13that different from previous cohorts.
  367. 17:15Again, there might be one topic that is
  368. 17:17not here that was before, but not need
  369. 17:20to go back uh and watch anything. Okay.
  370. 17:26Okay. I think I think I'm almost ready
  371. 17:30to show you the slides, guys.
  372. 17:35I honestly thought that I had this
  373. 17:37yesterday figured out. Uh, obviously I
  374. 17:39didn't.
  375. 17:42Okay, here we go.
  376. 17:46Here we go.
  377. 17:52Let me share my screen.
  378. 17:59Jesus Christ.
  379. 18:07You guys might be okay.
  380. 18:11I think there might be people wanting to
  381. 18:13come in. Yeah, there you go. You guys
  382. 18:16see my screen?
  383. 18:19All good?
  384. 18:20>> Yep.
  385. 18:21>> All right. So, yeah.
  386. 18:25All right. So the first session I
  387. 18:27usually try to talk about
  388. 18:30how do you approach a new project. Okay.
  389. 18:33Um the reason I spend time talking about
  390. 18:35this is and again you guys have to
  391. 18:39remember I'm going to have a bias
  392. 18:41towards
  393. 18:42me working with a client and me being
  394. 18:45responsible of everything that happens
  395. 18:48from that point on. Okay. Some of you, I
  396. 18:52assume some of you are are part of a
  397. 18:54team where in your team you're going to
  398. 18:56have people dedicated to all different
  399. 18:59phases, right? From selling, from
  400. 19:02marketing, project management, etc.,
  401. 19:04etc. When you're working solo, for the
  402. 19:07most part, you're doing all of those
  403. 19:09roles somehow, right? So, this is going
  404. 19:11to cover some of those ideas, right?
  405. 19:14From the beginning until the end until
  406. 19:16you you have a project moving on. That's
  407. 19:19how I organized my session. So session
  408. 19:21number one is kind of focused on hey how
  409. 19:24do we go from from from nothing to how
  410. 19:27do we start pretty much. So let me start
  411. 19:30with uh
  412. 19:33one of the big fuckups that I I made uh
  413. 19:36because I know uh that you guys have
  414. 19:39seen this before. So this was me uh this
  415. 19:42is a client uh I'm working as part of a
  416. 19:44team. This is a client. Uh they want us
  417. 19:46to we were working with the robot from
  418. 19:49Boston Dynamics. Uh if you've seen it,
  419. 19:52it's the yellow robot. It's called Spot.
  420. 19:56And we were building computer vision,
  421. 20:00different computer vision solutions for
  422. 20:02that robot. So the robot could get some
  423. 20:05skills. Um a client wanted us to, hey,
  424. 20:09how about we do inventory with uh the
  425. 20:12robot. So the robot basically will walk
  426. 20:14around the aisles. We'll take pictures
  427. 20:17of the boxes and we'll count the number
  428. 20:21of boxes and you know we will be able to
  429. 20:24have an idea of what's in there.
  430. 20:26The problem was uh oh by the way I said
  431. 20:29of course um the solution I built is
  432. 20:31what you see here on the left and I
  433. 20:34don't know if you can see this isn't
  434. 20:35very subtle but I on purpose I sort of
  435. 20:39like misplaced
  436. 20:41this bounding box here this uh if you
  437. 20:44see my screen I don't know can you guys
  438. 20:46see my mouse by the way
  439. 20:49I don't know if you can see it or not
  440. 20:51but anyway uh okay so if you do you can
  441. 20:55see here there is a like a you know
  442. 20:58green
  443. 20:59bounding box that's incorrectly set. Uh
  444. 21:03I did not represent it here well but
  445. 21:05there might be boxes that you cannot see
  446. 21:08just to to go straight to the point. It
  447. 21:11was a stupid solution. So I tried to
  448. 21:14solve something where there is a better
  449. 21:16solution. It's been invented for years
  450. 21:18now. And I tried to do something that
  451. 21:21obviously did not work. We had
  452. 21:23unreliable counts of boxes. Uh the robot
  453. 21:27could not see, could not work past
  454. 21:29occlusions. Like if there is a box
  455. 21:31behind another box, it was really really
  456. 21:34hard. Uh the solution obviously is just
  457. 21:36to follow protocols and use barcodes.
  458. 21:39That has been implemented forever. This
  459. 21:42was a failure. this is my failure for
  460. 21:45not, you know, telling the client, dude,
  461. 21:48you're just trying to invent the, you
  462. 21:51know, you're trying to invent something
  463. 21:53that already exists. So,
  464. 21:56here's the thing. Most projects fail
  465. 22:00because we're trying to solve the wrong
  466. 22:02thing. Okay? So, you need to start every
  467. 22:05project or my advice to you is to start
  468. 22:07every project with a discovery phase.
  469. 22:10Okay? That's what I propose to every
  470. 22:12single client I get. Uh somebody calls
  471. 22:15me, they say, "I want to work with you.
  472. 22:18I have a million dollars to build this
  473. 22:20thing. That's great. That's amazing. Uh
  474. 22:23can you tell me how long it's going to
  475. 22:24take?" And I'm going to answer to them.
  476. 22:28I just don't know. I need four to six
  477. 22:30weeks for a discovery phase. That's how
  478. 22:34I start every project. That's the only
  479. 22:36thing I ask the client to commit to.
  480. 22:39four to six weeks so we can figure out
  481. 22:44what we're doing and how we're doing it
  482. 22:46and how much is it going to cost. Okay,
  483. 22:49one of the biggest problems in software
  484. 22:51development, some of you I assume are
  485. 22:53software developers, is estimating
  486. 22:56things. How long is it going to take
  487. 22:57something? How much is going to cost uh
  488. 23:00to build it? The answer to all of those
  489. 23:02questions is I just don't know. I need
  490. 23:06time to figure those out. That's what
  491. 23:08the discovery phase will take care of.
  492. 23:11Okay, discovery phase is just a time
  493. 23:14box, you know, phase. I usually like to
  494. 23:17do four to six weeks. It could be
  495. 23:19longer. It could be shorter depending on
  496. 23:21the complexity that I think the project
  497. 23:24will have. But that's the goal there.
  498. 23:26You learn about the problem. You frame
  499. 23:29the problem. We're going to talk about
  500. 23:30problem framing in just a second. and
  501. 23:32you prove you can actually solve the
  502. 23:36problem. Especially with AI and machine
  503. 23:38learning, there are a lot of problems
  504. 23:41where you might not be able to solve
  505. 23:44because you don't have the data. You
  506. 23:45don't have way to capture the good data,
  507. 23:47the data that you need to solve that
  508. 23:49problem etc etc. So before you commit to
  509. 23:53anything you go through this discovery
  510. 23:55phase and that will reduce the risk.
  511. 23:57Okay. It's also very easy to convince a
  512. 24:01client to sign up for six week weeks of
  513. 24:05work than to ask the client, I'm gonna
  514. 24:09need a million dollars and one year,
  515. 24:12right? Just to solve this. Very easy the
  516. 24:14first, very hard to get that signature
  517. 24:17when you're asking for a lot of money, a
  518. 24:18lot of time, uh, under a lot of
  519. 24:20uncertainty. So, that's what the
  520. 24:23discovery phase is. Here are a bunch of
  521. 24:26questions. I'm not going to go through
  522. 24:27all of them, but you have the slides or
  523. 24:29you're going to have the slides after
  524. 24:30the class and you can just read the
  525. 24:33questions. But these are some of the
  526. 24:34questions that I use during that
  527. 24:36discovery phase. Okay. So, for example,
  528. 24:39what is the problem that we're trying to
  529. 24:41solve? What are the problems that we are
  530. 24:44going to ignore? Very important. It's
  531. 24:46not only about the things that you want
  532. 24:48to build, but the things that you are
  533. 24:50not going to touch while building that
  534. 24:53because you know the road to the
  535. 24:56solution that you're looking for is
  536. 24:59going to be full of rabbit holes. And if
  537. 25:03you're not careful spelling them out,
  538. 25:05it's very easy to go off track trying to
  539. 25:09build features and little things that
  540. 25:13you might might not be that important
  541. 25:15for your solution. Who's the customer?
  542. 25:18This is the last one I'm going to
  543. 25:19explain
  544. 25:20because it's one of the most important
  545. 25:22ones. When you're working with a
  546. 25:24company, you're usually talking to the
  547. 25:28person with the money, not to the person
  548. 25:31who needs the solution the most. What I
  549. 25:35mean by that is uh I work for a company,
  550. 25:37they want to build a new inventory
  551. 25:40system. I'm talking to the CTO of the
  552. 25:43company. The CTO is the person who's
  553. 25:45responsible for investing the money into
  554. 25:49building that solution. They're not the
  555. 25:51customer. they are not going to be
  556. 25:53running inventory or accounting or
  557. 25:55whatever the system is about. You need
  558. 25:57to identify who the real customer is.
  559. 26:00One of the most common mistakes is
  560. 26:02people trying to please the money person
  561. 26:07instead of pleasing the customer. What
  562. 26:11happens is there's going to be a
  563. 26:12mismatch and the customers, the people
  564. 26:15who have to adopt your tool will hate
  565. 26:18it.
  566. 26:20It doesn't matter that the boss is happy
  567. 26:22if the people who have to adopt the tool
  568. 26:24will hate it uh hate it because those
  569. 26:27are the ones that are going to rubber
  570. 26:29stamp your work. Okay? So you have to uh
  571. 26:33investigate or you know determine who
  572. 26:36the real customer is. bunch of other
  573. 26:38questions here. Read them later. But the
  574. 26:41goal is all of these questions are the
  575. 26:44ones that I'm going to be answering
  576. 26:47during the discovery phase.
  577. 26:50Have any of you, by the way, have any of
  578. 26:53you
  579. 26:55done this before when working on a new
  580. 26:58project? Have any of you have had that
  581. 27:00buffer at the beginning of it? that does
  582. 27:03not mean that you are uh you're still
  583. 27:07not uh committed to complete the
  584. 27:10project. You're just going through a
  585. 27:11discovery phase. Is this something that
  586. 27:12you guys have done? Yes or no?
  587. 27:18>> Yes. Yes. Yes. Of course.
  588. 27:20>> Santiago, quick question. What's the
  589. 27:22protocol? You have material for like
  590. 27:24entire one and a half an hour or you're
  591. 27:27happy to take questions during?
  592. 27:29>> I'm happy to take questions whenever
  593. 27:30whenever you have questions. just just
  594. 27:32raise your hand and uh
  595. 27:36>> okay
  596. 27:36>> I have I have a really quick one uh
  597. 27:39let's again out of curiosity what's your
  598. 27:42uh usual arrangement do you charge for
  599. 27:43the discovery phase separately without
  600. 27:46like going to details just basically
  601. 27:48like really quick question curious
  602. 27:51>> uh yeah so I do charge for the discovery
  603. 27:55phase I do not
  604. 27:58uh that doesn't mean that the client is
  605. 28:01is forced to to pay for the whole
  606. 28:03project.
  607. 28:04>> Yeah.
  608. 28:04>> I just don't get to the like basically I
  609. 28:07don't tell the client this is how much
  610. 28:09it's going to cost you the whole thing.
  611. 28:11I just say there are four weeks here. Uh
  612. 28:14you're going to pay me this much for the
  613. 28:16four weeks and part of the outputs of
  614. 28:19that those four weeks is going to be a
  615. 28:22plan and hopefully a budget for the rest
  616. 28:24of the project. Now, that being said,
  617. 28:27way I usually approach long projects is
  618. 28:30not it's going to cost you $500,000 for
  619. 28:34eight months. I don't do that. I ask for
  620. 28:37iterations. So, hey, this is the next
  621. 28:39iteration. It's going to be another
  622. 28:41month. This is how much you're going to
  623. 28:43pay me for a month. And these are the
  624. 28:46outputs that we expect to have after one
  625. 28:48month. You commit to one month and
  626. 28:51that's pretty much it. and after a month
  627. 28:54we reassess. That works well with many
  628. 28:57clients. With big companies, it doesn't
  629. 28:59work well for stupid reasons. Those
  630. 29:03reasons being approval, procurement for
  631. 29:06the money. So, it's really hard in a big
  632. 29:10company. It's usually hard for a manager
  633. 29:13to go multiple times to procurement to
  634. 29:17get paperwork done to approve funds for
  635. 29:20a project. So, it's way easier for them
  636. 29:23to go and ask for a million dollars than
  637. 29:26to go 10 times and ask for uh $100,000.
  638. 29:30You see what I'm saying? So, usually
  639. 29:33what happens is that uh what we do is we
  640. 29:38try to estimate how much it's going to
  641. 29:40be, but I'm only going to be charging
  642. 29:43the client for one iteration at a time.
  643. 29:46Okay? So the client understands that the
  644. 29:48big estimate is not a money that I'm
  645. 29:50asking or that they owe me. That's just
  646. 29:53for them to get approval, but then
  647. 29:55payments are going to be done per
  648. 29:57iterations and that's my only
  649. 29:59commitment. So anyway, that's that's a
  650. 30:00lot of uh insider baseball there, but
  651. 30:03that's the whole the whole idea. I
  652. 30:05charge for discovery. The output of
  653. 30:08discovery might be I I cannot build this
  654. 30:11for you. I don't have enough. You don't
  655. 30:13have the data. That's has happened
  656. 30:15multiple times. I specialize in computer
  657. 30:18vision. Many many companies hire me to
  658. 30:21do things and then I come back after
  659. 30:23four weeks and tell them you guys need
  660. 30:25images.
  661. 30:27To get images, let's say you have to fly
  662. 30:30drones.
  663. 30:31You don't even have a drone program that
  664. 30:34you can use to fly drones. I mean,
  665. 30:36flying drones is not is not sending Mary
  666. 30:39Jane with a drone and taking pictures.
  667. 30:41No, you need professionals and you need
  668. 30:44a way to fly those drones and fly them
  669. 30:46every week and recharge them and blah
  670. 30:48blah blah blah blah. You need a year to
  671. 30:51figure that out. You need to go and work
  672. 30:52with a company that does that for you.
  673. 30:54And after you have that in place and
  674. 30:56after you're capturing images, you come
  675. 30:58to me and I'm going to help you build
  676. 30:59the models. So that you know that's the
  677. 31:02output of this a discovery phase. if I
  678. 31:04wouldn't I mean if you don't do the
  679. 31:06discovery phase now you're stuck in a
  680. 31:08project you don't even know how to move
  681. 31:10forward with does that make sense
  682. 31:12>> yep makes perfect sense and I'm happy to
  683. 31:15hear that this works you know with
  684. 31:17businesses
  685. 31:19>> you know that there is this niche or
  686. 31:20like even like larger niche that when
  687. 31:23this is functional nice
  688. 31:25>> thanks it actually works uh it's in my
  689. 31:29experience it it's very refreshing to
  690. 31:32them to hear from somebody that's not
  691. 31:35asking them for eight months and giving
  692. 31:38them a promise that everyone knows at
  693. 31:41that table we cannot complete that prom.
  694. 31:43I mean whatever you're estimating that
  695. 31:46six, seven, eight month from now you're
  696. 31:49just it's just stupid like nobody knows
  697. 31:52that far you know far in advance how
  698. 31:54long things are going to take. So it's
  699. 31:56very refreshing to go let's go one
  700. 31:58iteration at a time. these are my
  701. 32:01commitments for one iteration and then
  702. 32:03we reassess and then we just put
  703. 32:06together a plan for the next iteration
  704. 32:08and it's it's it's like an employee will
  705. 32:11do with his boss, right? If you work for
  706. 32:14somebody, your boss is not asking you to
  707. 32:17commit to a year worth of work. That's
  708. 32:19not what your boss is telling you. Your
  709. 32:21boss is saying, "We're going to go one
  710. 32:23spring at a time, one week at a time,
  711. 32:25and if you stop working out, at least
  712. 32:27here in the United States, if you stop
  713. 32:29working out for me, I'm just going to
  714. 32:31fire you. Bye-bye. But as long as you
  715. 32:34bring value, I'm going to keep you in my
  716. 32:36team." That's the whole idea that we're
  717. 32:38trying to reproduce. Yeah.
  718. 32:41Okay. Cool. All right. So, problem
  719. 32:43framing. I said that one of the goals of
  720. 32:45discovery is framing the problem. And
  721. 32:48this is uh
  722. 32:51this is key. All right. Framing the
  723. 32:54problem. I mean you take a problem and
  724. 32:56you frame it in the incorrect way and
  725. 33:00you might be adding millions of dollars
  726. 33:03to to that project for no reason or you
  727. 33:06might be getting yourself into a hole
  728. 33:08that you might not be able to come out
  729. 33:09of it. So doing learning how to find the
  730. 33:13right framing for a problem is just
  731. 33:16going to be key. This is one of the most
  732. 33:17high lever uh tasks that you can
  733. 33:21perform. So let me give you one example
  734. 33:23here. Okay. Uh this is sort of like we
  735. 33:26try to to to draw here Tesla's you know
  736. 33:30infotainment system here but that
  737. 33:32self-driving car if you compare how
  738. 33:35Tesla and Whimo or Whimo however you
  739. 33:38pronounce it framed building full
  740. 33:41self-driving you're going to notice that
  741. 33:43they went very very different path.
  742. 33:46Okay, so Tesla decided we're going to
  743. 33:48put a crappy software out there, but
  744. 33:52we're going to focus on creating cars
  745. 33:54that many, many people buy. Okay? And
  746. 33:57over time, those people are going to be
  747. 34:00capturing more data. And with that data,
  748. 34:03we're going to be improving those
  749. 34:04models. So over time, our models are
  750. 34:07going to be really good. They focused on
  751. 34:11the commercial part of the equation.
  752. 34:12Whimo did something very, very
  753. 34:14different. Wimar released a full
  754. 34:17self-driving system from day one. It was
  755. 34:20not open to the public. It was
  756. 34:22restricted in the number of or in the
  757. 34:25roads that it could take. But that was
  758. 34:28it. They had an area, very small area
  759. 34:30with a full driving system. They did not
  760. 34:33care about selling cars. They only care
  761. 34:36about repetition and making that model
  762. 34:38better. And as it got better, they
  763. 34:41started expanding the area where their
  764. 34:44vehicles could drive. Very, very
  765. 34:48different approaches there. Now, you
  766. 34:51could argue that one of them is more
  767. 34:53successful than the other. I mean, it's
  768. 34:55depending on how you're looking at this,
  769. 34:56you're going to have an different
  770. 34:58opinion on which is the right framing.
  771. 35:01But you can hopefully clearly see that
  772. 35:04these are very, you know, very very
  773. 35:07different ways trying to solve the same
  774. 35:09thing which is full self drive. Okay. So
  775. 35:12that's the idea here. Now I like in
  776. 35:15order to frame my problems, I like to to
  777. 35:17use what I call the haystack principle.
  778. 35:20And I did not coin this term. Uh the
  779. 35:23first time I heard this was from
  780. 35:25somebody who was my boss. I learned a
  781. 35:27lot from him and he used to call it the
  782. 35:30haystack principle. So the whole idea
  783. 35:33here is instead of trying to find a
  784. 35:36needle in a hay stack, you're going to
  785. 35:39focus on trimming the hay stack until
  786. 35:43the need needle is right there. Does
  787. 35:46that make sense? So instead of focusing
  788. 35:48on the problem that everyone cares
  789. 35:51about, you're going to focus on
  790. 35:52everything else. get rid of everything
  791. 35:54else until the problem is right there.
  792. 35:57I'm going to show you uh couple of
  793. 36:00examples of how that of what that looks
  794. 36:02like. So, this is a project that we
  795. 36:05worked with Disney Disney World. So, I I
  796. 36:08don't know if you guys have been to
  797. 36:10Disney, but [clears throat] they have a
  798. 36:11problem with people uh getting into
  799. 36:14their parks without paying.
  800. 36:17People just go in. Now, their policy at
  801. 36:21Disney is not to be confrontational.
  802. 36:26So, even if they
  803. 36:28suspect that somebody came in without
  804. 36:31paying, they're not going to make a big
  805. 36:34deal out of it, they don't want any
  806. 36:36other guests seeing a discussion, etc.
  807. 36:40So, they were not sure how to solve this
  808. 36:42issue.
  809. 36:44So they decided
  810. 36:46to sort of like compute calculate how
  811. 36:50big of an issue is this like if this is
  812. 36:54I don't know $10,000 that we're losing
  813. 36:56every year. Who cares, right? Who is I
  814. 37:00mean we're not going to make a big fuss
  815. 37:01of uh $10,000 a year, but this is a
  816. 37:05multi-million dollar a year. Then maybe
  817. 37:07we have to find solutions for this.
  818. 37:09Okay, so that that's sort of like the
  819. 37:10mentality that they went in here. They
  820. 37:13asked us to estimate how big of a
  821. 37:16problem it was. And for that we had
  822. 37:18access to the cameras that they have on
  823. 37:21every like the every entrance point they
  824. 37:25have on every station they have a bunch
  825. 37:27of cameras and you go to the stations
  826. 37:28you scan your magic or your pass or
  827. 37:32whatever and then you go in. So we had
  828. 37:35access to those videos and we decided to
  829. 37:38build a model to do that. Now you can
  830. 37:41ask this to a thousand person and 999 of
  831. 37:44them are going to tell you well we need
  832. 37:46to build we need to build a system or
  833. 37:49build the model that identifies people
  834. 37:52coming into the park. Identify people
  835. 37:55coming in without stopping at the kiosk
  836. 37:58or you know the the place where they
  837. 38:00need to scan and maybe that right
  838. 38:03everyone will try to focus on the people
  839. 38:06who are doing the wrong thing.
  840. 38:09And that is very hard to do. If you have
  841. 38:12seen a line of people is just a huge
  842. 38:14mess and people go all over the place,
  843. 38:16especially when they have kids, they're
  844. 38:18unpredictable. They're running. It's a
  845. 38:21mass of people. Very hard to do. So
  846. 38:22instead, what we did was how about we
  847. 38:25take 10 hours of video footage per lane
  848. 38:28is just a huge ask. We have a 10-hour
  849. 38:31video feed and we identify
  850. 38:35every portion of the video feed where we
  851. 38:38are certain nothing bad is happening
  852. 38:41because lines like might not be a lot of
  853. 38:45people coming in or maybe the line is
  854. 38:47organized or maybe you know we identify
  855. 38:50that nothing weird is happen and by
  856. 38:53doing that we were able to reduce the
  857. 38:56amount of video feed that was
  858. 38:58interesting in 80% %. So now instead of
  859. 39:01having hours of video, now we had two
  860. 39:04hours of video to review. Now those two
  861. 39:06hours, the signal to noise ratio was
  862. 39:10really, really high. So we had a
  863. 39:12procurement department, a department,
  864. 39:14not a procurement department, a
  865. 39:15department that was tasked with watching
  866. 39:17those video feeds, their security
  867. 39:19department to review those two hours of
  868. 39:22video instead of giving them 10 hours
  869. 39:25per lane. Now they only had two hours to
  870. 39:28focus on. That was huge boost in
  871. 39:32productivity. We did not have to kill
  872. 39:36ourselves trying to identify the
  873. 39:38infractors. We only reduce the hay stack
  874. 39:42in order to get something that was
  875. 39:44better for humans or easier for humans
  876. 39:47to do. Does that make sense?
  877. 39:51That's the idea with the haystack
  878. 39:53principle. Another example of that is
  879. 39:56that you see all the time in uh ray
  880. 40:01x-rays sorry medical imaging right there
  881. 40:05are many many systems right now in place
  882. 40:08where before a radiologist had to go
  883. 40:11through a thousand images
  884. 40:13just looking for okay who what you know
  885. 40:16what's or the doctor not the radiologist
  886. 40:18but the doctor had to go through a
  887. 40:20thousand images identifying who was sick
  888. 40:24and who wasn't. And now you have
  889. 40:26algorithms that are going to go through
  890. 40:27a thousand images and will identify with
  891. 40:29very very high confidence every single
  892. 40:32image that's completely normal. Not the
  893. 40:35ones that are sick, which is very
  894. 40:37nuanced, but the ones that, for example,
  895. 40:40there are blank images, blank a x-ray
  896. 40:43images show nothing, those you can
  897. 40:46discard right away. Images that look
  898. 40:48very clean, those you can discard right
  899. 40:50away. and only leave the ones that are
  900. 40:53interesting for the doctor. That reduces
  901. 40:57the amount of work that the doctor has
  902. 40:59to do
  903. 41:01by a lot and you don't have to spend
  904. 41:03that much time building a system that's
  905. 41:05going to be really really hard for you.
  906. 41:07Okay. All right. So, let me go to next
  907. 41:10one here.
  908. 41:12So, that's the goal with problem
  909. 41:13framing. Every time you get to a
  910. 41:15problem, ask yourself, is it going to be
  911. 41:19easier for me to focus on the inversion
  912. 41:22of the problem? uh Charlie Mer uh I
  913. 41:25think he wrote it in his uh Charlie's
  914. 41:28calendar just book he wrote uh where he
  915. 41:32said that he and Warren Buffett became
  916. 41:36rich not by focusing on becoming rich
  917. 41:40but by focusing on not becoming poor or
  918. 41:44not uh basically becoming broke. So
  919. 41:49their whole strategy at the beginning
  920. 41:51was how can we avoid
  921. 41:54total you know financial failure.
  922. 41:58Let's just take a defensive position.
  923. 42:00Let's focus on the opposite on the
  924. 42:02inversion and that will help us you know
  925. 42:05the upside will take care of itself.
  926. 42:08That's sort of like the same idea where
  927. 42:10the hay stack principle would sort of
  928. 42:12like lead you to focus on the inverse
  929. 42:16like what everyone else is focusing on.
  930. 42:18All right. So next thing you you know
  931. 42:21you work on the framing the problem you
  932. 42:23ask the questions you have an idea of
  933. 42:25what you're working on. The next thing
  934. 42:27that I usually do during a discovery
  935. 42:29phase is just building just a simple
  936. 42:31prototype. So how quickly can we prove
  937. 42:34that this that we can actually build a
  938. 42:36solution for this? We have an idea. We
  939. 42:38know how we're going to frame it. Can we
  940. 42:40actually build a model? Can we actually
  941. 42:41build a solution that sort of like shows
  942. 42:44us that this is possible? Okay. And for
  943. 42:47this and if if nothing else, if you're
  944. 42:50not going to remember anything else from
  945. 42:51this class, I promise you remember this.
  946. 42:54You're going to you're going to be okay.
  947. 42:56Build always build the simplest thing
  948. 42:59that could possibly work. I've made a
  949. 43:03career out of that. out of saying we're
  950. 43:06not going to need that. We're not going
  951. 43:07to need that. What is the simplest
  952. 43:10thing? I have an anecdote which is kind
  953. 43:13of extreme,
  954. 43:15but it was a good lesson for the person
  955. 43:18who was working with me. So, we're
  956. 43:20working with this client and we're
  957. 43:21delivering a web page to a restaurant.
  958. 43:23And if you go to a restaurant page, you
  959. 43:26know that people display this map in
  960. 43:28restaurant pages where you can see every
  961. 43:31location the restaurant is is at. So you
  962. 43:34know if there's a chain you can see oh
  963. 43:37they have one here and one at five miles
  964. 43:39and one there. Anyway, the client wanted
  965. 43:42one of those maps and I have person
  966. 43:44working with me. We're up against the
  967. 43:46deadline. We have to deliver. The person
  968. 43:49is working on a map. He's asking me for
  969. 43:51more time. We need more time to build
  970. 43:53that map. We need to build an
  971. 43:55integration with Google map where we
  972. 43:57pass all of the locations that the
  973. 44:00client gave us and Google map will
  974. 44:02display those pings and then we're going
  975. 44:04to embed that Google map. We did not
  976. 44:06have uh cloud code back then. Probably
  977. 44:09we can do that today in five minutes
  978. 44:11asking cloud code to do it but we didn't
  979. 44:12have that cloud code back then. So we
  980. 44:14had to implement all of that and I was
  981. 44:16up to here. I did not have time for that
  982. 44:18and I told him we're not going to do
  983. 44:20that. This is what we're going to do.
  984. 44:24Google, go to Google Maps and Google the
  985. 44:26restaurant name and that will show you
  986. 44:28in Google Map all of the pins where the
  987. 44:31location is. Take a screenshot
  988. 44:33of that and paste it in the website.
  989. 44:36That's it.
  990. 44:37You put a screenshot on your website
  991. 44:40that shows every single pin. Well, yeah,
  992. 44:43but it's not going to be interactive.
  993. 44:44Who cares?
  994. 44:47Did the client say, "I want it to be
  995. 44:49interactive." No. People are not going
  996. 44:51to be able to zoom in. Yeah, they won't.
  997. 44:53Who cares? Boom there. Call it done.
  998. 44:56That's it. It's been a long time since I
  999. 45:00went to that website. But I promise you,
  1000. 45:03it was for at least three years. That
  1001. 45:05was the version they had there. Client
  1002. 45:07was happy. Everyone was happy. We made
  1003. 45:10assumptions that were not part of the
  1004. 45:12deal that nobody cared about. And it was
  1005. 45:16a screenshot. That was the simplest uh
  1006. 45:19possible thing that you can do. You
  1007. 45:21focus on this and it's going to be
  1008. 45:24you're going to be okay. Make it work
  1009. 45:26first, make it better later. That's the
  1010. 45:30mentality when you're building a
  1011. 45:31prototype. Okay? That's the whole
  1012. 45:34mentality. All right. So, here is an
  1013. 45:37example of it. So, I'm working for this
  1014. 45:39company called Fashion File. So fashion
  1015. 45:42file
  1016. 45:45is a I don't know maybe maybe if you you
  1017. 45:48guys uh care about fashion you know the
  1018. 45:51fashion file it's like eBay for luxury
  1019. 45:54goods so they sell watches they sell
  1020. 45:57expensive packs I work with them for
  1021. 45:59like three years I was alone like I mean
  1022. 46:02me working as a self-employee with them
  1023. 46:05my company working with them so
  1024. 46:08we're building uh this or we had to
  1025. 46:11build this model to determine
  1026. 46:15what is the optimal price for an item.
  1027. 46:20Uh so we can make the most money. That's
  1028. 46:22sort of like the idea. So imagine that
  1029. 46:24we are imagine that you buy a $10,000
  1030. 46:28watch from somebody. The question is how
  1031. 46:31much can you ask? I'm I I I paid $10,000
  1032. 46:35for that watch. I want to uh sell it
  1033. 46:39online. what is the maximum that I can
  1034. 46:42ask for it? Okay. And when you have a
  1035. 46:45complex operation where you are doing
  1036. 46:47this over millions of items, inventory
  1037. 46:50space is important. So you cannot just
  1038. 46:52say well just let's price it at 20,000
  1039. 46:55two times and we'll see if somebody you
  1040. 46:58cannot do that because that item will
  1041. 47:00sit in inventory for a long time might
  1042. 47:04lose value. you don't know but at least
  1043. 47:07going to be taking space from new uh
  1044. 47:10merchandise that you want your
  1045. 47:12merchandise to be moving. So we had to
  1046. 47:14find that balance and we wanted to
  1047. 47:17create a machine learning model to do
  1048. 47:19that.
  1049. 47:20This is not an easy thing to do to
  1050. 47:23build. Uh we require like first of all I
  1051. 47:26have no idea how to build this. We hey
  1052. 47:28we just need to sit down and see what
  1053. 47:30we're going to do. But we're not going
  1054. 47:33to wait six months or a year to have a
  1055. 47:36solution for this. Of course not. Let's
  1056. 47:38build just a simple prototype, a stupid
  1057. 47:40prototype and this is the way it's going
  1058. 47:42to work. By the way, they were doing
  1059. 47:43this with a procurement department. They
  1060. 47:47had a whole department that was
  1061. 47:49analyzing every single item and they
  1062. 47:51were deciding the price that we're going
  1063. 47:53to sell this on. And we wanted to take
  1064. 47:55some of the work off of that department.
  1065. 47:57So this is our prototype and it sounds
  1066. 47:59stupid but this was working for almost a
  1067. 48:02year. Okay, we took the the watch.
  1068. 48:07By the way, bonus points if you can
  1069. 48:08identify that watch is very
  1070. 48:11identifiable. So you should be able to.
  1071. 48:13So we took a watch and we set the
  1072. 48:15initial price of that watch to the cost,
  1073. 48:19how much we paid for it. Let's say we
  1074. 48:21paid a thou $10,000 for it plus specific
  1075. 48:24margin. That was a fixed concept. So
  1076. 48:27let's say 40% margin. Okay. So initial
  1077. 48:31price was $14,000.
  1078. 48:34Then we make that watch available for
  1079. 48:36purchasing. So the watch showed up in
  1080. 48:40the website. Okay. $14,000.
  1081. 48:43We waited for a month at that price.
  1082. 48:47If nothing happened, if the watch did
  1083. 48:49not sell after a month, we ask, can
  1084. 48:53[clears throat] we still reduce the
  1085. 48:55price? Like, what are we going to lose
  1086. 48:57money here? We had like a minimum of 10%
  1087. 49:00margin, for example. Well, yeah, we said
  1088. 49:02it at the beginning at 40% margin, we
  1089. 49:04still have time to go down. So, let's
  1090. 49:07discount the price by 10%.
  1091. 49:10And let's make it available again. So
  1092. 49:13now the the over time the price of the
  1093. 49:16watch is coming down 10% every 30 days
  1094. 49:21until it hit a point where we were not
  1095. 49:24going to reduce it anymore. And at that
  1096. 49:26point we added that watch as a priority
  1097. 49:30for the procurement team so they could
  1098. 49:33take care of it and decide how much they
  1099. 49:36wanted to sell that watch for. Very
  1100. 49:38simple five lines of code. I don't know
  1101. 49:40if this it was not five lines but you
  1102. 49:42can see how simple this is. This was our
  1103. 49:46prototype.
  1104. 49:48We deployed this over time we built that
  1105. 49:52machine learning model that took over
  1106. 49:56this and I promise you it was really
  1107. 50:00really hard to beat the
  1108. 50:05ability for this simple model to make
  1109. 50:07money. really really hard for the
  1110. 50:09machine learning model to overtake this
  1111. 50:13with better pricing. Sometimes simpler
  1112. 50:16things are easier. So next time you're
  1113. 50:19trying to build something on especially
  1114. 50:21on the discovery phase, build a
  1115. 50:22prototype that's very very very simple.
  1116. 50:26Okay. So a good prototype should be
  1117. 50:28simple to build, easy to maintain, and
  1118. 50:31you should prioritize time to first
  1119. 50:33insight over perfection. That's
  1120. 50:36important. The goal of a prototype is to
  1121. 50:39learn. That's what you want to do. So,
  1122. 50:42what can you do to learn the most out of
  1123. 50:45your prototype? Forget about the
  1124. 50:47perfection. Forget about the details.
  1125. 50:49Forget about the cool features. Focused
  1126. 50:52on learning. Okay? That's the goal of
  1127. 50:55the prototype because the prototype is
  1128. 50:56the one that's going to guide you going
  1129. 50:59forward. Okay? Another example here.
  1130. 51:02That's spot by the way. This is from a
  1131. 51:04video that we recorded. Let me see where
  1132. 51:07is my mouse.
  1133. 51:09Okay, there we go. So, this is Spot
  1134. 51:11right here. This is me talking to Spot.
  1135. 51:13So, we uh we were running missions with
  1136. 51:15Spotions.
  1137. 51:17What I mean is we were sending Spot
  1138. 51:19inside a warehouse go and gather
  1139. 51:21information and come back uh about you
  1140. 51:24know the warehouse and whatnot. And we
  1141. 51:26had this problem that we had to connect
  1142. 51:29to spot, you know, Wi-Fi hotspot and
  1143. 51:31connect open a website in order to read
  1144. 51:34the information from the mission. And we
  1145. 51:37wanted a way easy way to gather any
  1146. 51:41quick insights quickly without having to
  1147. 51:43do the whole connect to the robot or
  1148. 51:46wait for the robot to upload the
  1149. 51:48information etc etc. So what we built
  1150. 51:50was voice commands. This is before chat
  1151. 51:53GPT, but we built voice command to for a
  1152. 51:57spot to listen to us talking and then
  1153. 52:01using that information to just speed out
  1154. 52:04whatever happened. So for example, we
  1155. 52:06could say uh summary and spot will say
  1156. 52:10we found four problems in such and such
  1157. 52:14place and the problems are blah blah
  1158. 52:16blah blah blah. Okay, with a robotic
  1159. 52:18voice obviously. So the whole idea was
  1160. 52:21just to build a simple classification
  1161. 52:22model that will give us you know it will
  1162. 52:26interpret the actions coming from the
  1163. 52:28user from boys and will interpret them
  1164. 52:31and you know basically spot will do
  1165. 52:34those. So I was able to say something
  1166. 52:36like move back of or move forward or or
  1167. 52:41summary. That was the idea. Very very
  1168. 52:45simple application we were able to build
  1169. 52:48to do this. We did not have to get into
  1170. 52:51any complex solutions. Very simple. When
  1171. 52:55Chad GPT came out, uh this was even
  1172. 52:59simpler because we got into a problem
  1173. 53:01here. Just parenthesis here. We got into
  1174. 53:04a problem where people did not remember
  1175. 53:06the actual commands. So if you wanted
  1176. 53:09spot to move back, some people would say
  1177. 53:12back, some people would say step away,
  1178. 53:15some people would say move away. So it
  1179. 53:18was really hard. Chad GBT back then it
  1180. 53:22was great because we were able to take
  1181. 53:25the voice the transcription from the
  1182. 53:27voice from the user and turn that
  1183. 53:30classify that into a single command. So
  1184. 53:34move back, step away, uh I don't know,
  1185. 53:37get away from me. All of that translated
  1186. 53:40into back and it was very easy to So
  1187. 53:43anyway, hopefully that makes sense.
  1188. 53:48Simple rules to build the prototype
  1189. 53:51without using machine learning. Uh these
  1190. 53:54are I'm not going to go through all of
  1191. 53:55these, but basically uh there are many
  1192. 53:59many many different problems that we can
  1193. 54:01solve with machine learning.
  1194. 54:02classification, regression,
  1195. 54:03recommendations, anomaly detection,
  1196. 54:05forecasting, clustering, those are some
  1197. 54:07of them. These rules here, I add add
  1198. 54:10them here because people who are trying
  1199. 54:12to build models when they get into this
  1200. 54:15discovery phase, the first reaction is
  1201. 54:17well, we have to actually build the
  1202. 54:19model to does classification or we
  1203. 54:21actually need to build the regression
  1204. 54:23model. And the answer is no. You can
  1205. 54:25actually build a prototype without using
  1206. 54:27machine learning. You can actually do
  1207. 54:29classification by checking if a keyword
  1208. 54:33exists in the text. Okay? So if the
  1209. 54:36keyword exists, you're going to assign a
  1210. 54:37class. Or if a value is greater than a
  1211. 54:40specific threshold, we're going to
  1212. 54:42assign specific class. So you can build
  1213. 54:45rules that are not going to go far but
  1214. 54:48are going to be good enough for the
  1215. 54:49prototype in order to come up with a a
  1216. 54:52solution that's going to prove whether
  1217. 54:56there is light at the end of this
  1218. 54:58tunnel. Remember the goal here is to
  1219. 55:00build the simplest thing that could
  1220. 55:01possibly work. I'm going to leave all of
  1221. 55:03these rules here just in case you have
  1222. 55:06an idea. These are ways to simplify a
  1223. 55:10solution. Okay. Again, prototype demo.
  1224. 55:15That's what these are going to do. These
  1225. 55:17are not rules that are going to stay for
  1226. 55:19long. But our goal here is just to build
  1227. 55:21something as quickly as possible. All
  1228. 55:24right. So, any questions so far?
  1229. 55:28>> No, it makes perfect sense.
  1230. 55:31>> Cool.
  1231. 55:31>> Thanks for sharing.
  1232. 55:33>> All right. So
  1233. 55:36whole idea here with the prototype, I
  1234. 55:38think we talked about this is your goal
  1235. 55:40here is to basically measure, learn,
  1236. 55:44question, improve. That's the idea of a
  1237. 55:48prototype. It also serves to collect
  1238. 55:50data that you can later use to build the
  1239. 55:53model. Remember, when you're building a
  1240. 55:55machine learning model or an AI model,
  1241. 55:57all of those models require data to
  1242. 56:00learn. And one way to gather that data
  1243. 56:04is just to put together a prototype that
  1244. 56:06people can start using. Think about the
  1245. 56:08watch. By the way, did anybody recognize
  1246. 56:10the watch? Let me check the chat here.
  1247. 56:13Nobody recognize the the watch. Oh,
  1248. 56:16robot guest is a robot. Whose robot?
  1249. 56:19There was a robot here. It's a Cartier,
  1250. 56:22but it wasn't sure. Offer a bunch of
  1251. 56:24images to look at. Indeed, looks like
  1252. 56:27Cartier tank. must is a cartier Santos.
  1253. 56:31So, Ignasio is correct. It's a The tank
  1254. 56:36it's more rectangular. Okay, that's what
  1255. 56:38the tank is. The Santos is a square
  1256. 56:42watch. So, yes, it's a Cartier Santos.
  1257. 56:45That's the inspiration of that uh
  1258. 56:49semantics. All right. So, anyway, uh I
  1259. 56:52was gonna look for something and I
  1260. 56:54forgot what I was saying. Oh, remember
  1261. 56:56the watch example? When you put together
  1262. 56:59that prototype and you put it out there
  1263. 57:02for people to use, you're gathering
  1264. 57:04data. You're seeing how people react to
  1265. 57:07different prices for different products.
  1266. 57:09All of that data we used to build our
  1267. 57:12model. Without a prototype, number one,
  1268. 57:15nobody's using your system. Nobody's is
  1269. 57:17taking advantage of anything because you
  1270. 57:19don't even have anything out there. So,
  1271. 57:21you're not even collecting data at that
  1272. 57:23point. Okay? It's very very important uh
  1273. 57:26to have a prototype. Uh
  1274. 57:30I'm going to say your name is probably
  1275. 57:32going to be wrong. Please correct me. So
  1276. 57:33hype.
  1277. 57:34>> Yeah. So hi. Yes. So Santiago, you know,
  1278. 57:37this is my second time joining your
  1279. 57:38course. Uh a question I have is you are
  1280. 57:41suggesting building models, right? Can't
  1281. 57:43you use simply ResNet with a new set of
  1282. 57:46data instead of training your new model
  1283. 57:49or something very simple for object
  1284. 57:51detection uh or or you know whatever is
  1285. 57:54out there because training a model
  1286. 57:56itself you know it's it's uh it's a huge
  1287. 57:59task right uh uh starting from scratch
  1288. 58:03writing the training code and all that
  1289. 58:04in PyTorch or you know Jax or whatever
  1290. 58:07right is a huge huge effort so what are
  1291. 58:10your thoughts on this
  1292. 58:11>> so okay So, by the way, when I talk
  1293. 58:15about building a model, uh, building a
  1294. 58:17model, I'm not necessarily thinking
  1295. 58:19about training a model from scratch.
  1296. 58:21Building a model, take it one level of
  1297. 58:24abstraction higher. You don't care
  1298. 58:26exactly who was doing the job. The model
  1299. 58:28is sort of like the solution that's
  1300. 58:29solving a problem. That being said,
  1301. 58:32sometimes for some problems you do need
  1302. 58:35to train models regardless of how good
  1303. 58:38the latest cloud whatever Opus is or
  1304. 58:42Kajd is. Specialized models for certain
  1305. 58:46tasks are much better than general
  1306. 58:49models that were designed to do
  1307. 58:51something different. Let me just give
  1308. 58:52you one example. Okay, for this problem,
  1309. 58:55the one that I show you about uh the
  1310. 58:58company with the watch and whatnot,
  1311. 59:00they're running right now about probably
  1312. 59:03a couple dozen specialized computer
  1313. 59:07vision models to recognize uh luxury
  1314. 59:10items. When they the client sends a
  1315. 59:13picture of what they want to sell, the
  1316. 59:16models will recognize what that is.
  1317. 59:18You can do some of it with the current
  1318. 59:23tech. And some of it, what I mean by
  1319. 59:26that is the current tech opus will
  1320. 59:29recognize, oh that is a watch. Oh, that
  1321. 59:32is a bag. But it will not recognize
  1322. 59:37sometimes the model of the watch or the
  1323. 59:41model and brand of a bag. So a back is
  1324. 59:46we don't do anything with that. That's
  1325. 59:47not enough information. We need to know
  1326. 59:48it's a Louis Vuitton Tomach and we need
  1327. 59:51to know is a double kilted DD Louis
  1328. 59:54Vuitton Tomach from 2006.
  1329. 59:57Okay. So that level of detail you can
  1330. 1:00:00only accomplish with a specialized model
  1331. 1:00:03that's been trained on data coming from
  1332. 1:00:06Louis Vuitton catalogs in order to
  1333. 1:00:08recognize the nuance between two
  1334. 1:00:10different backs because the pricing is
  1335. 1:00:12going to be completely different. So
  1336. 1:00:14throw that back to uh Opus and or Sonet
  1337. 1:00:19or whatever model you're using and
  1338. 1:00:21they're going to probably it's going to
  1339. 1:00:22tell you oh that's a Louis Vuitton back.
  1340. 1:00:24Okay, tell me the model. It's not going
  1341. 1:00:26to know. So certain tasks require
  1342. 1:00:30specialized models. But I'm going to go
  1343. 1:00:31one step further. Even if or even when
  1344. 1:00:37the current state-of-the-art models
  1345. 1:00:40can perform a task, the next question is
  1346. 1:00:43can they do it cheap enough for us to
  1347. 1:00:47scale this? Okay, if we're getting if
  1348. 1:00:50we're processing
  1349. 1:00:52two million images every single day,
  1350. 1:00:54just as an example, how much are you
  1351. 1:00:57going to be paying on Tropic for two
  1352. 1:00:59million images a day to use their
  1353. 1:01:01models? that's going to be a lot of a
  1354. 1:01:04lot of money. It's not feasible for the
  1355. 1:01:06company to do that. They would rather
  1356. 1:01:09build their own models that do that at
  1357. 1:01:12just just nothing, you know, because
  1358. 1:01:14it's so small model that they can build
  1359. 1:01:17it quickly and they can run it super
  1360. 1:01:19quickly and they can accomplish the same
  1361. 1:01:21task without having to pay that much
  1362. 1:01:23money. So that is why those models are
  1363. 1:01:25not dead even when the latest you know
  1364. 1:01:29models from anthropic and and open AAI
  1365. 1:01:32can do the same job. Specialized models
  1366. 1:01:34are still small are still cheap they
  1367. 1:01:36scale very very well and they're still
  1368. 1:01:39uh desirable by companies. And on top of
  1369. 1:01:42that you said something and I'm going to
  1370. 1:01:45not disagree with it but I'm going to
  1371. 1:01:47sort of like add a little bit more
  1372. 1:01:48information. You said training a model
  1373. 1:01:50is a huge task.
  1374. 1:01:53It depends what model it is, what
  1375. 1:01:55project it is. You can train a model in
  1376. 1:01:58literally 15 minutes. If you've done it
  1377. 1:02:00before and you know what you're doing,
  1378. 1:02:02it's just literally 15 minutes at
  1379. 1:02:04assuming by 15 minutes. I don't mean
  1380. 1:02:06that that's how long it's going to take
  1381. 1:02:08the model training process. What I mean
  1382. 1:02:10is you your work like putting together
  1383. 1:02:12the code does that and does it well.
  1384. 1:02:14It's not necessarily a huge task.
  1385. 1:02:17Obviously, new projects or bigger
  1386. 1:02:20projects will require more time from
  1387. 1:02:22you, but it's not necessarily a huge
  1388. 1:02:24accomplishment. Don't see it as as a
  1389. 1:02:27mountain that requires a team. That's
  1390. 1:02:30for yeah, for one of the
  1391. 1:02:32state-of-the-art large language models,
  1392. 1:02:34it's way more complex. For a small
  1393. 1:02:36specialized models where you're starting
  1394. 1:02:38off uh a foundational model that's very
  1395. 1:02:41easy to just reproduce and retrain, it's
  1396. 1:02:44not that complex. Hopefully that makes
  1397. 1:02:46sense.
  1398. 1:02:49>> Yes, thank you.
  1399. 1:02:52What's up?
  1400. 1:02:53>> Uh yes. Yes, there just as an extension
  1401. 1:02:55maybe to to the question. uh I was more
  1402. 1:02:58in on the on the edge case maybe where
  1403. 1:03:01uh okay you train on a small model over
  1404. 1:03:04uh some data and maybe I'm not really
  1405. 1:03:07versed into that that field yet but what
  1406. 1:03:10happens when for example a given brand
  1407. 1:03:12comes up with a new model like it's a
  1408. 1:03:15brand new one so how do you do you
  1409. 1:03:17manage to deal with this use case
  1410. 1:03:18usually
  1411. 1:03:20>> yeah you you're not going to recognize
  1412. 1:03:21that you have to keep training your
  1413. 1:03:23models all of the time and we're going
  1414. 1:03:25to talk about this in the class uh we
  1415. 1:03:27call it usually continuous learning and
  1416. 1:03:29it's something that you have to build
  1417. 1:03:31into your projects uh I usually tell
  1418. 1:03:35people that training the first version
  1419. 1:03:36of your model that's your day one here
  1420. 1:03:39people think okay we train the model
  1421. 1:03:41we're done project is over no this is
  1422. 1:03:44just day one of your project you need to
  1423. 1:03:47build
  1424. 1:03:48the workflows necessary for that model
  1425. 1:03:51not only to keep monitoring the model
  1426. 1:03:53and understand what happens with it but
  1427. 1:03:55to keep retraining the model as new data
  1428. 1:03:58becomes available. So the way you deal
  1429. 1:04:00with that type of stuff uh if they're
  1430. 1:04:02asking specifically number one you have
  1431. 1:04:04to stay up to date but number two when
  1432. 1:04:06your models see something that do not
  1433. 1:04:09recognize you want to teach your models
  1434. 1:04:12that hey I should not be able I should
  1435. 1:04:15not be giving you an answer about this.
  1436. 1:04:18One of the problems with these models is
  1437. 1:04:21that they are trained to give you an
  1438. 1:04:23answer regardless of whether they know
  1439. 1:04:25what they're talking about or not. That
  1440. 1:04:27sort of like explains hallucinations a
  1441. 1:04:29little bit. Models don't know how to
  1442. 1:04:31answer. They don't know how to say, "Oh,
  1443. 1:04:33I don't know." They just tell you
  1444. 1:04:36They just you. If you
  1445. 1:04:38build a classification model, for
  1446. 1:04:40example, and you want the model to
  1447. 1:04:42classify an object into three classes,
  1448. 1:04:46let's say we're talking about animals,
  1449. 1:04:48elephant, dinosaur, and and lion, and
  1450. 1:04:52you show the model a cat, the model will
  1451. 1:04:55likely put that cat into a lion because
  1452. 1:04:58it's the closest thing that resembles
  1453. 1:05:00the cat. The model does not know that it
  1454. 1:05:03should not be making assumptions about a
  1455. 1:05:05cat because it hasn't seen a cat before.
  1456. 1:05:08uh I think it's in session three or
  1457. 1:05:10session four I'm going to show you
  1458. 1:05:12techniques that you can implement to
  1459. 1:05:15prevent models from making these sort of
  1460. 1:05:18like mistakes which are very common and
  1461. 1:05:20from dealing with scenarios where the
  1462. 1:05:23model should not be providing an answer
  1463. 1:05:26that's a good thing that we humans have
  1464. 1:05:28if I ask you hey how do we send a rocket
  1465. 1:05:31to the moon uh well maybe you know but
  1466. 1:05:35maybe you tell me I have no idea idea.
  1467. 1:05:37That's a good thing, right? That the
  1468. 1:05:39fact that you're telling me I don't know
  1469. 1:05:41how to do that. That's a good thing.
  1470. 1:05:43Models don't have that capacity. If you
  1471. 1:05:46were a model, you will tell me, "Oh,
  1472. 1:05:48yeah. To send a rocket to the moon,
  1473. 1:05:50first step, go to the store, buy just
  1474. 1:05:53stupid answer like that."
  1475. 1:05:56All right. Cool. Awesome. So,
  1476. 1:06:00we built the prototype. We
  1477. 1:06:03were in the middle of the discovery
  1478. 1:06:05phase. We framed the problem. Uh, one
  1479. 1:06:07thing that I would like to I'm going to
  1480. 1:06:10paste it here, but if you have not read
  1481. 1:06:14this, please do. This is a great reading
  1482. 1:06:17and it's going to sort of like uh yeah,
  1483. 1:06:20it's going to give you a different
  1484. 1:06:21perspective. How do I go to the chat?
  1485. 1:06:23Okay, maybe here
  1486. 1:06:31I found it.
  1487. 1:06:35So, for those of you who have not read
  1488. 1:06:38that essay, uh just take take the time
  1489. 1:06:41and go through it. It's just just really
  1490. 1:06:43really good. Okay. Do things that don't
  1491. 1:06:46scale from Paul Graham. Uh
  1492. 1:06:50that's going to give you that's going to
  1493. 1:06:52put your mind I think in the right place
  1494. 1:06:55when you're thinking about the prototype
  1495. 1:06:58that you have to build. Okay. All right.
  1496. 1:07:01So,
  1497. 1:07:04Okay, building and labeling a data set.
  1498. 1:07:08We have a prototype. We know how we're
  1499. 1:07:10framing the problem. Assuming that we're
  1500. 1:07:12building machine learning based project,
  1501. 1:07:15assuming that we have to build the model
  1502. 1:07:17or we have to train a model. The next
  1503. 1:07:20step is we just need to to have data to
  1504. 1:07:24clean that data and to have that data
  1505. 1:07:26ready for us to train a model. So,
  1506. 1:07:28usually I'm going to focus here.
  1507. 1:07:31Sometimes this is part of my discovery
  1508. 1:07:34phase. Sometimes it's not depending on
  1509. 1:07:37how complex the project is. Okay. So,
  1510. 1:07:40this is sort of like a good breaking
  1511. 1:07:42point for me to go back to the client
  1512. 1:07:44and say, "Hey, uh, this is how we're
  1513. 1:07:46going to be solving the problem. This is
  1514. 1:07:48a quick prototype that we built. It
  1515. 1:07:51proves that we're going to be able to
  1516. 1:07:52solve this problem for sure. This is how
  1517. 1:07:54we're going to do it. Uh, it's going to
  1518. 1:07:56take this much time. It's gonna take
  1519. 1:07:59this much money approximately. Uh for
  1520. 1:08:02the next step, for the next iteration,
  1521. 1:08:04we're going to be taking a couple more
  1522. 1:08:06weeks or three weeks or four weeks,
  1523. 1:08:07whatever it is. This is how much you're
  1524. 1:08:09going to pay me for this. And we're
  1525. 1:08:11going to start by collecting the data,
  1526. 1:08:13by labeling the data, by cleaning the
  1527. 1:08:15data, by doing feature engineering of
  1528. 1:08:17the data. And that's going to be sort of
  1529. 1:08:19like a good start for the project. Okay.
  1530. 1:08:22Regarding the data, you want your data
  1531. 1:08:24set uh three characteristics on your
  1532. 1:08:27data sets. You need high quality, a lot
  1533. 1:08:30of diversity and the right amount of
  1534. 1:08:32quantity of data. Okay? So more data is
  1535. 1:08:35not necessarily better. You need the
  1536. 1:08:37right amount of data to train a model.
  1537. 1:08:40You want that data to be high quality
  1538. 1:08:42data and you're not you want that data
  1539. 1:08:44to be diverse to cover as many real case
  1540. 1:08:49scenarios as possible. That's sort of
  1541. 1:08:52like the goal here with collecting the
  1542. 1:08:54data. Okay, one parenthesis here. I'm
  1543. 1:08:58going to come back later in a different
  1544. 1:09:00session and this is going to make more
  1545. 1:09:02sense. But when you are collecting data,
  1546. 1:09:06you want to track
  1547. 1:09:09uh as much meta data that comes with
  1548. 1:09:12that data that explains that data that
  1549. 1:09:14contextualizes that data as you possibly
  1550. 1:09:17can. Let me give you an example. Imagine
  1551. 1:09:20that you're building a model and the
  1552. 1:09:22only thing that you need are pictures.
  1553. 1:09:24You need images. Don't just take
  1554. 1:09:26pictures and that's it.
  1555. 1:09:29Record the picture, the time you took
  1556. 1:09:32that picture, the conditions of the
  1557. 1:09:34place where you took that picture, the
  1558. 1:09:36camera that took that picture, the
  1559. 1:09:39length that took that picture. Anything
  1560. 1:09:41that explains and adds information
  1561. 1:09:45about that specific piece of data might
  1562. 1:09:49become crucial later. Okay. Another
  1563. 1:09:53example, we are putting cameras inside a
  1564. 1:09:56warehouse or
  1565. 1:09:58a store. You have all of those CCTV
  1566. 1:10:01cameras. From each camera, we're going
  1567. 1:10:04to be recording the videos that come
  1568. 1:10:06from the camera, but we also want to
  1569. 1:10:09record the location of the camera. We
  1570. 1:10:11also want to record the type of camera,
  1571. 1:10:14the lens that's installed on that
  1572. 1:10:17camera, anything that we consider is
  1573. 1:10:20going to be important later on. Why is
  1574. 1:10:23that? Just imagine that in a month one
  1575. 1:10:27camera goes down. The company replaces
  1576. 1:10:30that camera with the new model that came
  1577. 1:10:33out and now you're getting two video
  1578. 1:10:35feeds. One coming from old cameras, one
  1579. 1:10:38coming from the new camera. You want
  1580. 1:10:41that difference to be obvious. When
  1581. 1:10:44you're analyzing your data, maybe your
  1582. 1:10:46model stops working and you by
  1583. 1:10:49segmenting your data out, you realize
  1584. 1:10:52that the video feed coming from the new
  1585. 1:10:55camera is different somehow, maybe
  1586. 1:10:57different resolution,
  1587. 1:10:59whatever, than the video coming from the
  1588. 1:11:02old camera. And the only way you can do
  1589. 1:11:04that and you can analyze the data that
  1590. 1:11:06way is by having the meta data. I see a
  1591. 1:11:10mistake that I see is that people just
  1592. 1:11:11record the video feed and they don't
  1593. 1:11:13record anything else and that is a big
  1594. 1:11:15problem. So record as much as possible
  1595. 1:11:18that will help you later. Okay. All
  1596. 1:11:21right. So better data is better than
  1597. 1:11:26better models. I truly believe this. I
  1598. 1:11:29would rather work with a crappy model, a
  1599. 1:11:32simple model with a very very good data
  1600. 1:11:35set than the opposite. Okay? a very
  1601. 1:11:39state-of-the-art almost perfect model
  1602. 1:11:43with a crappy data set. Okay? So, don't
  1603. 1:11:46worry that much about building better
  1604. 1:11:49models. Worry more about building better
  1605. 1:11:52data sets. That's what you want to do.
  1606. 1:11:55Okay? So, we talked about the
  1607. 1:11:57characteristics of a good data set. We
  1608. 1:12:00talked about the quality of the data
  1609. 1:12:02set. Here is you want the data set to
  1610. 1:12:04have predicted features. You want the
  1611. 1:12:06data set to have the correct labels. You
  1612. 1:12:08want the data set not to have missing
  1613. 1:12:11values. You want data set to be
  1614. 1:12:12complete. You want a lot of diversity,
  1615. 1:12:15right? You want the data set to include
  1616. 1:12:18rare events, outliers, have low bias,
  1617. 1:12:22represent subgroups of the population
  1618. 1:12:25that you're capturing in your data set
  1619. 1:12:27proportionally. That's what a good
  1620. 1:12:29diversity means. And you have good
  1621. 1:12:32quantity. By good, I don't mean a lot of
  1622. 1:12:34data. I mean the right enough amount of
  1623. 1:12:36data. So enough samples for the model to
  1624. 1:12:39generalize
  1625. 1:12:41appropriate volume for the model. Okay,
  1626. 1:12:44we're going to see examples of how more
  1627. 1:12:47data is not necessarily better. Okay, so
  1628. 1:12:51here's one example here.
  1629. 1:12:54Predicting home prices and how more data
  1630. 1:12:56does not help. So imagine that you have
  1631. 1:12:59an initial data set from location A and
  1632. 1:13:02these are your images. I don't know if
  1633. 1:13:04you can see those images there. Uh I
  1634. 1:13:08generated those images with with an AI
  1635. 1:13:10model. Maybe Chad GPT generated those
  1636. 1:13:13for me. Those are crappy sort of like
  1637. 1:13:15crappy houses representing maybe a
  1638. 1:13:17location that's not too wealthy. Okay.
  1639. 1:13:20And let's say we have 10,000 houses
  1640. 1:13:22here. And the median average uh the the
  1641. 1:13:28median average price here, the mean
  1642. 1:13:29absolute error here is actually $18,500,
  1643. 1:13:35okay, from these neighborhoods. And now
  1644. 1:13:38you go out there and you augment that
  1645. 1:13:41data set by adding houses from location
  1646. 1:13:44B. Okay? So you just doubled the number
  1647. 1:13:47of houses. You went from 10,000 houses
  1648. 1:13:50to 20,000 houses, but because now you
  1649. 1:13:53added a bunch of rich people houses
  1650. 1:13:56here. Now your mean absolute error in
  1651. 1:14:00this data set goes up to 20,000 $21,000.
  1652. 1:14:05So the result of a model by the way this
  1653. 1:14:09in case I was not clear enough this m ae
  1654. 1:14:13mean absolute error that's sort of like
  1655. 1:14:16the the average error that my model has
  1656. 1:14:19given me the price of a house. Imagine
  1657. 1:14:21that we're building a model that's going
  1658. 1:14:22to predict the price of a house. With
  1659. 1:14:25this data set the error of that model is
  1660. 1:14:28going to be on average $18,000. That's
  1661. 1:14:31the mistake my model is making. on
  1662. 1:14:34average is up or down $18,000.
  1663. 1:14:37By adding more data to that data set,
  1664. 1:14:40the error is going to go up. Now, and
  1665. 1:14:43the reason is because the data that I'm
  1666. 1:14:45adding is actually making this this sort
  1667. 1:14:49of like problem space for the model way
  1668. 1:14:52harder to generalize to because now
  1669. 1:14:54there are houses that are sort of like
  1670. 1:14:57all over the place, very very expensive
  1671. 1:14:59houses. Does that make sense? more data
  1672. 1:15:03is not going to necessarily
  1673. 1:15:06make my model better. Better data will
  1674. 1:15:09not necessarily uh it's going to make my
  1675. 1:15:12model better. So
  1676. 1:15:14sometimes more data is actually worse
  1677. 1:15:18and I keep insisting on this.
  1678. 1:15:22I consult for companies and this is very
  1679. 1:15:24very normal. Companies call me because
  1680. 1:15:27they're having a problem with their
  1681. 1:15:28models. They ask me, "Hey, can you come
  1682. 1:15:30and take a look? let's see what's going
  1683. 1:15:31on. And [snorts] I go and I listen to
  1684. 1:15:33them and they tell me the problems
  1685. 1:15:35they're having and whatnot. And I
  1686. 1:15:37usually start by asking them, so what do
  1687. 1:15:39you think the solution would be? Okay.
  1688. 1:15:41And nine out of 10 times people tell me
  1689. 1:15:44we need more data. That's nine out of 10
  1690. 1:15:46times. If the model is not working well,
  1691. 1:15:49we just need more data.
  1692. 1:15:52And no, you I mean you might, but you
  1693. 1:15:56have to justify more data. Okay. So this
  1694. 1:16:00is sort of like the process that we go
  1695. 1:16:02through. This is very simple. This is
  1696. 1:16:05machine learning 101.
  1697. 1:16:07This is how an experiment that you can
  1698. 1:16:09run to determine whether you actually
  1699. 1:16:11need more data. I force companies to do
  1700. 1:16:13this. I force the team to do this and to
  1701. 1:16:16show me if they truly need more data. So
  1702. 1:16:19this is the way it works. Okay. So we
  1703. 1:16:21take the whole data set, the whole
  1704. 1:16:24training set that they're using and
  1705. 1:16:26we're gonna we're going to create we're
  1706. 1:16:28going to take 10% of that data set and
  1707. 1:16:31then we're going to take 20% of the data
  1708. 1:16:33set and then 30 and then 40 and then 50,
  1709. 1:16:35right? We're going to be creating these
  1710. 1:16:36subsets each of them with increasing
  1711. 1:16:39amount of data and we're going to be
  1712. 1:16:41training the model that they have and
  1713. 1:16:45testing it on the regular test set. So
  1714. 1:16:47imagine that we train with 10% of the
  1715. 1:16:49data set. Where is my mouse? And we're
  1716. 1:16:52going to get our model. Let's say our
  1717. 1:16:54model is model one. Uh we're going to
  1718. 1:16:57get sort of like a performance right
  1719. 1:16:58here. And when we do with 20%, the
  1720. 1:17:01performance is right here. And we do
  1721. 1:17:02with 70% the performance is going to be
  1722. 1:17:04right here. Okay. The more data we add,
  1723. 1:17:07we plot I mean we can see how that model
  1724. 1:17:10the accuracy of that model is going up.
  1725. 1:17:13So I'm going to ask you this comparing
  1726. 1:17:16model one with model two.
  1727. 1:17:19Which of these models could benefit from
  1728. 1:17:22more data? I mean, it's the answer is
  1729. 1:17:24obvious because it's right here on the
  1730. 1:17:26screen, but you can see that model one
  1731. 1:17:28could potentially use more data because
  1732. 1:17:31so far we have not seen a plateau. The
  1733. 1:17:35more data we add, the better the model
  1734. 1:17:38does. So we might, you know, think it's
  1735. 1:17:42it's it's yeah, it's it's obvious kind
  1736. 1:17:44of obvious that we might want to check
  1737. 1:17:46adding another 10% of the data and see
  1738. 1:17:49if the trajectory keeps going up. But
  1739. 1:17:53whenever we are in the case of model two
  1740. 1:17:56and I see this all the time, you already
  1741. 1:17:59see a plateau in this model from 80% of
  1742. 1:18:02the data set going forward like you can
  1743. 1:18:04see how the performance of the model is
  1744. 1:18:07not improving even though we're adding
  1745. 1:18:09more data to that data set. Okay. So
  1746. 1:18:12whenever I ask a company to do this
  1747. 1:18:14exercise, a team to do this exercise and
  1748. 1:18:17we analyze the learning curve and we see
  1749. 1:18:19that we are in the case of model two
  1750. 1:18:22that tells them it's not the data. You
  1751. 1:18:25can go and try to get more data but you
  1752. 1:18:28have no guarantees that data is going to
  1753. 1:18:30make that model go up. You need to focus
  1754. 1:18:33somewhere else not on the data. Okay?
  1755. 1:18:36Does this make sense?
  1756. 1:18:40All right. People spend too much worried
  1757. 1:18:42about their models. Every single book
  1758. 1:18:44that you can buy out there talks about
  1759. 1:18:46how to build models.
  1760. 1:18:49They don't take enough time to think
  1761. 1:18:51about their data. Okay? Data is very
  1762. 1:18:55very important. You should be spending
  1763. 1:18:58more time on your data, less time on
  1764. 1:19:00your models. I promise you. So there was
  1765. 1:19:03this like movement that started I don't
  1766. 1:19:05know maybe eight years ago, five years
  1767. 1:19:07ago. It's called datacentric AI where
  1768. 1:19:10the whole idea of datacentric AI was to
  1769. 1:19:12do AI to do machine learning by focusing
  1770. 1:19:16on the data instead of just optimizing
  1771. 1:19:19the models. Okay, this is what I usually
  1772. 1:19:22do. So I spend most of my time worrying
  1773. 1:19:26about the data because I believe or what
  1774. 1:19:29I've seen is that
  1775. 1:19:32the defaults of when I let's say I'm
  1776. 1:19:35going to create a computer vision model
  1777. 1:19:37classification model and I I'm going to
  1778. 1:19:39based off that classification model off
  1779. 1:19:42of an existing uh architecture the
  1780. 1:19:45restnet 50 architecture or the restnet
  1781. 1:19:48100 architecture and I'm going to use
  1782. 1:19:51very you
  1783. 1:19:53sensible hyperparameters like the
  1784. 1:19:56obvious ones. I'm going to use a batch
  1785. 1:19:58size of 32. I'm going to use a learning
  1786. 1:20:00rate of 0.003.
  1787. 1:20:03Things like that. That usually is enough
  1788. 1:20:06to get very very good results. Can I
  1789. 1:20:09improve that? Maybe. I'm not going to
  1790. 1:20:11spend a lot a long time doing that.
  1791. 1:20:13Instead, I'm going to try to focus a
  1792. 1:20:16model on the data. Okay. Here are some
  1793. 1:20:19of the things that you do, some of the
  1794. 1:20:21activities that you do. When you're
  1795. 1:20:22focusing on the model on the left versus
  1796. 1:20:25when you're focusing on the data on the
  1797. 1:20:26right. Okay. So, when you're focusing on
  1798. 1:20:28the model on when you're focusing on the
  1799. 1:20:30model, you're doing things like
  1800. 1:20:31hyperparameter tuning. What is the best
  1801. 1:20:34batch size for this data set or uh let's
  1802. 1:20:37implement an ensemble model or let's do
  1803. 1:20:39transfer learning or let's use
  1804. 1:20:42regularization.
  1805. 1:20:43you're trying to squeeze better
  1806. 1:20:46performance out of your model with the
  1807. 1:20:48data set that you have on data centric
  1808. 1:20:50AI instead you're focusing on the data
  1809. 1:20:52you're keeping the the model fixed and
  1810. 1:20:55you're saying how can we create new
  1811. 1:20:57features for example or modify the
  1812. 1:21:00existing features in our data set in
  1813. 1:21:03order to increase the amount of insights
  1814. 1:21:05we give the model that we have so the
  1815. 1:21:07model can make better predictions how
  1816. 1:21:09can we do balancing how can we improve
  1817. 1:21:12the labels the quality quality of those
  1818. 1:21:14labels. Maybe there are wrong labels.
  1819. 1:21:16How can we generate more fake data or
  1820. 1:21:19synthetic data to improve the ability
  1821. 1:21:22for the model to generalize? That's the
  1822. 1:21:24idea with that ascentric AI. This is
  1823. 1:21:27where over you know I usually spend most
  1824. 1:21:30of my time instead of on the first
  1825. 1:21:33column here. All right.
  1826. 1:21:35Okay. So you will start with data
  1827. 1:21:38centric with model centric. You would
  1828. 1:21:40build quickly a model. it works. it to
  1829. 1:21:43sort of like gives me results and from
  1830. 1:21:45there on I'm going to focus on data
  1831. 1:21:46centric AI and whenever I hit maybe my
  1832. 1:21:50ceiling I'm going to go back to model
  1833. 1:21:51centric do some tuning
  1834. 1:21:54see how can I prove this quickly and
  1835. 1:21:56then go back to dataentric sort of like
  1836. 1:21:57that back and forth is what I find that
  1837. 1:22:00it sort of like helped me okay so
  1838. 1:22:03finally before you start training the
  1839. 1:22:05model you need to produce part of the
  1840. 1:22:08data you need to produce consistent high
  1841. 1:22:11quality ground truth labels. Okay,
  1842. 1:22:16this here is always a huge bottleneck.
  1843. 1:22:19The lack of label data. So whenever I go
  1844. 1:22:22to companies, some of them some of those
  1845. 1:22:24companies have good quality data but
  1846. 1:22:28they don't have labels for that data and
  1847. 1:22:30creating those labels is is huge. It's a
  1848. 1:22:34huge effort. I think it was Karpati who
  1849. 1:22:36uh who said a long time ago when he was
  1850. 1:22:38working for Tesla uh somebody asked him
  1851. 1:22:41in an interview if he was giving $10
  1852. 1:22:43million more to improve Tesla uh or you
  1853. 1:22:47know the self-driving system uh where
  1854. 1:22:49would he spend that money and everyone I
  1855. 1:22:52I'm pretty sure everyone would have
  1856. 1:22:53guessed oh you know we will buy more
  1857. 1:22:55data centers or you know more people to
  1858. 1:22:58improve the algorithm and he said on
  1859. 1:23:00labeling I need better labels right I
  1860. 1:23:04would spend my $10 million in better
  1861. 1:23:06labels because it's a huge huge problem.
  1862. 1:23:09The lack of quality labels, uh, that's
  1863. 1:23:12just going to destroy everything. Just
  1864. 1:23:14to give you an idea of how hard it is or
  1865. 1:23:17just to sort of like good frame of mind,
  1866. 1:23:20imagine that you're building a
  1867. 1:23:21self-driving system and you're capturing
  1868. 1:23:23an image that looks like this and you
  1869. 1:23:26want to train your system and in order
  1870. 1:23:27to do that, you want to label every
  1871. 1:23:30single object that you see here that's
  1872. 1:23:31relevant for driving. Okay? So here
  1873. 1:23:34you're going to have cars and you're
  1874. 1:23:36going to have traffic lights and trees
  1875. 1:23:38and lanes and cars in front of you and
  1876. 1:23:41maybe pedestrians. So there's a bunch of
  1877. 1:23:44images here. Okay. So let's say you
  1878. 1:23:46capture one minute of video. That's all
  1879. 1:23:48you capture. One minute of video and you
  1880. 1:23:52capture that video at 30 frames per
  1881. 1:23:54second. So that means there are 30
  1882. 1:23:56images for every minute of video and
  1883. 1:23:59there are approximately 20 objects per
  1884. 1:24:02frame. So on every frame you're going to
  1885. 1:24:04see 20 different objects that you would
  1886. 1:24:06like to label. Okay. 60 seconds of video
  1887. 1:24:11times 30 frames per second times 20
  1888. 1:24:15objects. That's 36,000
  1889. 1:24:18boxes that somebody has to draw on the
  1890. 1:24:21screen to completely label that one
  1891. 1:24:24minute of video. So if you have somebody
  1892. 1:24:28that's capable of drawing one box every
  1893. 1:24:31second, it will take 10 hours to label
  1894. 1:24:36one minute of video. That's a long long
  1895. 1:24:40time. Okay, this is why labeling is
  1896. 1:24:44hard. There are bunch of algorithms that
  1897. 1:24:46do this that help with this problem.
  1898. 1:24:48People don't sit here obviously to label
  1899. 1:24:50every single one of those. But this is
  1900. 1:24:52just to give you an idea of how hard the
  1901. 1:24:56process is. Okay. Now you can do
  1902. 1:25:00labeling by hand. You can uh generate
  1903. 1:25:03labels using algorithms that exist or
  1904. 1:25:06you can use existing labels if your
  1905. 1:25:08problem
  1906. 1:25:10you know have built-in labels. there are
  1907. 1:25:12problems that uh you don't need to
  1908. 1:25:14generate labels because let's say you
  1909. 1:25:16want to predict whether it's going to
  1910. 1:25:18rain in the next hour or not. Well, the
  1911. 1:25:21label for that problem, you just wait an
  1912. 1:25:23hour and then you're going to have your
  1913. 1:25:25answer. So, that's the label is a
  1914. 1:25:26built-in label right there. You don't
  1915. 1:25:28need to generate a label manually. But
  1916. 1:25:30many problems do not have those built-in
  1917. 1:25:34labels. You have to create them. That's
  1918. 1:25:37where things get a little bit uh tricky.
  1919. 1:25:39So here is one algorithm that you can
  1920. 1:25:41use to sort of like uh avoid having to
  1921. 1:25:46label a lot of the data sort of like
  1922. 1:25:49shortcut create a model without you
  1923. 1:25:52spending a ton of time generating labels
  1924. 1:25:55because again it's very very expensive.
  1925. 1:25:58uh as an example uh so I uh when I was
  1926. 1:26:01working with my previous company uh we
  1927. 1:26:03were working with this company and one
  1928. 1:26:06thing that they were doing is uh is
  1929. 1:26:08digging for oil. So literally they
  1930. 1:26:11wanted to uh they had a company or an
  1931. 1:26:14operation that was drilling holes in the
  1932. 1:26:17ground finding oil. Okay. So they wanted
  1933. 1:26:20to sort of like create a model that
  1934. 1:26:22would predict where to drill next. Okay.
  1935. 1:26:26That's sort of like the idea.
  1936. 1:26:29But in order to do that
  1937. 1:26:31they we need a data and data needs
  1938. 1:26:34label. So imagine that I come here and I
  1939. 1:26:36say okay so here I need a label that
  1940. 1:26:40tells me in these coordinates if there
  1941. 1:26:42is oil yes or not. How do you think you
  1942. 1:26:46come up with that label?
  1943. 1:26:49You have to drill. That's that's the
  1944. 1:26:52only way you're gonna know if there is
  1945. 1:26:53oil or not. So you know if we have
  1946. 1:26:5710,000 samples we cannot just go out
  1947. 1:26:59there and start drilling holes to just
  1948. 1:27:02label the data set. So you have to
  1949. 1:27:03minimize the number of labels you
  1950. 1:27:05actually need. Okay. So active learning
  1951. 1:27:09helps with that. Okay. So active
  1952. 1:27:11learning technique. I've used it a ton.
  1953. 1:27:13It helps with that. It takes a bit to
  1954. 1:27:16sort of like understand how it works. So
  1955. 1:27:19hopefully we can work through this
  1956. 1:27:20really really quick. But just pay
  1957. 1:27:22attention here and hopefully this makes
  1958. 1:27:23sense. So we start with a data set.
  1959. 1:27:26Imagine that your goal is to build a
  1960. 1:27:28model here. Okay? But you start with a
  1961. 1:27:30data set that don't have any labels. So
  1962. 1:27:32you don't know anything about this data.
  1963. 1:27:34You don't have any labels here. So
  1964. 1:27:38the first step is just to take small
  1965. 1:27:41portion of that data set and label it.
  1966. 1:27:43Okay? You're not going to focus all of
  1967. 1:27:45your time labeling all of the data.
  1968. 1:27:47Remember that's going to be too
  1969. 1:27:48expensive. Just going to take let's say
  1970. 1:27:5010%.
  1971. 1:27:52and label that 10%. And with that
  1972. 1:27:55manually labeled data, you're just going
  1973. 1:27:58to train the first version of your
  1974. 1:27:59model. Okay? So only 10% of the data,
  1975. 1:28:02probably not enough to get a good model,
  1976. 1:28:05but you're going to get a model that's
  1977. 1:28:08better than not having a model. So now
  1978. 1:28:10we have that model, version one. You're
  1979. 1:28:13going to use that model to make
  1980. 1:28:15predictions to automatically generate
  1981. 1:28:18the labels of the other 90% of the data
  1982. 1:28:21set. So after this, this is what you're
  1983. 1:28:24going to get. You're going to have the
  1984. 1:28:2610% of the data set that you manually
  1985. 1:28:28labeled. You're going to get some data
  1986. 1:28:32that's automatically labeled by the
  1987. 1:28:34version one of the model, but I'm
  1988. 1:28:36splitting that in two separate sets. the
  1989. 1:28:40automatically labeled and the complex
  1990. 1:28:43samples. What I mean by this is
  1991. 1:28:46depending on the type of model that you
  1992. 1:28:48create, you will find that that model is
  1993. 1:28:51very confident in certain predictions
  1994. 1:28:55and less confident in other predictions.
  1995. 1:28:59So if you separate those now you can
  1996. 1:29:01have some the high confidence
  1997. 1:29:06samples you can just assume those are
  1998. 1:29:08correct because your model should be
  1999. 1:29:10good enough to predict those and the
  2000. 1:29:13least confident samples you can sort of
  2001. 1:29:16like put them in the these are very
  2002. 1:29:19complex for my model therefore I'm gonna
  2003. 1:29:23need to do something with them. So, what
  2004. 1:29:25you are going to do with them is you're
  2005. 1:29:27gonna send this red sliver of samples.
  2006. 1:29:30You're gonna send that. Oh, there are
  2007. 1:29:32people here trying to enter. Hold on.
  2008. 1:29:35You're going to send the How do I do
  2009. 1:29:36that? Oh, there we go.
  2010. 1:29:39You're going to send this sort of like
  2011. 1:29:41red liver of samples to the labeling
  2012. 1:29:46team. The labeling team then will
  2013. 1:29:48automatically label this. Not
  2014. 1:29:51automatically, manually label this.
  2015. 1:29:53You're going to poke the holes on those
  2016. 1:29:55ones there and then you're going to
  2017. 1:29:57restart the process again. The next
  2018. 1:30:00model version two, you're going to use
  2019. 1:30:01the many level samples. You could use
  2020. 1:30:03the automatically labelled samples
  2021. 1:30:05together. You're going to train the
  2022. 1:30:06second version of the model. You're
  2023. 1:30:08going to apply the same principle going
  2024. 1:30:10forward. And every single round, your
  2025. 1:30:13goal is to determine the complex samples
  2026. 1:30:16here. And if you determine the complex
  2027. 1:30:19samples, those are the candidates for
  2028. 1:30:22you to manually label. Next,
  2029. 1:30:25I'm going to talk about in case that's
  2030. 1:30:27the question that you guys have, but I'm
  2031. 1:30:29going to let you speak right now. Uh
  2032. 1:30:31Adulson,
  2033. 1:30:33the next few slides I'm going to show
  2034. 1:30:35you what how to determine what the
  2035. 1:30:38complex samples are. But if you trust me
  2036. 1:30:42and you sort of like believe me that we
  2037. 1:30:44can do that correctly,
  2038. 1:30:46active learning have shown that we can
  2039. 1:30:49build a model as good as if you if you
  2040. 1:30:54label the whole data set. Basically, in
  2041. 1:30:56other words, you do not need labels for
  2042. 1:30:59every single sample in order to have the
  2043. 1:31:02best possible model. You can do it more
  2044. 1:31:05efficiently. and active learning will
  2045. 1:31:07let you find what those what the
  2046. 1:31:09critical samples are. Uh Adelson, what's
  2047. 1:31:12up?
  2048. 1:31:14>> Oh, thank you, Santiago. So, regarding
  2049. 1:31:15to um the size of the data set some
  2050. 1:31:19slides ago, um the test set
  2051. 1:31:24I think I think the test set should be
  2052. 1:31:26also subplit, right? I think there could
  2053. 1:31:30be some issues if we were evaluating
  2054. 1:31:33directly on the actual test set, right?
  2055. 1:31:37I sorry you're going to have to repeat
  2056. 1:31:39that. What is this the test set role
  2057. 1:31:42here? What do you mean by the test set
  2058. 1:31:44here?
  2059. 1:31:45>> Because uh you said um in order to know
  2060. 1:31:49if we need more data or not subsplit
  2061. 1:31:51your the data you have and then you
  2062. 1:31:54continually train and add 10% more. But
  2063. 1:31:58at each iteration you should test right.
  2064. 1:32:01So I'm just concerned about this test
  2065. 1:32:03set. this test set cannot be the actual
  2066. 1:32:07uh test set right can need to be one of
  2067. 1:32:11the splits as well right so it depends
  2068. 1:32:14if you're starting so there are two
  2069. 1:32:16approaches here approach number one is
  2070. 1:32:18that you do have a test set set aside
  2071. 1:32:21it's not part of this slide here and
  2072. 1:32:24that's the test set you're going to be
  2073. 1:32:25using to test whatever model you're
  2074. 1:32:27building that's one that test set where
  2075. 1:32:30is it coming from well maybe it's data
  2076. 1:32:31that you labeled manually the second
  2077. 1:32:33approach which is that you're studying
  2078. 1:32:35with a data set that has no labels, but
  2079. 1:32:38part of the manually labelled samples,
  2080. 1:32:40those are going to become your test set.
  2081. 1:32:43And as you increase the manually
  2082. 1:32:45labelled samples, you're also increasing
  2083. 1:32:48the amount of that data that goes into
  2084. 1:32:50the test set. Obviously, in those cases,
  2085. 1:32:52you will never use the test samples to
  2086. 1:32:55train a version of the model. You will
  2087. 1:32:57keep those aides. I did not represent
  2088. 1:32:59the test set here, but hopefully that
  2089. 1:33:01makes sense. Does that answer your
  2090. 1:33:02question?
  2091. 1:33:03>> Yeah. Yeah. Mhm. That's clarify. Thank
  2092. 1:33:05you.
  2093. 1:33:06>> Yeah. So imagine just just to make it
  2094. 1:33:08more concrete, imagine that this instead
  2095. 1:33:10of instead of manually labeling 10% of
  2096. 1:33:13my data set, I'm going to label 15% of
  2097. 1:33:15my data set. 5% of it I'm going to keep
  2098. 1:33:17aside for my test set. The other 10% is
  2099. 1:33:19the one that you see represented here.
  2100. 1:33:22Now, the next time I do manual labeling,
  2101. 1:33:24which is right here. Now, out of all of
  2102. 1:33:26the data that I manually labeled, I'm
  2103. 1:33:29going to get another maybe, I don't
  2104. 1:33:30know, 20% of that data and throw it
  2105. 1:33:32away. Not throw it away, set it aside to
  2106. 1:33:35increase the size of my test set. I want
  2107. 1:33:38my test set to become stronger as my
  2108. 1:33:41model becomes stronger as well. And then
  2109. 1:33:43I want to keep repeating the process
  2110. 1:33:45there. Make sense?
  2111. 1:33:47>> Yeah. Thank you.
  2112. 1:33:49>> Hi, uh, Pavang, what's up?
  2113. 1:33:52>> Hi. Um I just wanted to know your
  2114. 1:33:54experience like have you had a chance to
  2115. 1:33:56use any LLM models to generate synthetic
  2116. 1:33:59labels? Uh if so any popular that that
  2117. 1:34:03are like well known.
  2118. 1:34:05>> Yeah. Yeah. I've used LLM to generate
  2119. 1:34:08synthetic labels. Um well synthetic I
  2120. 1:34:11don't know what a synthetic label is to
  2121. 1:34:14generate to automatically label data if
  2122. 1:34:16that's what you mean. Yes.
  2123. 1:34:18>> Okay.
  2124. 1:34:19And any like uh do you recall any like
  2125. 1:34:22models that you might have used?
  2126. 1:34:24>> I mean it's I usually so the only time
  2127. 1:34:28I've used them is when the LLM I know
  2128. 1:34:32for certain that the LLM is going to be
  2129. 1:34:34very good at providing those labels. So
  2130. 1:34:36for example classifying customer
  2131. 1:34:38requests.
  2132. 1:34:40Customers send a paragraph they want to
  2133. 1:34:43do something. you create a bunch of
  2134. 1:34:46categories and the LLM is going to read
  2135. 1:34:48the text and classify that text in one
  2136. 1:34:52of those categories or you've also seen
  2137. 1:34:55uh sentiment analysis is another one
  2138. 1:34:57that LLM do very well like is the client
  2139. 1:35:00uh is this review positive or negative
  2140. 1:35:02right very easy for the LLM to classify
  2141. 1:35:06given portion of text sent by a client
  2142. 1:35:08into positive or negative review so
  2143. 1:35:11those are the examples that I've used
  2144. 1:35:13LLM to to uh to generate labels. I don't
  2145. 1:35:16need to read the text myself and say
  2146. 1:35:20positive or negative.
  2147. 1:35:21>> Understood. Understood. That's okay.
  2148. 1:35:24>> Cool.
  2149. 1:35:25>> Thank you.
  2150. 1:35:26>> All right. So, the question that remains
  2151. 1:35:28unanswered here is what the heck are
  2152. 1:35:30these complex samples? uh because you
  2153. 1:35:33know if you're able to identify those
  2154. 1:35:35complex samples out of all of the
  2155. 1:35:38predictions that the model produces well
  2156. 1:35:40that's the key because if those complex
  2157. 1:35:43samples I I I call them here complex
  2158. 1:35:46some people call them most informative
  2159. 1:35:50uh if we can identify good complex
  2160. 1:35:52samples that means that we're going to
  2161. 1:35:55be able to learn really really quick to
  2162. 1:35:57to sort of like the model will progress
  2163. 1:36:00really really
  2164. 1:36:02If I do this run, if my complex samples
  2165. 1:36:05are not that interesting for the model,
  2166. 1:36:07the model will not improve. Okay? So the
  2167. 1:36:10the better those samples are, the faster
  2168. 1:36:12my model will improve. Okay? So
  2169. 1:36:15there are usually I I mean there are
  2170. 1:36:18entire PhDs
  2171. 1:36:20thesis
  2172. 1:36:22created just on this topic, okay?
  2173. 1:36:25Because it's a topic with a lot of
  2174. 1:36:26research behind. But usually the two
  2175. 1:36:29techniques that I've personally used and
  2176. 1:36:32again there are hundreds of techniques
  2177. 1:36:34that you can use here are uncertainty
  2178. 1:36:38and diversity. So I want to pick my
  2179. 1:36:42complex samples or my most informative
  2180. 1:36:44samples those that increase the
  2181. 1:36:46uncertainty and the diversity of my data
  2182. 1:36:50set. So let me give you here uh first
  2183. 1:36:53uncertainty what uncertainty means.
  2184. 1:36:55Okay. So these are samples that my model
  2185. 1:36:59find confusing. I want to identify any
  2186. 1:37:02samples that my model it's making a
  2187. 1:37:06mistake
  2188. 1:37:07uh thinking the the the data is
  2189. 1:37:10something but it's actually something
  2190. 1:37:11else. Uh
  2191. 1:37:14here it's just me again trying to
  2192. 1:37:16generate pictures here with AI. But here
  2193. 1:37:18you can see a cat that actually looks
  2194. 1:37:20like a duck. Kind of like it's just
  2195. 1:37:23there is a bone there. Or this cat here
  2196. 1:37:26is also wearing a custom of a dog. So
  2197. 1:37:28you can imagine a model just looking at
  2198. 1:37:30these pictures and saying, "Oh, I think
  2199. 1:37:32that's a dog." When it actually is not a
  2200. 1:37:34cat. This is a dog, but it looks to me
  2201. 1:37:36like a cat. It's sort of like half the
  2202. 1:37:38face like a cat. Is kind of weird. And
  2203. 1:37:40this looks like I don't know like a
  2204. 1:37:42pillow. This little cat there. Maybe a
  2205. 1:37:44dog. I don't even know what it is, but
  2206. 1:37:46you get the idea. is samples that might
  2207. 1:37:49be one way or the other. Imagine a
  2208. 1:37:52binary classifier.
  2209. 1:37:54And in a binary classification problem,
  2210. 1:37:57your model is going to be this dotted
  2211. 1:37:59black line. Any samples that are near
  2212. 1:38:03that boundary that could either be left
  2213. 1:38:06or right. If you just move the model one
  2214. 1:38:08little bit, you will have to change the
  2215. 1:38:11classification of those samples. So any
  2216. 1:38:14samples near that boundary those are
  2217. 1:38:17good uh candidates for me to label. I
  2218. 1:38:21want to actually find out the label of
  2219. 1:38:25those samples because if I if I find out
  2220. 1:38:28that the label of this sample is
  2221. 1:38:29actually blue not green. Right now it's
  2222. 1:38:32on the green side but if this is
  2223. 1:38:34actually blue that gives the model a lot
  2224. 1:38:37of information. the model should
  2225. 1:38:39accommodate for that loop should move to
  2226. 1:38:41the left. Okay, so these are samples
  2227. 1:38:45that have the potential of teaching my
  2228. 1:38:47model a lot. That's what uncertainty
  2229. 1:38:49sampling is. Now in the case of
  2230. 1:38:52diversity sampling is
  2231. 1:38:56samples that are far far away from that
  2232. 1:38:58decision boundary. Those could be edge
  2233. 1:39:01cases. Those could be outliers. I want
  2234. 1:39:04my model to know about those. So the
  2235. 1:39:06pictures here, you can see like a
  2236. 1:39:08nighttime picture of a deer and it's
  2237. 1:39:11it's a picture that's completely
  2238. 1:39:13different from every other animal
  2239. 1:39:15picture that I have on my data set. I
  2240. 1:39:17want to label that one there. Or maybe a
  2241. 1:39:19zoomed out butterfly. This just usually
  2242. 1:39:23an unusual picture of a butterfly very
  2243. 1:39:26very close. or images that have low
  2244. 1:39:29contrast
  2245. 1:39:31because you know the animals and in both
  2246. 1:39:33images sort of like blend with the
  2247. 1:39:35background. So it's just anything
  2248. 1:39:38that could potentially be an edge case
  2249. 1:39:41an outlier. I want to label those. In
  2250. 1:39:45the case of the binary classifier, those
  2251. 1:39:48will be these data points right here
  2252. 1:39:51that are very very far away from
  2253. 1:39:53everything else in the data set. those
  2254. 1:39:57will provide a lot of information to my
  2255. 1:40:00model. Okay, if I identify those two,
  2256. 1:40:04I'm gonna have a way to label data that
  2257. 1:40:08will improve my model way faster and
  2258. 1:40:11obviously the process is going to be way
  2259. 1:40:13cheaper than having to label every
  2260. 1:40:16single sample in my data set. All right,
  2261. 1:40:18any questions so far? We're going to go
  2262. 1:40:20to the last of the topics here and then
  2263. 1:40:23we're done for today. The last of the
  2264. 1:40:25topic is feature engineering. Uh again,
  2265. 1:40:28you can also create like a whole career
  2266. 1:40:31of a feature engineering. Uh
  2267. 1:40:35I find out that the best people that I
  2268. 1:40:37know that do this well are those that
  2269. 1:40:39are they participate in Kaggle. Everyone
  2270. 1:40:42who who's done Kaggle has gone through
  2271. 1:40:44this process. A bunch of techniques come
  2272. 1:40:47out of that. This is sort of like an
  2273. 1:40:49art. This is the ability to take a data
  2274. 1:40:51set and
  2275. 1:40:54shape that data set in a way that
  2276. 1:40:57maximizes the amount of insights you put
  2277. 1:41:01in front of the model. Okay? If you
  2278. 1:41:04don't do that, your models might
  2279. 1:41:06struggle. Models might struggle. It's
  2280. 1:41:08sort of like you are hiding the
  2281. 1:41:09information from the model. But if you
  2282. 1:41:11sort of like put that information
  2283. 1:41:13outside, models are going to do really
  2284. 1:41:16really good. Okay. Again, you want to
  2285. 1:41:18learn feature engineering, my best
  2286. 1:41:20recommendation is just go join Kaggle,
  2287. 1:41:22start participating in competitions
  2288. 1:41:24there.
  2289. 1:41:26Just just super super cool. Uh there are
  2290. 1:41:28a bunch of importances. I mean picture
  2291. 1:41:30engineering has a bunch of importances.
  2292. 1:41:32The the one that I really really really
  2293. 1:41:34care about is more accurate models. I
  2294. 1:41:36think this is this should be enough. But
  2295. 1:41:38yeah, you can also your models are going
  2296. 1:41:39to become faster. They're going to be
  2297. 1:41:41simpler uh you know if if you do good
  2298. 1:41:44feature engineering here. So bunch of
  2299. 1:41:46techniques for feature engineering.
  2300. 1:41:48Bunch of things that we can sort of like
  2301. 1:41:51put under the umbrella of feature
  2302. 1:41:53engineering. The first one is creating
  2303. 1:41:55new features. You have a data set. You
  2304. 1:41:58want to create a model and when you
  2305. 1:42:00analyze that data set you realize that
  2306. 1:42:02by you creating new features you will
  2307. 1:42:05make it easier for the model to learn
  2308. 1:42:07that data set. Okay. So let me give you
  2309. 1:42:10a few examples. Imagine that the
  2310. 1:42:12original data set contains the price of
  2311. 1:42:15products and contains the sold date of
  2312. 1:42:19those products. Okay, that's the
  2313. 1:42:21original data set. Okay, so one thing
  2314. 1:42:24that you could do is what we call bin.
  2315. 1:42:28Okay. And being here is because you know
  2316. 1:42:32that the problem you're trying to solve
  2317. 1:42:35cares about products that are cheaper
  2318. 1:42:38for some reason, products that are under
  2319. 1:42:41$50.
  2320. 1:42:43Maybe you want to make that information
  2321. 1:42:46painfully obvious to the model. And
  2322. 1:42:48instead of letting the model figure that
  2323. 1:42:50out from the price itself, you're going
  2324. 1:42:52to create a new feature that's called
  2325. 1:42:54under 50. That's going to be a binary
  2326. 1:42:57feature. is going to contain one if the
  2327. 1:42:59price is less than $50 or zero if the
  2328. 1:43:02price is not less than $50. Okay, very
  2329. 1:43:06simple for the model to just process
  2330. 1:43:08this feature here and
  2331. 1:43:12signal for those products that matter
  2332. 1:43:15for the problem you're creating. Okay,
  2333. 1:43:18that's bin. Temporal feature engineering
  2334. 1:43:21is what you do with the date. So maybe
  2335. 1:43:23for example you want to extract the
  2336. 1:43:26quarter number where this the sale
  2337. 1:43:29happened
  2338. 1:43:31uh into a new feature and this was you
  2339. 1:43:33know this happened in the fourth quarter
  2340. 1:43:35and these three happened in the first
  2341. 1:43:37quarter or maybe you want to specify
  2342. 1:43:40whether that specific day fell on a
  2343. 1:43:44holiday. And now you get here this one
  2344. 1:43:47for holidays and zeros for any other
  2345. 1:43:51date that are not holidays. Again, here
  2346. 1:43:54you're basically creating new
  2347. 1:43:57information from the model. Taking what
  2348. 1:43:59already exists
  2349. 1:44:01and shaping it in a different way for
  2350. 1:44:04the model to process. The other
  2351. 1:44:06technique is clustering. And this is I
  2352. 1:44:08don't know for some reason you have a
  2353. 1:44:10separate model maybe and you process all
  2354. 1:44:13of your products and you cluster them
  2355. 1:44:17following a specific characteristic. So
  2356. 1:44:19maybe some of these products well were
  2357. 1:44:22sold to men and some of them were sold
  2358. 1:44:25to women and that's a cluster that you
  2359. 1:44:28create with zero for men and one for
  2360. 1:44:30women and that's another information
  2361. 1:44:33you're giving to the model. Okay, this
  2362. 1:44:35is what creating new features looks
  2363. 1:44:39like. Okay, so one specific example, a
  2364. 1:44:42real example, this is also for fashion
  2365. 1:44:44file. These are bags and we had these
  2366. 1:44:47computer vision models like I I told you
  2367. 1:44:50about that the goal of those models was
  2368. 1:44:52to classify
  2369. 1:44:56classify specific image from a back uh
  2370. 1:45:00into a brand and into a model of that
  2371. 1:45:03brand. So maybe you get a Hermes, Dato,
  2372. 1:45:08whatever, CC, whatever. They have just
  2373. 1:45:10some weird names. So
  2374. 1:45:12to do this, we were using images sent by
  2375. 1:45:16the customer. So the customer wants to
  2376. 1:45:18sell a bag. They take a bunch a bunch of
  2377. 1:45:21pictures off of that bag. They sent us,
  2378. 1:45:24I don't know, 10 14 pictures. We took
  2379. 1:45:26all of those pictures through a
  2380. 1:45:28classifier, and that classifier would
  2381. 1:45:30tell us what the back was. The problem
  2382. 1:45:32is that because we're working with
  2383. 1:45:35multiple pictures,
  2384. 1:45:37the classifier might give different
  2385. 1:45:39answers for different pictures. Okay,
  2386. 1:45:42that was the problem. So, imagine that I
  2387. 1:45:44have a back and I have a back. Where is
  2388. 1:45:46the back? Yes, I have a back right here.
  2389. 1:45:51So, I have a back and I send this
  2390. 1:45:54picture of the back and then I send this
  2391. 1:45:56picture of the back and then I send this
  2392. 1:45:58picture of the back and then I send this
  2393. 1:46:00picture of the back and then I open the
  2394. 1:46:02back and send another picture inside and
  2395. 1:46:04another picture here. You get the idea.
  2396. 1:46:06That's how people send pictures. But
  2397. 1:46:09this here does not provide the same
  2398. 1:46:12amount of information
  2399. 1:46:14than this here. Right? So I might get an
  2400. 1:46:17answer from this picture that's
  2401. 1:46:21different from this picture
  2402. 1:46:22unfortunately. So we had to solve that
  2403. 1:46:25problem. And the way we solve that
  2404. 1:46:27problem is just by voting. That's just,
  2405. 1:46:30you know, let's get all of the models or
  2406. 1:46:33the pictures and get, you know, voting
  2407. 1:46:36and, you know, whatever brand had the
  2408. 1:46:40most votes. That's the final answer. And
  2409. 1:46:43that worked relatively well.
  2410. 1:46:46But we discovered something that made it
  2411. 1:46:49so much better. I think it was, let me
  2412. 1:46:51see if I wrote it here. I did not write
  2413. 1:46:53it here. I forgot. But I think it was 6
  2414. 1:46:56to 8% better, which translates into a
  2415. 1:47:00lot of money, by the way.
  2416. 1:47:02And that was creating a new feature
  2417. 1:47:06that will tell us the order, the package
  2418. 1:47:10of images that the client sent. We used
  2419. 1:47:14the order of those images as a new
  2420. 1:47:18feature for the voting model. So
  2421. 1:47:21basically when the client takes a
  2422. 1:47:23picture of the back, if the client takes
  2423. 1:47:25this as the first picture, we will pass
  2424. 1:47:28that's order zero. If the client took
  2425. 1:47:30this as the second picture, we will say
  2426. 1:47:33that's order one, etc. It turns out that
  2427. 1:47:36most people when they send a package of
  2428. 1:47:38images, they usually start here.
  2429. 1:47:41Like people don't take this picture,
  2430. 1:47:43upload it, and then take this picture,
  2431. 1:47:45upload it, and then finally take this
  2432. 1:47:47picture and upload it. At least not most
  2433. 1:47:49people. So by adding the order that they
  2434. 1:47:53use when uploading the images to the
  2435. 1:47:55website, that allowed us to provide uh
  2436. 1:48:01more weight to the votes of the brand
  2437. 1:48:07and model coming from the first few
  2438. 1:48:10pictures. with respect to the other
  2439. 1:48:13picture. So basically we were making the
  2440. 1:48:15assumption that the very first picture
  2441. 1:48:17was going to provide the most amount of
  2442. 1:48:19information then the second and third
  2443. 1:48:22will be the second and then everything
  2444. 1:48:24else will help but will not be decisive
  2445. 1:48:30and by doing that we were able to
  2446. 1:48:32increase the sort of like the capacity
  2447. 1:48:34of our model to make good predictions in
  2448. 1:48:36five six%. Okay, by the way, after we
  2449. 1:48:39realized this, we asked the web team to
  2450. 1:48:43change the interface to notch people to
  2451. 1:48:46start by uploading the front and then
  2452. 1:48:48uploading the back, etc. So, and by
  2453. 1:48:50doing that, we were sort of like
  2454. 1:48:53increasing the ability or the
  2455. 1:48:54probability that people were were
  2456. 1:48:56uploading the pictures in the right
  2457. 1:48:58order. So, that's an example of feature
  2458. 1:49:00engineering where you're adding
  2459. 1:49:02something new to the problem. you're
  2460. 1:49:03creating a new feature here that's going
  2461. 1:49:06to help you make better decisions. Okay,
  2462. 1:49:09so another sort of like category of
  2463. 1:49:11feature engineering is vectorization. So
  2464. 1:49:13this is when you turn text into numbers
  2465. 1:49:17just to keep it simple. Okay, models
  2466. 1:49:20work with numbers. They don't like text.
  2467. 1:49:22So you need to find techniques that turn
  2468. 1:49:24text into numbers. So let me give you
  2469. 1:49:26one particular example here. So imagine
  2470. 1:49:29that you have a data set with the name
  2471. 1:49:32of the animal and you want to process
  2472. 1:49:34that data set you know among other
  2473. 1:49:36features but there is a feature that's
  2474. 1:49:37called animal and you have cats and dogs
  2475. 1:49:39and horses and whatever
  2476. 1:49:42and you want to process that data set
  2477. 1:49:44with your model. You have to turn these
  2478. 1:49:47animals into numbers in order for your
  2479. 1:49:49data set to for your model to work with
  2480. 1:49:52it. And a very very simple technique is
  2481. 1:49:55called label encoding. And label
  2482. 1:49:57encoding is basically going to create
  2483. 1:49:59this mapping, right? It's going to
  2484. 1:50:02create this map that says, okay, so
  2485. 1:50:03whatever I see a cat, turn that into a
  2486. 1:50:06one and whatever I see a dog, turn it
  2487. 1:50:09into a two, etc., etc., right? That's
  2488. 1:50:12the idea. So what we want to do here or
  2489. 1:50:15when you process when you take label
  2490. 1:50:17encoding and process your data set, this
  2491. 1:50:19is what you're going to get. you're
  2492. 1:50:20going to get a new column that contains
  2493. 1:50:23the mapping number, the encoded number
  2494. 1:50:27instead of the actual text. And now this
  2495. 1:50:31data set you can actually process with a
  2496. 1:50:33model. Now can anybody tell me
  2497. 1:50:36I mean this works by the way works very
  2498. 1:50:38well but there are problems with this.
  2499. 1:50:40Can anybody tell me what the problem is?
  2500. 1:50:43Any idea why this could become
  2501. 1:50:45problematic? Why don't we just do this
  2502. 1:50:49every single time? So Diego is saying
  2503. 1:50:51cardinality. Diego, cardinality is a big
  2504. 1:50:54big word. Can you explain further what
  2505. 1:50:57do you mean by that?
  2506. 1:50:59>> Yes, of course. So we can have many
  2507. 1:51:01multiple options for example cats, dogs,
  2508. 1:51:04horses, I don't know worms, etc.
  2509. 1:51:08So as long as that that that list draws
  2510. 1:51:12the number of embedible encodings label
  2511. 1:51:15encodings will grow also and we will
  2512. 1:51:17have a really really sparse set of
  2513. 1:51:19labels. Yeah. And here is the thing. So
  2514. 1:51:22I'm going to add on top of what Diego
  2515. 1:51:24just said to a model. These numbers here
  2516. 1:51:29have a meaning. They are numerical
  2517. 1:51:32values. So the model might look at this
  2518. 1:51:36and say, well, this ID3 feature here or
  2519. 1:51:39this ID row here, ID3 row
  2520. 1:51:44somehow is three times more important
  2521. 1:51:46than this one here because the magnitude
  2522. 1:51:49of the number is three and the other one
  2523. 1:51:52is one. So maybe maybe I should be
  2524. 1:51:54paying more attention to this one here
  2525. 1:51:58rather than this one here. See what the
  2526. 1:52:00problem is? The bigger that distance is,
  2527. 1:52:03as Diego said, as the cardinality rows,
  2528. 1:52:05if I have a thousand animals, now we're
  2529. 1:52:07going to have rows with a value of one
  2530. 1:52:10and rows with the value of a thousand.
  2531. 1:52:14My model will tend to pay more
  2532. 1:52:16attention, especially if you're using,
  2533. 1:52:18let's say, a neural network, to the rows
  2534. 1:52:21with a thousand rather than rows with a
  2535. 1:52:24one. We don't want that to happen. We
  2536. 1:52:26want all all of our values to be
  2537. 1:52:29standardized. And we're going to see
  2538. 1:52:31that in another technique. But that's a
  2539. 1:52:33problem with label encoding. How do we
  2540. 1:52:35solve that? Well, there is a technique
  2541. 1:52:37for example that's called one hot
  2542. 1:52:38encoding that does not have that
  2543. 1:52:40hierarchical problem because we can turn
  2544. 1:52:43our animals or this column, we can turn
  2545. 1:52:47it into multiple columns. So now instead
  2546. 1:52:49of having an animal column, we're going
  2547. 1:52:50to have is cat, is dog, is horse. And
  2548. 1:52:54we're going to use a one or a zero to
  2549. 1:52:57specify well if it's a cat it's going to
  2550. 1:52:59have a one here and zero everyone else.
  2551. 1:53:02If it's if it's a dog it's going to have
  2552. 1:53:04a zero here and cat one in the dog and
  2553. 1:53:07zero everywhere else. So as you can see
  2554. 1:53:09in this particular case the model will
  2555. 1:53:12never get confused than a horse is more
  2556. 1:53:15valuable than a cat because there are no
  2557. 1:53:18differences here. Okay. So you can have
  2558. 1:53:19as many animals as you want and all of
  2559. 1:53:22the rows are going to be zeros or ones.
  2560. 1:53:25But cardinality is still a problem here.
  2561. 1:53:28If you have many many animals, you're
  2562. 1:53:31going to have a data set that with many
  2563. 1:53:33many columns. You don't want that.
  2564. 1:53:35That's going to be really really
  2565. 1:53:36horrible. So you need a better technique
  2566. 1:53:39to solve that. So here is how to or a
  2567. 1:53:43different technique. Not how to solve
  2568. 1:53:44that but is a different technique that
  2569. 1:53:47is very very effective. is called target
  2570. 1:53:49encoding. So with target encoding here,
  2571. 1:53:52you're going to be sort of like doing a
  2572. 1:53:54trick where you're going to be taking
  2573. 1:53:56your original data set and you're going
  2574. 1:53:58to be averaging the target of the data
  2575. 1:54:02and using that as the encoded value. So
  2576. 1:54:05what I mean by that is imagine that I
  2577. 1:54:07have different IP addresses which are
  2578. 1:54:10how many IP addresses can you have? It's
  2579. 1:54:12just the number is just unbounded or
  2580. 1:54:14just too many. So, I'm going to get
  2581. 1:54:16every single value that's the same.
  2582. 1:54:1817216 254.3. You can see it three times.
  2583. 1:54:22That's what I put them in red. And I'm
  2584. 1:54:24going to take the target value. The
  2585. 1:54:26target is the value that you want to
  2586. 1:54:27come up with. The value that you want to
  2587. 1:54:29predict. I'm going to get the target
  2588. 1:54:31value. I'm going to average that target
  2589. 1:54:33value across all of those three
  2590. 1:54:35examples. So, I'm going to add 5200 with
  2591. 1:54:3937.99 with 5230 divided by three. That's
  2592. 1:54:43the new IP address. That's the encoded
  2593. 1:54:45IP address, okay, that I'm going to go
  2594. 1:54:48with. So now I'm going to have 4743 and
  2595. 1:54:50the target will be 52000. 4743, the
  2596. 1:54:54target will be 3799.
  2597. 1:54:56See how I turned this non-numerical
  2598. 1:55:00value, which is an IP into a numerical
  2599. 1:55:02value by just using target encoding. And
  2600. 1:55:06then I'm going to do the same thing with
  2601. 1:55:08blue. Okay, the blue IP here, I'm going
  2602. 1:55:10to add these two values divided by two.
  2603. 1:55:14That's going to be my new encoded column
  2604. 1:55:17and that is going to be my new data set.
  2605. 1:55:19Now there are I don't know if anybody's
  2606. 1:55:22raising their hands. Usually people are
  2607. 1:55:23just freaking out at this point. There
  2608. 1:55:25are some things to consider when you're
  2609. 1:55:28doing target encoding. So number one
  2610. 1:55:30target encoding is very very effective
  2611. 1:55:33but you need to have a data set that is
  2612. 1:55:36not that uh is where every sample in the
  2613. 1:55:41data set have a lot of representation in
  2614. 1:55:43the data set. If you have a data set
  2615. 1:55:46where you have only one animal or only
  2616. 1:55:49one IP address that's the same and that
  2617. 1:55:52IP address does not repeat multiple
  2618. 1:55:54times. What's going to end up happening
  2619. 1:55:57is that there's not going to be anything
  2620. 1:55:58to combine here. So you're basically
  2621. 1:56:01going to be showing your model the
  2622. 1:56:04actual prediction value. So this value
  2623. 1:56:06here will be 52000. This value here will
  2624. 1:56:09be 5385.
  2625. 1:56:11You're asking the model giving if I give
  2626. 1:56:14you 5200 predict 52000 which is stupid.
  2627. 1:56:18So if your data set is not dense enough
  2628. 1:56:21target encoding is not going to work. If
  2629. 1:56:23you have many many samples for each IP
  2630. 1:56:26address, the combination of those are
  2631. 1:56:29going to obscure the prediction value is
  2632. 1:56:31going to work very very well. So that's
  2633. 1:56:33the first thing that you need to keep in
  2634. 1:56:35mind. So be very careful because you
  2635. 1:56:38could be overfitting when using target
  2636. 1:56:40encoding. You could overfit. The second
  2637. 1:56:43thing to take into account is that the
  2638. 1:56:45algorithm for target encoding when you
  2639. 1:56:47go to an official implementation let's
  2640. 1:56:50say in scikitlearn they also they just
  2641. 1:56:53don't average numbers they also include
  2642. 1:56:56a smoothing as well. It's basically
  2643. 1:56:58adding some sort of like obscure value
  2644. 1:57:01to the formula to help with overfitting.
  2645. 1:57:06But anyway check it out uh because it's
  2646. 1:57:09very very effective.
  2647. 1:57:11All right, two more and we're done.
  2648. 1:57:13Normalization, standardization. I
  2649. 1:57:15mentioned this when we were talking
  2650. 1:57:16about label encoding. You want your
  2651. 1:57:20features to be homogeneous, to be around
  2652. 1:57:24the same range. You do not want to be
  2653. 1:57:28working with values here with the salary
  2654. 1:57:31of a person in the $100,000 and the age
  2655. 1:57:34of a person. That's 39. Just too much
  2656. 1:57:38difference. Okay. There are two usually
  2657. 1:57:40two algorithms that we use to sort of
  2658. 1:57:42like make these values homogeneous. The
  2659. 1:57:45first one is normalization. This is the
  2660. 1:57:46formula of normalization. An example of
  2661. 1:57:49that is when we are working with images,
  2662. 1:57:52imagine that this is an image. Every
  2663. 1:57:54pixel has a value between 0 and 255.
  2664. 1:57:57Zero meaning black, 255 meaning uh
  2665. 1:58:00white. Whenever we want to process an
  2666. 1:58:03image, black and white image like this,
  2667. 1:58:06we normalize the image first and we
  2668. 1:58:09don't want to work with some pixels that
  2669. 1:58:12are equal to one and some pixels that
  2670. 1:58:14are equals to 250 just too much
  2671. 1:58:17difference. So what we do is we
  2672. 1:58:18normalize using this formula and now
  2673. 1:58:21every single value will be between zero
  2674. 1:58:23and one very very small range. That's
  2675. 1:58:26what we want. our models are going to
  2676. 1:58:28work way better in this case here. Okay,
  2677. 1:58:32another example is using
  2678. 1:58:33standardization.
  2679. 1:58:35This is the formula here. Imagine that
  2680. 1:58:37we're working with salaries and ages and
  2681. 1:58:40this is sort of like the distribution
  2682. 1:58:42here of salary and ages. Uh when we put
  2683. 1:58:44them in a chart, we could using this
  2684. 1:58:47formula standardize these values because
  2685. 1:58:50salaries again is in the tenth of
  2686. 1:58:52thousands and ages is in the tens,
  2687. 1:58:55right? It's just
  2688. 1:58:57They're not going to be they're not
  2689. 1:58:58homogeneous. But if we standardize we
  2690. 1:59:02can get our salaries between minus.2
  2691. 1:59:05and.3 and our edges between minus.4 and
  2692. 1:59:09point.4 which is very very you know same
  2693. 1:59:12range pretty much. And our model is
  2694. 1:59:15going to work much better this way. And
  2695. 1:59:18the distribution obviously is going to
  2696. 1:59:19stay the same. Nothing changes. You're
  2697. 1:59:21just changing the numerical magnitude of
  2698. 1:59:23the values. Okay. That's another process
  2699. 1:59:26you have to go through when doing
  2700. 1:59:27feature engineering on your data set.
  2701. 1:59:29Okay. And finally, the final one is you
  2702. 1:59:32have to handle missing values. Okay. So
  2703. 1:59:35it's very normal. You get a data set,
  2704. 1:59:37you collected the data and a bunch of
  2705. 1:59:40that data is not there. It's not
  2706. 1:59:42present. You have to find ways to deal
  2707. 1:59:45with that because when you pass all of
  2708. 1:59:48that data to a model, the model doesn't
  2709. 1:59:49know what to do with a missing value.
  2710. 1:59:51Doesn't know how to replace that. you
  2711. 1:59:52have to do you have to make those
  2712. 1:59:54decisions. So multiple ways to handle
  2713. 1:59:57missing values. So one of them for
  2714. 1:59:58example is removing the columns that
  2715. 2:00:01contain missing values. If you have a
  2716. 2:00:03feature and that feature is very
  2717. 2:00:06incomplete like in this case you get one
  2718. 2:00:08example here male one example here
  2719. 2:00:10female but most of the data doesn't
  2720. 2:00:12contain anything. You can just get rid
  2721. 2:00:14of that column. Okay maybe that column
  2722. 2:00:17is not going to be that important. You
  2723. 2:00:18get rid of the column you move on.
  2724. 2:00:20Another way is just to remove the rows
  2725. 2:00:23that have the missing values. In this
  2726. 2:00:25particular case, there is only one row
  2727. 2:00:27here with a missing value. And in your
  2728. 2:00:29new data set, you can just get rid of
  2729. 2:00:31it. So just remove every column that
  2730. 2:00:35doesn't have that value. Another way is
  2731. 2:00:38replacing the missing values with uh you
  2732. 2:00:42know a good option. So basically you're
  2733. 2:00:45imputing a missing value. That's what
  2734. 2:00:47imputation mix uh means.
  2735. 2:00:50this particular example, we're using the
  2736. 2:00:53most frequent value to replace sorry or
  2737. 2:00:56to replace the missing value. So we're
  2738. 2:00:58missing the sex here, but the most
  2739. 2:01:01frequent value in this data set is male.
  2740. 2:01:04See, male, male, male, male. So we are
  2741. 2:01:07going to assume that any missing values
  2742. 2:01:10are going to be males. You do the
  2743. 2:01:12imputation [clears throat] and now you
  2744. 2:01:14pass your entire data set. Okay, these
  2745. 2:01:16are different techniques that you could
  2746. 2:01:18use to replace missing values. Something
  2747. 2:01:22important, never replace missing values
  2748. 2:01:26without asking why those values are
  2749. 2:01:29missing in the first place. Okay, so
  2750. 2:01:32anecdote here, 2016 United States
  2751. 2:01:36election, Hillary Clinton versus Donald
  2752. 2:01:39Trump, uh pollsters started asking
  2753. 2:01:42people, who are you voting for? A lot of
  2754. 2:01:45people started saying I don't want to
  2755. 2:01:47say I don't want to participate. Okay.
  2756. 2:01:51So pollsters assume that if you didn't
  2757. 2:01:53want to participate they did not want to
  2758. 2:01:55just include you. So why would I include
  2759. 2:01:57you if you're not giving me the answer
  2760. 2:01:59that I'm asking? What they failed to
  2761. 2:02:02realized or what many of them failed to
  2762. 2:02:04realize is there was a reason behind so
  2763. 2:02:08many people saying I do not want to tell
  2764. 2:02:11you. I do not want to participate. Okay,
  2765. 2:02:15Donald Trump ended winning that
  2766. 2:02:16election. Um, a lot of people did not
  2767. 2:02:20want to participate because they were
  2768. 2:02:22going to vote for Donald Trump, but
  2769. 2:02:23Trump was the most polarizing candidate.
  2770. 2:02:27So, they were not uh happy to tell that
  2771. 2:02:31in public. They were supporting Donald
  2772. 2:02:33Trump in public. So this is just one
  2773. 2:02:35example of what not trying to understand
  2774. 2:02:40why the missing value in the first place
  2775. 2:02:42is a mistake. If you dig deeper, why are
  2776. 2:02:46you not giving me this answer? Let's
  2777. 2:02:47think about that. Why are am I getting a
  2778. 2:02:51missing value in this column? You have
  2779. 2:02:53to think this deeper. You have to think
  2780. 2:02:55about that uh more carefully so you can
  2781. 2:02:59actually fix that issue going on. Uh
  2782. 2:03:01final slide.
  2783. 2:03:04if I can get there. So, this is uh this
  2784. 2:03:08is a little map with spot. We're running
  2785. 2:03:10a mission inside a warehouse. This is a
  2786. 2:03:12real example.
  2787. 2:03:14And that mission was for a spot to use a
  2788. 2:03:18camera, take a picture of analog gauges
  2789. 2:03:22that are, you know, next to equipment
  2790. 2:03:25and automatically read the value on
  2791. 2:03:28those analog gauges. So a pressure tank
  2792. 2:03:31spot will take a picture of the gauge
  2793. 2:03:33and we'll come up and say okay so it's
  2794. 2:03:35120 PSI that's what we see. So this is
  2795. 2:03:39sort of like the data that comes out of
  2796. 2:03:41the mission results. Okay so we get the
  2797. 2:03:43image we get the location where that
  2798. 2:03:45image is where spot took that picture
  2799. 2:03:48and we get the reading. But imagine that
  2800. 2:03:50you get sort of like these mission
  2801. 2:03:52results and you realize that the
  2802. 2:03:54warehouse here does not come with an
  2803. 2:03:57image and with a reading. If you had an
  2804. 2:04:00automatic process to just replace the
  2805. 2:04:03missing values here, okay, you wouldn't
  2806. 2:04:06miss the fact that well there's
  2807. 2:04:07something going on in the warehouse. And
  2808. 2:04:09this is sort of like an obvious example
  2809. 2:04:10when you see it like this. I promise you
  2810. 2:04:13was not that obvious when we were
  2811. 2:04:15dealing with this. So if you analyze the
  2812. 2:04:17data, well clearly something is
  2813. 2:04:19happening in the warehouse. So maybe the
  2814. 2:04:21warehouse 80% of the missing values are
  2815. 2:04:24coming from the warehouse or nine out of
  2816. 2:04:2610 times we go to the warehouse, we get
  2817. 2:04:28a missing value. Okay, so this is
  2818. 2:04:30something that's worth investigating.
  2819. 2:04:32Let's go to the warehouse and see what's
  2820. 2:04:34going on. Okay, so maybe somebody left a
  2821. 2:04:36box in front of the the gauge or maybe
  2822. 2:04:39the gauge is getting at the time
  2823. 2:04:42that we're running the missions because
  2824. 2:04:43some other thing is going on there and
  2825. 2:04:46spot cannot take a good picture of that
  2826. 2:04:48image. So whatever it is, you have to
  2827. 2:04:51analyze the data before making a
  2828. 2:04:53decision what to do with the missing
  2829. 2:04:55values. By the way, what we did in this
  2830. 2:04:57particular case, just in case it's
  2831. 2:04:59interesting, we had a model, machine
  2832. 2:05:01learning model that will do imputation
  2833. 2:05:03of missing values. That model, the goal
  2834. 2:05:06of that model was to analyze past
  2835. 2:05:08readings and to sort of like predict
  2836. 2:05:10what the new reading would be like and
  2837. 2:05:13it will replace missing values with that
  2838. 2:05:16value. So just in case that's
  2839. 2:05:18interesting. All right. So this is the
  2840. 2:05:20final slide that I have. This sort of
  2841. 2:05:23like covers again from the discovery
  2842. 2:05:25phase sometimes all the way to the first
  2843. 2:05:28iteration where I start dealing with the
  2844. 2:05:31data to build my first model. Sometimes
  2845. 2:05:35this is just discovery depending on the
  2846. 2:05:37project. So at the end of discovery I'm
  2847. 2:05:38going to have labels or at least a way
  2848. 2:05:41to gather those labels or to come up
  2849. 2:05:44with those labels. I'm going to have
  2850. 2:05:45data. I'm going to have a pretty good
  2851. 2:05:46idea of the feature engineering that I'm
  2852. 2:05:49going to have to do for that data set.
  2853. 2:05:52I'm going to have a good framing for my
  2854. 2:05:54problem and I probably going to have a
  2855. 2:05:56prototype or an idea to build that
  2856. 2:05:58prototype.
  2857. 2:06:00Questions?
  2858. 2:06:13anything goes.
  2859. 2:06:15>> I was thinking about how did you weight
  2860. 2:06:17the image like when you add the order
  2861. 2:06:21how how to just did you tell them did
  2862. 2:06:24you tell them about that the first image
  2863. 2:06:26was more weight than the other ones.
  2864. 2:06:30>> Oh, okay. So, just to keep it simple, it
  2865. 2:06:32was a little bit more complex than this,
  2866. 2:06:35but just to keep it simple, imagine that
  2867. 2:06:37you have three images. Okay? And what
  2868. 2:06:39I'm going to do is three images. Each
  2869. 2:06:41one of those images is going to have an
  2870. 2:06:44answer. Okay? So each image is going to
  2871. 2:06:46tell me I'm going to be a class A or
  2872. 2:06:50class B. Each image is, you know, you're
  2873. 2:06:52going to get a class from each image.
  2874. 2:06:54>> So what I do is I I'm going to assign a
  2875. 2:06:57weight to each of the images.
  2876. 2:06:59>> So the first image I'm going to say you
  2877. 2:07:02represent 50% of the weight and the
  2878. 2:07:05second image you're going to be 25% and
  2879. 2:07:07the third image is going to be 25%. So
  2880. 2:07:10by doing that by creating the weight a
  2881. 2:07:13different weight for each image now I
  2882. 2:07:16can compute the final prediction by
  2883. 2:07:18taking 50% of whatever answer the first
  2884. 2:07:21image gave me 25% of the second and 25%
  2885. 2:07:25of the okay so that's kind of
  2886. 2:07:28handcrafted the decision in the soft max
  2887. 2:07:32>> that is correct yes if you want to be
  2888. 2:07:34more specific I will do that with the
  2889. 2:07:36soft max and the weights and the weights
  2890. 2:07:39We will compute over time. We had a set
  2891. 2:07:42of weights and we will sort of like came
  2892. 2:07:45up with those weights automatically. So
  2893. 2:07:47basically train for those weights. But
  2894. 2:07:50those weights were based on the n the
  2895. 2:07:53image number. Okay. So if you were the
  2896. 2:07:56first image your weight was going to be
  2897. 2:07:58higher. Again we were training for is it
  2898. 2:08:01going to be 38 or it's going to be 36.
  2899. 2:08:04So we were sort of like optimizing those
  2900. 2:08:06but overall the weight was determined by
  2901. 2:08:09the number in the order. Okay.
  2902. 2:08:14>> Got it. So you first so first you you
  2903. 2:08:16start with a fixed weight and then you
  2904. 2:08:19then you optimize this weight to
  2905. 2:08:21dynamically be selected.
  2906. 2:08:24>> What what we did was just we started
  2907. 2:08:26with fixed weights and then we changed
  2908. 2:08:29the weights. We basically learned what
  2909. 2:08:31good weights were based on the data that
  2910. 2:08:32we had. So we had a training set and we
  2911. 2:08:35were it's like just training a model to
  2912. 2:08:37determine what the optimal weights are.
  2913. 2:08:38>> Okay.
  2914. 2:08:39>> And we were rerunning that over time
  2915. 2:08:41like I don't know maybe every month. Hey
  2916. 2:08:43let's just optimize for the weights and
  2917. 2:08:46let's come up with the weights the
  2918. 2:08:47better weight
  2919. 2:08:48>> to measure. Yeah. to measure how
  2920. 2:08:50important the first one the first image
  2921. 2:08:52was
  2922. 2:08:52>> because you had the you had the
  2923. 2:08:54pre-intuition that the first one is
  2924. 2:08:56better but you couldn't tell for sure
  2925. 2:08:58how much
  2926. 2:08:59>> I don't know how better it was or how
  2927. 2:09:01much we should be trusting it okay so I
  2928. 2:09:04did not know that yeah
  2929. 2:09:06>> sure yeah thank you
  2930. 2:09:10>> uh Iban Ibano
  2931. 2:09:13drums
  2932. 2:09:15h how do you call it I mean how is the
  2933. 2:09:19TXO it means cho.
  2934. 2:09:22>> Oh, sure.
  2935. 2:09:25>> Okay, cool.
  2936. 2:09:27>> Uh, yeah. So, you mentioned that this
  2937. 2:09:29will be your first iteration the whole
  2938. 2:09:31process. So, I guess I I will be
  2939. 2:09:33interesting to know how do you do how do
  2940. 2:09:36you document all this process? Do you
  2941. 2:09:38use a boards? Do you use a wiki or or
  2942. 2:09:41what's what's your process behind all
  2943. 2:09:43this? Oh, we usually so I wish I had a
  2944. 2:09:47saying on that. All of this usually
  2945. 2:09:50happens on the client's tools. So it's a
  2946. 2:09:52if I have a saying I usually document
  2947. 2:09:54things in GitHub because it's very
  2948. 2:09:56simple and everyone has access to it and
  2949. 2:09:58I just create issues and work you know
  2950. 2:10:00you in GitHub you can create these uh
  2951. 2:10:03boards where you can have multiple
  2952. 2:10:05columns and you can assign tasks to each
  2953. 2:10:08column and all of that or you can just
  2954. 2:10:10create issues there but anything
  2955. 2:10:12actually works. uh usually what happens
  2956. 2:10:15is that the clients dictate where I
  2957. 2:10:17should be providing or or ending
  2958. 2:10:19information they have Jira clashen or
  2959. 2:10:22whatever tools they use uh bunch of
  2960. 2:10:24clients use base camp it doesn't really
  2961. 2:10:26matter the important thing here is that
  2962. 2:10:28you capture the right information and
  2963. 2:10:30the process and what not and who's doing
  2964. 2:10:32what and what's left to do that's yeah
  2965. 2:10:37>> thanks
  2966. 2:10:39what
  2967. 2:10:44Santiago, very cool, very cool uh
  2968. 2:10:47practitioner techniques, you know, how
  2969. 2:10:50to normalize the data. For example, the
  2970. 2:10:52notes that you made about like how the
  2971. 2:10:54larger distance between values impacts
  2972. 2:10:58model performance. Would you have papers
  2973. 2:11:00somewhere or is it just basically common
  2974. 2:11:02sense at this stage like you know for
  2975. 2:11:04someone who does it for a living? I mean
  2976. 2:11:06why why a larger value will will
  2977. 2:11:09>> no would you have is this like obvious
  2978. 2:11:12enough that there is no point in reading
  2979. 2:11:14papers anymore about this or would you
  2980. 2:11:16have papers somewhere noted that we
  2981. 2:11:18could kind of take a look at
  2982. 2:11:20>> I can tell you exactly I I mean there
  2983. 2:11:22there might be I don't think there is a
  2984. 2:11:24paper out there that explains why a
  2985. 2:11:26higher value will impact the performance
  2986. 2:11:28but I can tell you why it's going to
  2987. 2:11:29impact the performance. So if you have
  2988. 2:11:32uh
  2989. 2:11:34I'm writing stuck here.
  2990. 2:11:36>> What I meant is more also about like
  2991. 2:11:39that you gave like several hints, right?
  2992. 2:11:42And they were interesting.
  2993. 2:11:45>> So
  2994. 2:11:45>> So look at So this is this here is the
  2995. 2:11:49formula of a line, right? This is just
  2996. 2:11:51like the you know you get the y value.
  2997. 2:11:54It's it's the the how do you call this
  2998. 2:11:56in English? I forgot. slope times the
  2999. 2:11:58the x value plus a bias or or you know
  3000. 2:12:02this is al also the formula that we have
  3001. 2:12:04in a neural network to compute the value
  3002. 2:12:06of a network of of a neuron. So the
  3003. 2:12:08value of a neuron will be the set of
  3004. 2:12:11weights that are predefined times the
  3005. 2:12:14input of that neurons plus a bias. Now I
  3006. 2:12:18want you to imagine that the input of
  3007. 2:12:20you have two columns in your data set
  3008. 2:12:23the salary and the age. Okay. So if I
  3009. 2:12:28have a neuron, let me try to make this
  3010. 2:12:34a piece of paper here where this will
  3011. 2:12:37make sense.
  3012. 2:12:47So we have this neural network. Okay.
  3013. 2:12:49And there are two inputs here. And I'm
  3014. 2:12:51going to assign the salary to one input.
  3015. 2:12:56and that's going to be 10,000.
  3016. 2:12:58And I'm going to assign the age
  3017. 2:13:01to another input.
  3018. 2:13:03You get something like this. So the
  3019. 2:13:05inputs to my network are one. The first
  3020. 2:13:09the first input is going to be the
  3021. 2:13:10salary which is going to be a very large
  3022. 2:13:12number and the second input is going to
  3023. 2:13:15be the age which is going to be a
  3024. 2:13:16smaller number. And now I want to
  3025. 2:13:18compute the value of a neuron. again is
  3026. 2:13:23going to be the set of weights that are
  3027. 2:13:26for my network times the input. So
  3028. 2:13:29assuming the set of weights are at the
  3029. 2:13:31same value. So they're homogeneous. It's
  3030. 2:13:33going to be 0.1 and 0 2 and point n. You
  3031. 2:13:36can see that in that multiplication
  3032. 2:13:38the x value is it's you know if we get
  3033. 2:13:42the value of a non and by the way there
  3034. 2:13:44is also uh an activation function here.
  3035. 2:13:47I'm going to forget that for a second.
  3036. 2:13:49But if I have this
  3037. 2:13:53If I have the set of weights, sorry, I
  3038. 2:13:55cannot see where I'm pointing. If I have
  3039. 2:13:57the set of weights, the value of the
  3040. 2:13:59neuron is going to be the set of weights
  3041. 2:14:00times the input. When that input grows,
  3042. 2:14:04so if I have 10,000,
  3043. 2:14:07that value, the y value is going to be
  3044. 2:14:09way higher than when the input is very
  3045. 2:14:13small, which is 32. So what's going to
  3046. 2:14:15happen is when you have this in a data
  3047. 2:14:17set all of the neurons that use that
  3048. 2:14:21input here that are exposed that input
  3049. 2:14:24the value will grow in comparison to the
  3050. 2:14:27neurons that are exposed to the other
  3051. 2:14:30features that are smaller. So the model
  3052. 2:14:33when I when the value grows in inside
  3053. 2:14:36the neural network and if if you follow
  3054. 2:14:39the process of a neural network any
  3055. 2:14:40values that are really small the the
  3056. 2:14:43network is not going to do anything with
  3057. 2:14:44them and it's going to start activating
  3058. 2:14:47that's what we call a neuron gets more
  3059. 2:14:49activation when the value is larger.
  3060. 2:14:51That's what's happening. Then the the
  3061. 2:14:52network is paying more attention to
  3062. 2:14:55what's happening to the salary. It's not
  3063. 2:14:57paying enough attention to what's
  3064. 2:14:59happening with the age. By making these
  3065. 2:15:02two values
  3066. 2:15:04homogeneous within the same range, you
  3067. 2:15:08avoid that problem. Now the network has
  3068. 2:15:10to pay attention to all of the features.
  3069. 2:15:12So that's that's what's happening. Uh by
  3070. 2:15:14the way, that would not be the case if
  3071. 2:15:16you're working, let's say, with a
  3072. 2:15:18decision tree. like a decision tree will
  3073. 2:15:20not have that problem because it's not
  3074. 2:15:23using the same mechanism as the neural
  3075. 2:15:25network. It's not multiplying by those
  3076. 2:15:26values. So it wouldn't care about the
  3077. 2:15:29homogeneous part. But the but making the
  3078. 2:15:32values homogeneous does not hurt. So you
  3079. 2:15:34always do it and now you have the
  3080. 2:15:36flexibility of using whatever model and
  3081. 2:15:38you don't care about whether the model
  3082. 2:15:41uh is sensible to that or not. You can
  3083. 2:15:43just use the whatever model you have and
  3084. 2:15:45it's going to work the same.
  3085. 2:15:49Super cool. Thanks.
  3086. 2:15:54What else?
  3087. 2:15:57How many of you are going to How many of
  3088. 2:15:59you is AI going to replace?
  3089. 2:16:03What is plan B?
  3090. 2:16:06They going to the you know build and you
  3091. 2:16:10know becoming I don't know a carpenter
  3092. 2:16:11or something. What is plan B for us?
  3093. 2:16:14I was smiling when you mentioned Pog
  3094. 2:16:16Graham the the the essay because I'm
  3095. 2:16:19pretty sure he's already working on a
  3096. 2:16:21you know updated version because like
  3097. 2:16:24you know what doesn't scale is
  3098. 2:16:27redefining in front of our very eyes
  3099. 2:16:29like the term is no longer what it used
  3100. 2:16:32to be 10 years ago or 20 years ago.
  3101. 2:16:35>> So yeah.
  3102. 2:16:39>> Yeah. and and hearing you, you know,
  3103. 2:16:41saying that like you you're thinking of
  3104. 2:16:44like doing something else. I almost b
  3105. 2:16:46laughing. Yep.
  3106. 2:16:51>> Yeah,
  3107. 2:16:54man. I don't know. I don't know what
  3108. 2:16:55plan B is. Uh I don't have plan B. So, I
  3109. 2:16:59hope we never come to knitting a plan B.
  3110. 2:17:04Somebody says here, "Well, I'm going to
  3111. 2:17:06be working on HVAC
  3112. 2:17:08systems.
  3113. 2:17:10I mean that's that's a that's a cool way
  3114. 2:17:12of making a living. I suppose my
  3115. 2:17:14personal hope is that it will really
  3116. 2:17:17create like all new opportunities. It's
  3117. 2:17:20just that the intering period is going
  3118. 2:17:22to be super bumpy but like I don't know
  3119. 2:17:2520 years whatever the time frames are
  3120. 2:17:27very hard because it has accelerated so
  3121. 2:17:29much. Uh but like in some time we'll be
  3122. 2:17:34much better off like imagine what's
  3123. 2:17:36going to happen if we suddenly have free
  3124. 2:17:39power or like we actually fly to the
  3125. 2:17:42moon on scheduled basis and stuff like
  3126. 2:17:44this where crisper is going to take off
  3127. 2:17:47for real for ordinary humans like this
  3128. 2:17:50is like we can't really even think about
  3129. 2:17:52this right now.
  3130. 2:17:54>> So fingers crossed right?
  3131. 2:17:56>> Yeah I mean I I I joke with this but uh
  3132. 2:18:00I I don't think it's I don't think it's
  3133. 2:18:03it's not going to be a good deal.
  3134. 2:18:04Obviously, that doesn't mean that AI is
  3135. 2:18:06not going to disrupt. What I mean is
  3136. 2:18:09that for people for professionals who've
  3137. 2:18:12been doing this or or people who are
  3138. 2:18:16investing in in their education and
  3139. 2:18:18learning, AI is not going to replace
  3140. 2:18:21them. If if you go outside Twitter, if
  3141. 2:18:24you go outside LinkedIn, if you go
  3142. 2:18:26outside the bubble, you will realize how
  3143. 2:18:30how far back the entire world is. Like
  3144. 2:18:33there are people right now. I just had
  3145. 2:18:36to apply for my daughter's visa. She's
  3146. 2:18:38going to the UK, studying there.
  3147. 2:18:42The the entire website was made in I
  3148. 2:18:44don't know, maybe 1960 before the
  3149. 2:18:46internet. that I mean you look at that
  3150. 2:18:48website and you're like nobody's going
  3151. 2:18:50to replace us ever. These people don't
  3152. 2:18:53even know what building a website looks
  3153. 2:18:54like. Let alone everything is going to
  3154. 2:18:57be automated by no not really. It's not
  3155. 2:19:00I
  3156. 2:19:01plus we are getting to the point where
  3157. 2:19:04yes these models are great and these
  3158. 2:19:06models are doing a lot of it but
  3159. 2:19:08everyone realizes that no you cannot let
  3160. 2:19:12these models just
  3161. 2:19:14they're not replacing us so far is that
  3162. 2:19:17yes coding they're doing but coding is
  3163. 2:19:20not building software. Coding is just a
  3164. 2:19:22small percentage of what building
  3165. 2:19:24software looks like. Okay,
  3166. 2:19:27I know that before it was an important
  3167. 2:19:31uh task that most people could not do.
  3168. 2:19:35But people who couldn't write
  3169. 2:19:37[clears throat] software, who couldn't
  3170. 2:19:38write code before, they're not
  3171. 2:19:40developers now. They're not going to
  3172. 2:19:41become developers. My wife is not going
  3173. 2:19:43to become a developer. She doesn't know
  3174. 2:19:45anything about systems, engineering,
  3175. 2:19:47software. She's not gonna be prompting
  3176. 2:19:50models saying build me an app. That
  3177. 2:19:53that's not the way works. I've heard
  3178. 2:19:56people online saying when everyone can
  3179. 2:19:59build an app for their phones. Do you
  3180. 2:20:02really believe that
  3181. 2:20:05your friends that have never touch a
  3182. 2:20:07computer before, they're going to be
  3183. 2:20:09sitting down building apps for their
  3184. 2:20:12phone? Come on. Come on. We pay for
  3185. 2:20:15people to cook for us. people get a
  3186. 2:20:18little bit of money and they buy a chef.
  3187. 2:20:20They don't even want to cook food for
  3188. 2:20:22them. Now imagine they're going to be
  3189. 2:20:24building apps for them. That's it's not
  3190. 2:20:27everyone knows how to cook. Everyone
  3191. 2:20:29knows how to cook or at least everyone
  3192. 2:20:31has the means to learn how to cook and
  3193. 2:20:34nobody wants to do it and people still
  3194. 2:20:36go to restaurants. So I do not sorry I'm
  3195. 2:20:38I'm passionate about this. Uh, I do not
  3196. 2:20:41think that the end of the world is near
  3197. 2:20:45or that we're going to need a plan B.
  3198. 2:20:47What I do think though is that you need
  3199. 2:20:49to keep improving. And I don't think
  3200. 2:20:51this is different than before. You need
  3201. 2:20:53to keep learning. You need to keep
  3202. 2:20:55getting better at the tools that the
  3203. 2:20:57current state of the art that is
  3204. 2:20:59education is the only way you are going
  3205. 2:21:02to be better off tomorrow. That's the
  3206. 2:21:04only thing that I know. Yeah. So anyway,
  3207. 2:21:09>> hey the
  3208. 2:21:11>> Oh, sorry.
  3209. 2:21:12>> Go on, please.
  3210. 2:21:14>> Yeah, I want to say every IT meme ends
  3211. 2:21:18up with agriculture. So maybe that's the
  3212. 2:21:20plan B, but even their robots can
  3213. 2:21:23replace us. But my question was about
  3214. 2:21:25the if if on your system uh I so I saw
  3215. 2:21:29the
  3216. 2:21:31uh on the slides the part of the
  3217. 2:21:33normalization and uh I was wondering if
  3218. 2:21:37do you how how do you handle al also
  3219. 2:21:39with ambiguity in in the in the
  3220. 2:21:41contextualization because that's why uh
  3221. 2:21:43transformers came up came up right
  3222. 2:21:45because of apple can mean apple in
  3223. 2:21:47agriculture but also can mean apple in a
  3224. 2:21:49technology for example right and how do
  3225. 2:21:52you handle this in this
  3226. 2:21:54machine learning pipelines
  3227. 2:21:56>> that it's it's very specific to the
  3228. 2:21:58problem that you're working on. So uh
  3229. 2:22:02all of the models that I've been
  3230. 2:22:03involved with, I've never built an LLM
  3231. 2:22:05before, built from scratch, another
  3232. 2:22:06before. So I've never had to deal with
  3233. 2:22:08that problem specifically of two words
  3234. 2:22:11meaning Apple the company or Apple the
  3235. 2:22:13fruit or bank from river bank or bank
  3236. 2:22:17from financial institution. I haven't
  3237. 2:22:19had to build solutions for that. But
  3238. 2:22:22there are of course depending on the
  3239. 2:22:25problem that you are working on there
  3240. 2:22:27are pieces of information that might
  3241. 2:22:29have different meanings depending on the
  3242. 2:22:31context. The solution to that is to
  3243. 2:22:33include the context. So remember that I
  3244. 2:22:36had a slide that said you have to add as
  3245. 2:22:39much metadata that contextualizes
  3246. 2:22:41one piece of information as possible.
  3247. 2:22:44And whenever you find yourself in a
  3248. 2:22:46problem where that is is an issue, where
  3249. 2:22:49the the the meaning of something is an
  3250. 2:22:51issue, you have to go to the to the meta
  3251. 2:22:53data and include that metadata as part
  3252. 2:22:55of your data, your official data. So
  3253. 2:22:57maybe the image is not enough for you to
  3254. 2:23:00solve the problem. And this has happened
  3255. 2:23:01all the time where you take two
  3256. 2:23:03pictures, but it's not enough for the
  3257. 2:23:06image to give an answer because it
  3258. 2:23:08really depends on whether you took the
  3259. 2:23:10picture during daytime or nighttime. So
  3260. 2:23:13now what you do in order to provide that
  3261. 2:23:15context is you add another feature that
  3262. 2:23:17says time of the picture. Now you have
  3263. 2:23:20the image and the time you took that
  3264. 2:23:22picture because that's important for the
  3265. 2:23:25model to do something different for that
  3266. 2:23:27picture. So anyway, point being you add
  3267. 2:23:30the context. So that's what you have to
  3268. 2:23:32do. But for you to add the context, you
  3269. 2:23:34first have to have that context. So when
  3270. 2:23:38you're collecting the data, make sure
  3271. 2:23:40you are including as much metadata as
  3272. 2:23:42possible so you can actually solve that
  3273. 2:23:44problem later on. Hopefully that makes
  3274. 2:23:46sense.
  3275. 2:23:47>> Yes, sure. And and does it affect uh
  3276. 2:23:50tagging as well?
  3277. 2:23:53>> Uh it will. So you're usually going to
  3278. 2:23:56realize that you need that context when
  3279. 2:23:58you are doing labeling. So way before
  3280. 2:24:00your model is not going to tell you that
  3281. 2:24:01the model is confused. Usually when
  3282. 2:24:03you're doing labeling, the people who
  3283. 2:24:05are labeling are going to tell you, I
  3284. 2:24:07don't know what to tell you here. Like
  3285. 2:24:09what is the answer for this?
  3286. 2:24:11>> Makes [snorts] sense.
  3287. 2:24:12>> Yeah. Yeah.
  3288. 2:24:13>> Thanks.
  3289. 2:24:20>> What else?
  3290. 2:24:26I see here from SA. I'm starting my PhD
  3291. 2:24:29this year, so it's encouraging to hear
  3292. 2:24:31this. I completely agree that education
  3293. 2:24:33needs to improve so people can better
  3294. 2:24:35understand and develop this field. Yep.
  3295. 2:24:39Uh Mansour, what's up?
  3296. 2:24:41Uh yes I have a question around
  3297. 2:24:44synthetic data and whether one one thing
  3298. 2:24:47is are we going to talk about it and
  3299. 2:24:50second is
  3300. 2:24:52how how much synthetic data can we
  3301. 2:24:54actually uh how useful it is because
  3302. 2:24:57just to give you context here in Africa
  3303. 2:24:59whenever you do things like machine
  3304. 2:25:01learning and uh you know AI number one
  3305. 2:25:04issues you're having actually is data
  3306. 2:25:06right a lot of the things we we try to
  3307. 2:25:09build we don't have enough data not
  3308. 2:25:11quality data.
  3309. 2:25:12>> So for the things I'm trying to build, I
  3310. 2:25:15I'm really looking into maybe synthetic
  3311. 2:25:18data as a way to overcome that
  3312. 2:25:20challenge. But now can you go and abuse
  3313. 2:25:23of synthetic data and actually have good
  3314. 2:25:27results based off of that? Maybe from
  3315. 2:25:29your experience or the industry standard
  3316. 2:25:32is very like a cap or that says for
  3317. 2:25:35example only 30% of your training data
  3318. 2:25:38can be sent data. Beyond that you get
  3319. 2:25:40garbage.
  3320. 2:25:41>> Yeah, there is no number. Actually the
  3321. 2:25:43the question you need to answer is how
  3322. 2:25:45good is that synthetic data? How
  3323. 2:25:48indistinguishable it is from real data?
  3324. 2:25:51If you have a process that can generate
  3325. 2:25:54synthetic data that's as good as real
  3326. 2:25:57data, it's you you can add unlimited
  3327. 2:26:01synthetic data. The problem is that not
  3328. 2:26:03everyone has that process. And if the
  3329. 2:26:06synthetic data that you're generating
  3330. 2:26:08differs from what the real data looks
  3331. 2:26:10like, you're going to be limited in how
  3332. 2:26:12much synthetic data you can use before
  3333. 2:26:15your model learns how the synthetic data
  3334. 2:26:17looks like and forgets about what the
  3335. 2:26:19real data looks like. So again, the
  3336. 2:26:21answer is going to be very different
  3337. 2:26:23depending on what you're doing. Let me
  3338. 2:26:24give you one example. Imagine that you
  3339. 2:26:27have sensors
  3340. 2:26:29and that capture the temperature. Okay?
  3341. 2:26:32So the sensor is going to go a real
  3342. 2:26:34sensor capturing temperature. It's going
  3343. 2:26:37to be working very very differently than
  3344. 2:26:40a process that generates temperatures
  3345. 2:26:42randomly. Okay. The sensor might break,
  3346. 2:26:44the sensor might capture you know the
  3347. 2:26:47weather correctly, the random values or
  3348. 2:26:49not. So if your process to generate
  3349. 2:26:52synthetic temperatures is just random,
  3350. 2:26:55that's not going to be good enough like
  3351. 2:26:57uh it's not going to be as good as the
  3352. 2:27:00real sensor. But you might have a
  3353. 2:27:02process that generates good data that is
  3354. 2:27:06not necessarily real, but maybe you have
  3355. 2:27:09sensors deployed in a similar location,
  3356. 2:27:11similar weather, maybe even in the same
  3357. 2:27:14location, and you're using that to
  3358. 2:27:16generate more data. Maybe that's good
  3359. 2:27:18enough. So it really depends for you.
  3360. 2:27:20Yeah. But you can use it is is fine.
  3361. 2:27:22Yeah.
  3362. 2:27:28What else?
  3363. 2:27:31As a reminder on Wednesday, remember we
  3364. 2:27:34have office hours. You don't have to
  3365. 2:27:37come, but if you if you do, we're just
  3366. 2:27:39gonna no agenda. We're just going to be
  3367. 2:27:41talking about whatever. If you have
  3368. 2:27:42questions, you can show up. We can talk
  3369. 2:27:45about business. I don't know, social
  3370. 2:27:47media, the moon, whatever you guys
  3371. 2:27:50decide that we should be talking on. So,
  3372. 2:27:53plan B, that type of stuff. I Hey, I
  3373. 2:27:56like to take photos, so that might be I
  3374. 2:27:58don't know, maybe I become a
  3375. 2:27:59photographer.
  3376. 2:28:01I don't think a lot of photographer make
  3377. 2:28:03a lot of money, but anyway, maybe that's
  3378. 2:28:05plan B for me.
  3379. 2:28:10Sebastian, what's up?
  3380. 2:28:12>> Listen, Dale, what's up? Uh well
  3381. 2:28:16I spend more I spend more time on
  3382. 2:28:18Twitter than I would like to admit to be
  3383. 2:28:20honest. Uh but I recently saw that you
  3384. 2:28:24took a stand regarding not reading AI
  3385. 2:28:26generated code anymore and it's
  3386. 2:28:31well at least I kind of had the feeling
  3387. 2:28:33that it uh started a heated discussion
  3388. 2:28:37because I saw that GMO from Bol
  3389. 2:28:41regarding that matter and I would just
  3390. 2:28:44like to know like if you could elaborate
  3391. 2:28:46more on that. Yeah. What are you
  3392. 2:28:48thinking?
  3393. 2:28:49>> Yeah. So he and I have exactly the same
  3394. 2:28:52point of view. And the problem is that
  3395. 2:28:55we framed it in very different ways. But
  3396. 2:28:57if you read his post, I don't know if
  3397. 2:28:58you have it in front of you. If you read
  3398. 2:29:01his post,
  3399. 2:29:03>> yes, I'm going to find it. It should be
  3400. 2:29:04very easy to find because
  3401. 2:29:07>> it turned kind of viral.
  3402. 2:29:10>> Like do you if you have it in front of
  3403. 2:29:12you, do you mind pasting it here so I
  3404. 2:29:14can just go and look at it?
  3405. 2:29:16>> Yeah. Give me a second. I'm just
  3406. 2:29:18>> let me see if I can find it here.
  3407. 2:29:27>> Okay. Yeah, I just found it. I can share
  3408. 2:29:29the
  3409. 2:29:31>> if you share it here.
  3410. 2:29:33>> Yeah.
  3411. 2:29:39>> Okay, there we go. Let me open it here.
  3412. 2:29:41All right. So he says the the key here
  3413. 2:29:44the key here is in the first sentence.
  3414. 2:29:47That's it. He says if you are not
  3415. 2:29:49reading the code,
  3416. 2:29:52whether explicitly
  3417. 2:29:55or through agentic inquire that's it.
  3418. 2:29:59>> Okay. Basically, he's saying if you're
  3419. 2:30:01asking an agent, build this and that's
  3420. 2:30:05it and you're just deploying whatever
  3421. 2:30:07the agent built then and then he goes
  3422. 2:30:10into the rest of the post. Okay?
  3423. 2:30:13>> He's telling you that you should be
  3424. 2:30:15reviewing that code, not necessarily
  3425. 2:30:18explicitly, meaning sitting down and
  3426. 2:30:21reading the lines and thinking about the
  3427. 2:30:23lines. And that's it. He and I have
  3428. 2:30:26exactly the same opinion. I said, "I'm
  3429. 2:30:30not reading the code manually. I'm not
  3430. 2:30:34sitting down going through 10,000
  3431. 2:30:38autogenerated lines of code trying to
  3432. 2:30:41understand what the agent did. And if
  3433. 2:30:44you are, then a bunch of things are
  3434. 2:30:47true. Either one, you're not generating
  3435. 2:30:50that much code. Two, you're not moving
  3436. 2:30:53fast enough. There is no way I can give
  3437. 2:30:56you 10,000 lines of code for and you are
  3438. 2:30:59going to read through all of them and
  3439. 2:31:01verify all of them and think about the
  3440. 2:31:02mental model that all of those lines are
  3441. 2:31:04doing fast enough. There's no way it's
  3442. 2:31:07going to take you a ton of time to do
  3443. 2:31:09that. Right? So he and I have the same
  3444. 2:31:12opinion. The thing is that Twitter is
  3445. 2:31:15the place where nuance is lost.
  3446. 2:31:19>> Lost. So, if you go to the post to what
  3447. 2:31:22I I posted something today
  3448. 2:31:25that says people hate that many of us
  3449. 2:31:28I'm going to paste a link here.
  3450. 2:31:33Uh let me see where where do I do that?
  3451. 2:31:36Here we go. So, this is what I posted
  3452. 2:31:37today. Okay.
  3453. 2:31:39And I say people hate that many of us
  3454. 2:31:42aren't reading AI code anymore. That's
  3455. 2:31:44the post. That's how it says. But if you
  3456. 2:31:46keep reading here, you're gonna realize
  3457. 2:31:49that I'm explaining
  3458. 2:31:52that
  3459. 2:31:54I'm just referring to reading lines of
  3460. 2:31:56code, but I'm verifying the code. I have
  3461. 2:32:01unit tests, acceptant tests, verifi code
  3462. 2:32:05reviews, automated code reviews. I have
  3463. 2:32:07a bunch of layers that are helping me
  3464. 2:32:11understand whether the code is working
  3465. 2:32:13or not. I'm just not reading the code
  3466. 2:32:15anymore. I was reading the code. I'm not
  3467. 2:32:18anymore. I can't I It just It's not
  3468. 2:32:20worth it to me or to anybody. Okay, this
  3469. 2:32:24is just no way that's worth it. But
  3470. 2:32:26again, nuance is lost. And you say, "I'm
  3471. 2:32:29not reading the code anymore." AND
  3472. 2:32:30EVERYONE IS LIKE, "HOLY YOU
  3473. 2:32:32somebody uh found my website. I have a
  3474. 2:32:36website linked on Twitter." And that
  3475. 2:32:38person opened my website and that person
  3476. 2:32:40told me, "Well, of course you're not
  3477. 2:32:42reading your code. your website and
  3478. 2:32:44Who cares about your website?
  3479. 2:32:47That's the it's just a landing page. It
  3480. 2:32:49doesn't even work correctly. And I'm
  3481. 2:32:51like, dude, tell me why so I can fix it.
  3482. 2:32:53Yeah. Anyway, so that's that's just
  3483. 2:32:56Twitter. I'm used to it. But yeah, uh so
  3484. 2:32:59that's my stance. I should you be
  3485. 2:33:02reading your code? I'm going to say,
  3486. 2:33:03well, it depends. Are you producing
  3487. 2:33:06enough code? If all that you're doing is
  3488. 2:33:09just maybe one function at a time, uh
  3489. 2:33:11you're doing most that's fine and you
  3490. 2:33:13you can read the code, that's fine. It's
  3491. 2:33:16a matter of the signal versus noise
  3492. 2:33:18ratio. Okay. So, as these models have
  3493. 2:33:21gotten better and better and better,
  3494. 2:33:23what we realize is it's not that these
  3495. 2:33:25models do not make mistakes, is that it
  3496. 2:33:27takes a lot of time to find those
  3497. 2:33:31mistakes. Okay? because it's 10,000
  3498. 2:33:33lines of code and maybe there is a bug
  3499. 2:33:35there or two a couple of bugs there. So
  3500. 2:33:37the question we need to answer is is
  3501. 2:33:39there a more efficient way to identify
  3502. 2:33:43those mistakes
  3503. 2:33:44than just asking somebody sit down and
  3504. 2:33:47read those 10,000 lines of code. when
  3505. 2:33:50you are forcing your team to read the
  3506. 2:33:53the lines of code, what actually needs
  3507. 2:33:56to happen is that now you need to
  3508. 2:33:57produce less code because there nobody's
  3509. 2:34:00going to sit down and read 10 10,000
  3510. 2:34:02lines of code. So you are
  3511. 2:34:05uh putting a cap on how much progress
  3512. 2:34:09you can make just so your people can
  3513. 2:34:12find the bugs really really quick. I
  3514. 2:34:14don't think that's the most efficient
  3515. 2:34:16way of doing it. Obviously, this will
  3516. 2:34:18vary depending on the software that
  3517. 2:34:19you're doing. If you're creating a
  3518. 2:34:21medical system that people's lives are
  3519. 2:34:24going to be at stake, well, maybe you
  3520. 2:34:26should not do what I'm doing right now.
  3521. 2:34:28But for any regular stuff, maybe what
  3522. 2:34:30you want to do is maximize how much you
  3523. 2:34:33can produce, but identify ways or design
  3524. 2:34:36ways to verify that that is good. And
  3525. 2:34:38that's it. That's good enough. So,
  3526. 2:34:40anyway, that's that's my take on this.
  3527. 2:34:42Yeah.
  3528. 2:34:46>> Thank you.
  3529. 2:34:47Okay. So, uh I see something here. Let
  3530. 2:34:50me see. I So, Uncle B modding said
  3531. 2:34:54something. I'm not reading the tweet,
  3532. 2:34:56but I'm I'm looking at your the LDR. It
  3533. 2:34:58says, "The way I understand it, no need
  3534. 2:35:00to read anymore. Better to focus on
  3535. 2:35:02setting and enforcing boundaries and
  3536. 2:35:04ironing out harnesses." That's exactly
  3537. 2:35:06right. So, again, reading the code, it's
  3538. 2:35:10inefficient.
  3539. 2:35:12And if you're not there, it's because
  3540. 2:35:15you're not producing enough code. That's
  3541. 2:35:16it. It's just there's no other way. So,
  3542. 2:35:20how can we stop reading the code and
  3543. 2:35:22instead use that time to find more
  3544. 2:35:24efficient ways to verify the product?
  3545. 2:35:26That's it. That's the whole idea. This
  3546. 2:35:29is the same. By the way, we've been here
  3547. 2:35:31before. This is just it's controversial
  3548. 2:35:34because it's just because we like to be
  3549. 2:35:36enraged. But when we went from unit
  3550. 2:35:39testing to
  3551. 2:35:42uh integration testing, it's sort of
  3552. 2:35:44like the same jump in abstraction where
  3553. 2:35:46in unit testing you're testing every
  3554. 2:35:49line of code that you're typing. You're
  3555. 2:35:51typing code, you're writing tests that
  3556. 2:35:53test individual units of your code. When
  3557. 2:35:57you go to integration testing, now
  3558. 2:35:59you're taking you're you're moving up
  3559. 2:36:01one level where you don't care about the
  3560. 2:36:04code itself. you care about the
  3561. 2:36:05integration of different components. Uh
  3562. 2:36:07maybe in acceptant testing, you're just
  3563. 2:36:10looking at your overall system, how the
  3564. 2:36:11overall system is working. Um you don't
  3565. 2:36:14care about the code, you care about an
  3566. 2:36:16higher level. This is the same thing.
  3567. 2:36:18We're moving up the abstraction layer
  3568. 2:36:20here in order to verify that the overall
  3569. 2:36:24system is working. I do not understand
  3570. 2:36:28people telling me, well, you have to
  3571. 2:36:30understand every line of code because if
  3572. 2:36:32you do not, you're stupid. Well, maybe
  3573. 2:36:34that's for you, not for me. Not useful
  3574. 2:36:36for me. So, anyway, yeah, that's where
  3575. 2:36:38we are.
  3576. 2:36:45Uh, Santi, I have a quick question with
  3577. 2:36:47regards to this like how do you bound
  3578. 2:36:51the
  3579. 2:36:53request you ask to the agents like for
  3580. 2:36:55example in case of like chachd 5.6 six
  3581. 2:36:58if I gave it like hey review this Jira
  3582. 2:37:01story I did and my code base is large
  3583. 2:37:03enough and it's old enough what it does
  3584. 2:37:06it's like it gives me goes to like very
  3585. 2:37:10sometimes like very minuscule of
  3586. 2:37:12possible error scenario that could
  3587. 2:37:14happen and it told us like hey this is a
  3588. 2:37:16high priority thing you need to fix it
  3589. 2:37:18out and if I tied it up with my like
  3590. 2:37:21developer agent I tied it up with my
  3591. 2:37:23reviewer agent with two different models
  3592. 2:37:25there was a scenario like last week I
  3593. 2:37:28tried and it went like 25 times back and
  3594. 2:37:30forth and at the last end it went even
  3595. 2:37:32code to like you know basic Python
  3596. 2:37:35language the under under the hood of it
  3597. 2:37:37like it went way too deep. How do you
  3598. 2:37:40think we can bound it? Do you have any
  3599. 2:37:42like do you have thought about it like
  3600. 2:37:45can you share your experience or like
  3601. 2:37:47how you restrict like the review part
  3602. 2:37:50that with the resp like the latest model
  3603. 2:37:54is like throwing way too much of code
  3604. 2:37:56reviews for me then it's all about
  3605. 2:37:59prompting and the
  3606. 2:38:02every the information you give these
  3607. 2:38:04models that's how you bound these models
  3608. 2:38:07to do what you want and I don't have
  3609. 2:38:10like an easy I don't have like an easy,
  3610. 2:38:12hey, just go and do this and this. This
  3611. 2:38:15is an iterative process that's going to
  3612. 2:38:18become better and better and better and
  3613. 2:38:20better as you work on it. So
  3614. 2:38:23start somewhere,
  3615. 2:38:25realize what's failing, realize what
  3616. 2:38:28your model is doing that you don't want
  3617. 2:38:29your model to do, and start basically
  3618. 2:38:33prompting your way into what you want
  3619. 2:38:36them to do. And when I say prompting, I
  3620. 2:38:38mean the documents that you provide your
  3621. 2:38:40model, the cloud MD file, the agents.m
  3622. 2:38:43MD file, depending on what you're using,
  3623. 2:38:44the skills that you're creating for your
  3624. 2:38:46model to do this. You need to specify
  3625. 2:38:49little by little the things that you
  3626. 2:38:51want, the behavior you want to see, the
  3627. 2:38:53behavior you don't want to see. And over
  3628. 2:38:56time, you're going to get to the point
  3629. 2:38:58where the models are doing
  3630. 2:39:01better. They're doing what you want them
  3631. 2:39:03to do. So I don't have a specific
  3632. 2:39:04advice. uh is just this is an iterative
  3633. 2:39:09process. This is the new coding. Okay,
  3634. 2:39:12before coding was about typing the lines
  3635. 2:39:15of code. Now the co the new coding is
  3636. 2:39:18how can we instruct these models
  3637. 2:39:21better. Now it's it's another type of
  3638. 2:39:24coding. It's in English but it's telling
  3639. 2:39:29what examples can I provide? What kind
  3640. 2:39:31of examples can I provide? uh how should
  3641. 2:39:34I how do I emphasize that something is
  3642. 2:39:37very important versus something else
  3643. 2:39:39that is less important that's the new
  3644. 2:39:41coding and unfortunately we're just
  3645. 2:39:44learning all of these we're not sure and
  3646. 2:39:48even more unfortunately
  3647. 2:39:50it does I know that's a weird way to
  3648. 2:39:52construct this the sentence but when the
  3649. 2:39:55new model comes out whatever the new
  3650. 2:39:56version is some of these principles will
  3651. 2:40:00change so some of the things. I don't
  3652. 2:40:03know if you guys remember when we had to
  3653. 2:40:06well writing capital letters the areas
  3654. 2:40:08where you want the model to really pay
  3655. 2:40:10attention or write critical important
  3656. 2:40:14important and a bunch of tricks to get
  3657. 2:40:16these models to pay attention to certain
  3658. 2:40:18things. All of those or some of those
  3659. 2:40:21are no longer relevant because new
  3660. 2:40:23models don't need that. They're gonna be
  3661. 2:40:26new models and some of these techniques
  3662. 2:40:28and tricks are just going to be outdated
  3663. 2:40:30and we're going to keep learning and
  3664. 2:40:32getting this to a point where it
  3665. 2:40:34actually works. So anyway, hopefully
  3666. 2:40:35that makes sense.
  3667. 2:40:42What else? Anything else?
  3668. 2:40:53Apparently, my new post is less. Just to
  3669. 2:40:56be to be fair,
  3670. 2:40:59the last post that I wrote about this, I
  3671. 2:41:01said, "I'm not reading my code anymore."
  3672. 2:41:05I was specifically talking about not
  3673. 2:41:07reading my code. I don't remember the
  3674. 2:41:08post, but it got
  3675. 2:41:11it on fire. So many likes and so many
  3676. 2:41:15reactions and whatnot. And a lot of
  3677. 2:41:18people, like literally a lot of people
  3678. 2:41:20told me today I was gonna be death. And
  3679. 2:41:23and I get what why, right?
  3680. 2:41:27A lot of people have a strong reaction
  3681. 2:41:29when somebody tells them the thing that
  3682. 2:41:33you are known for is not longer
  3683. 2:41:36valuable. I have a strong reaction.
  3684. 2:41:39Okay. [clears throat]
  3685. 2:41:40So if you're a developer and that's how
  3686. 2:41:42you identify if I tell you developing
  3687. 2:41:46software is not longer relevant of
  3688. 2:41:49course you are going to you're I cannot
  3689. 2:41:51expect you to say oh well that's fine
  3690. 2:41:54right you're going to have a strong
  3691. 2:41:56reaction but yeah I said I'm not I I
  3692. 2:41:59I've been a hold out I've been reading
  3693. 2:42:01code and trying to sort of like reduce
  3694. 2:42:04output so I can keep up with
  3695. 2:42:07verification for a long time but at some
  3696. 2:42:09point you have to realize guys who am I
  3697. 2:42:12lying to I'm not better than this thing
  3698. 2:42:15writing code right I'm better at
  3699. 2:42:18understanding the whole system the big
  3700. 2:42:20picture talking to customers sure
  3701. 2:42:24I'm not better at writing the lines it's
  3702. 2:42:26I'm I'm not finding bucks okay somebody
  3703. 2:42:30told me you're not finding bucks because
  3704. 2:42:31you're not capable of well yeah maybe
  3705. 2:42:35I'm not capable of that's okay the model
  3706. 2:42:39is better than I am. That's my point.
  3707. 2:42:41I'm not finding bugs because I'm not
  3708. 2:42:43capable. I have the inability to find
  3709. 2:42:47bugs. So, why am I reviewing the code if
  3710. 2:42:50I'm not good enough to find those bugs
  3711. 2:42:52in the first place? Right. You got a
  3712. 2:42:54point. Thank you for insulting me in a
  3713. 2:42:57way that proves my freaking point. So,
  3714. 2:43:00anyways, it's just it's just what it is.
  3715. 2:43:02It's mine.
  3716. 2:43:04>> Come on, Santiago. You do. You just
  3717. 2:43:06ignore it, right?
  3718. 2:43:11when you're chatting when you're
  3719. 2:43:12chatting with customers like for example
  3720. 2:43:14you mentioned Boston dynamics and like
  3721. 2:43:16others uh and you also pointed out that
  3722. 2:43:20like you know there are sections of the
  3723. 2:43:22globe which don't even have internet
  3724. 2:43:24right so how far in advance like in the
  3725. 2:43:28US how far the advanced companies are
  3726. 2:43:31from you know limiting number starting
  3727. 2:43:33to limit number of people humans
  3728. 2:43:36involved in the processes like the
  3729. 2:43:38warhouse example that you were
  3730. 2:43:40describing, right? Like can we imagine
  3731. 2:43:42that there will be no maybe I don't know
  3732. 2:43:44three humans just walking around in the
  3733. 2:43:47dark anytime soon or is it like a 10
  3734. 2:43:50years from your kind of perspective
  3735. 2:43:52view? What's your thoughts?
  3736. 2:43:56>> I don't know man. What do you think?
  3737. 2:43:59>> Oh like I myself I'm hopeful that it
  3738. 2:44:02will create more opportunities.
  3739. 2:44:04>> Yeah.
  3740. 2:44:05>> Is it bumpy time? So if you have savings
  3741. 2:44:08probably keep them right now well
  3742. 2:44:11invested but the ultimate like couple of
  3743. 2:44:15years decades from now it will be great
  3744. 2:44:17awesome so our kids and grandkids will
  3745. 2:44:19have very nice lives I
  3746. 2:44:22>> so I I think it will all obviously will
  3747. 2:44:25create more opportunities the question I
  3748. 2:44:27don't know how to answer is will those
  3749. 2:44:30new opportunities
  3750. 2:44:32the beneficiaries of those opportunities
  3751. 2:44:34will be the people who are displaced
  3752. 2:44:36here like For example, if we go back
  3753. 2:44:38when we invented the car, right? There
  3754. 2:44:40were people tending horses. Uh they
  3755. 2:44:42will, you know, giving food to the
  3756. 2:44:44horses and cleaning them or whatnot.
  3757. 2:44:46>> Those were not the ones that became
  3758. 2:44:48mechanics. So, yes, the car, you know,
  3759. 2:44:51brought a bunch of mechanics and a new
  3760. 2:44:53job.
  3761. 2:44:54>> Y,
  3762. 2:44:54>> but they were not the ones tending the
  3763. 2:44:56horses. Those were there. That's it. No,
  3764. 2:44:59we don't care about you anymore. Right.
  3765. 2:45:02So that's my question now is are these
  3766. 2:45:05>> that's obvious
  3767. 2:45:06>> going to be available to us? Are we
  3768. 2:45:09going to be able to just move and sort
  3769. 2:45:12of like uh stop doing what we're doing
  3770. 2:45:14and sort of become the new thing fast
  3771. 2:45:17enough? That's what I'm saying. You
  3772. 2:45:19know, the more I think about this is
  3773. 2:45:21just education, keeping up with what's
  3774. 2:45:23happening, right? If you just say,
  3775. 2:45:25"Okay, I don't care about this anymore."
  3776. 2:45:28Yes, you're going to be left behind.
  3777. 2:45:29you're gonna get replaced eventually. Uh
  3778. 2:45:32if you're trying to keep up, I think you
  3779. 2:45:34have a better chance. Yeah,
  3780. 2:45:36>> it's always been like this. Like, you
  3781. 2:45:37know, the whole move from like onrem
  3782. 2:45:40self-hosted stuff through the cloud now
  3783. 2:45:42to like completely crazy solutions.
  3784. 2:45:45Uncle Bob, he's like 70. He's like a
  3785. 2:45:47legend. He he invented like, you know,
  3786. 2:45:51uh good good good software practices,
  3787. 2:45:54right? And he's still there. So those
  3788. 2:45:56people will survive. We'll be fine. I
  3789. 2:45:58posted a nice link to Asimov's story.
  3790. 2:46:00So, war freedom if you're interested the
  3791. 2:46:03profession.
  3792. 2:46:04>> Okay, cool.
  3793. 2:46:06>> Got it.
  3794. 2:46:07>> Anyway, I'm talking too much probably.
  3795. 2:46:09So, yep. Zip. H curious curious about
  3796. 2:46:12what you me what what I ask about like
  3797. 2:46:14your experience with companies, how far
  3798. 2:46:17they are in automating and you know and
  3799. 2:46:20and doing the ML stuff, ordinary
  3800. 2:46:23companies, not our bubble. Yep. Manor,
  3801. 2:46:27what's up?
  3802. 2:46:28Yes, maybe my last intervention. So just
  3803. 2:46:31about reading code for me again also I I
  3804. 2:46:34don't think I read much code either and
  3805. 2:46:37for me it's more like the compiler now.
  3806. 2:46:39No, nobody's going to look at the output
  3807. 2:46:42of a compiler because you trust that the
  3808. 2:46:43person will build the compiler did it
  3809. 2:46:45right. So my two cents me here is we
  3810. 2:46:48will probably move into a more of
  3811. 2:46:52building blocks that we can trust and
  3812. 2:46:54more deterministic things produced by
  3813. 2:46:57LLMs where you know in advance that this
  3814. 2:47:00is working. I don't need to look into
  3815. 2:47:02it. I don't think we're going to keep
  3816. 2:47:04burning tokens like we do to recreate
  3817. 2:47:06each time the same kind of application.
  3818. 2:47:09Doesn't make sense. You could be talking
  3819. 2:47:10about the zero token architecture. In a
  3820. 2:47:13sense, it make it's close to to to to
  3821. 2:47:17what where we need to go, which is
  3822. 2:47:19basically not reinvent the wheel and
  3823. 2:47:21burning tokens every day for the things
  3824. 2:47:23we know how to build and then maybe use
  3825. 2:47:26LM for things that are frontier, things
  3826. 2:47:28that we never built before.
  3827. 2:47:30>> But this is my my two cents, but reading
  3828. 2:47:32code for sure. Yes, it won't be the
  3829. 2:47:34thing we need to be doing. We need to
  3830. 2:47:36think about systems at a at a different
  3831. 2:47:38level.
  3832. 2:47:39>> 100% 100% with you. Uh again, right now
  3833. 2:47:43the easier thing and the the the fun
  3834. 2:47:46thing is just to build everything from
  3835. 2:47:47scratch. But if you think about it is
  3836. 2:47:49this is not what's going to happen. It's
  3837. 2:47:51impossible to think of a future where
  3838. 2:47:54everyone who's going to build an
  3839. 2:47:55application is going to start from the
  3840. 2:47:57foundation and build everything and
  3841. 2:47:58spend the tokens to build everything
  3842. 2:48:00over and over and over and over again.
  3843. 2:48:02So we're going to get to a point where
  3844. 2:48:04we're going to have components, AI first
  3845. 2:48:06components, whatever that means. Don't
  3846. 2:48:08ask me what that means, but components
  3847. 2:48:10like libraries that we have today that
  3848. 2:48:12are going to do a lot of the work. Now,
  3849. 2:48:14what we have not found is a mechanism
  3850. 2:48:17for those components to exist right now
  3851. 2:48:20in a world where everyone wants to start
  3852. 2:48:22from scratch and build everything. So
  3853. 2:48:26just like we invented libraries before
  3854. 2:48:28and we reuse all of those libraries in
  3855. 2:48:30order to build something we need in the
  3856. 2:48:33new world those components that LLMs are
  3857. 2:48:36going to constantly use to build new
  3858. 2:48:38things. Uh what that those look like I'm
  3859. 2:48:41not sure. Here's the thing what I was
  3860. 2:48:43saying about the economic impact about
  3861. 2:48:45this.
  3862. 2:48:46I know a lot of people who work on open
  3863. 2:48:49source they stopped or they're thinking
  3864. 2:48:51of stopping. Why would they want to keep
  3865. 2:48:54contributing to a tool that LLMs are
  3866. 2:48:58just reproducing on their site? Why
  3867. 2:49:01would they? So, we have to figure that
  3868. 2:49:04out. Why would I write a blog where LLMs
  3869. 2:49:08are the ones that are just processing
  3870. 2:49:11that block and giving those answers
  3871. 2:49:13away? What is my economic incentive?
  3872. 2:49:16Before I got traffic from Google, I was
  3873. 2:49:20able to sell ads.
  3874. 2:49:23Google is not giving me traffic anymore.
  3875. 2:49:25The chat GPT is not going to give me
  3876. 2:49:27traffic. People are not asking questions
  3877. 2:49:29on Google anymore. So, until we figure
  3878. 2:49:32that out, we're going to see where we
  3879. 2:49:35get. But I I believe in a future where
  3880. 2:49:37again, everyone will start from big
  3881. 2:49:39components to build things that that
  3882. 2:49:42process works. People are not going to
  3883. 2:49:44be building applications on their phones
  3884. 2:49:46and starting from scratch. I don't think
  3885. 2:49:48that's what's going to happen. Yeah, I
  3886. 2:49:49I'm with you on that.
  3887. 2:49:52Yep.
  3888. 2:49:58All right. We good then?
  3889. 2:50:03All right. We can keep the conversation
  3890. 2:50:04on Wednesday. Remember, Wednesday office
  3891. 2:50:06hours, Thursday session number two.
  3892. 2:50:09We're going to move in session number
  3893. 2:50:11two forward. Okay. So now let's build
  3894. 2:50:13the model. We're in the middle of a
  3895. 2:50:15project. What do we do? How do we do it?
  3896. 2:50:17How do we select the best model? Etc.
  3897. 2:50:19etc. And uh yeah, I'll see you guys on
  3898. 2:50:22Wednesday.
  3899. 2:50:23>> Do we have any code to review until
  3900. 2:50:26Wednesday?
  3901. 2:50:27>> You don't have to, but obviously you
  3902. 2:50:29have access to the entire codebase.
  3903. 2:50:31There are no homework or anything. The
  3904. 2:50:33code base it's uh I was going to say
  3905. 2:50:36self-explanatory, but that's not true.
  3906. 2:50:40the codebase when when you follow the
  3907. 2:50:42instructions uh that's going to install
  3908. 2:50:44a plug-in on your Visual Studio Code
  3909. 2:50:46that is going to help you an extension
  3910. 2:50:48that's going to help you navigate all of
  3911. 2:50:50the code. I wrote explanations
  3912. 2:50:53practically line by line so you can
  3913. 2:50:55follow all of those uh the whole session
  3914. 2:50:59and go through all of the code that I
  3915. 2:51:01built. There are assignments for every
  3916. 2:51:05section of the code. I leave a bunch of
  3917. 2:51:08assignments that you can solve if you
  3918. 2:51:09find them helpful. But none of that is
  3919. 2:51:12required for you to attend the session
  3920. 2:51:14or not. So that's you can do that on
  3921. 2:51:16your own.
  3922. 2:51:17>> Thanks.
  3923. 2:51:18>> Cool.
  3924. 2:51:20>> All right.
  3925. 2:51:22>> So have a great day.
  3926. 2:51:24>> See you too. See see you Wednesday. See
  3927. 2:51:26you guys.

About this transcript

This page contains the full transcript of Session 1 - How To Start (Almost) Any Project by Underfitted, generated from the public captions YouTube serves with the video. The transcript has 27,487 words across 3,927 segments, with the original timestamps preserved so you can click any line to jump to that moment in the embedded player.

What you can do with it

Use the transcript to take notes, quote the speaker, build a study guide, generate a summary with ChatGPT or Claude via the YouTube Summary tool, or export it as a timed subtitle file with YouTube to SRT. You can also re-open it in the transcriber to translate the transcript into 100+ languages.

Free YouTube transcript tool

YouTube2Text is a free YouTube transcript generator — no signup, no daily limit. Paste any YouTube link and get the full transcript instantly, with timestamps, click-to-jump, translation to 100+ languages, AI prompts for ChatGPT, Claude, and Gemini, and exports to TXT, SRT, VTT, or Markdown.