Getting Started: Claude Code for Economists with Paul Goldsmith-Pinkham | Markus' Academy | Ep.162-1 — Transcript
Full transcript
- 0:08Thanks for joining us
- 0:10for mini series on Claude code for
- 0:13applied economists
- 0:15with Paul Goldsmith Bingham. Hi Paul,
- 0:17good to have you.
- 0:18Hi Marcus, thanks so much for having me.
- 0:21Great. So today we learn how to use LLMs
- 0:26for empirical research, but this is part
- 0:29of a mini series and we had an earlier
- 0:31mini series with Ben Gallop who focused
- 0:33on economics and the theoretical
- 0:35economics. He showed us how to use LLMs
- 0:37with cursor. This was in December 2025.
- 0:41But he also had a video on prompting
- 0:43insights and on his new software
- 0:46refine.ink where you can actually run
- 0:48your paper through this software and get
- 0:51a referee report and get some feedback
- 0:54how to improve your paper. But today we
- 0:56will work with Paul on Claude code and
- 1:00to some extent co-work how to use this
- 1:04LLMs for applied economic research. So
- 1:07thanks a lot Paul. We're looking forward
- 1:09to your presentation.
- 1:10>> Great.
- 1:11Great, thank you so much Marcus. This is
- 1:13a real pleasure and I'm looking forward
- 1:15to this and I hope
- 1:16you know, it's so funny as I get ready
- 1:18to sort of share this is that you know,
- 1:20you say that you had you had Ben do this
- 1:25just in just in December
- 1:28and things have changed a lot even even
- 1:30since December. It's sort of remarkable
- 1:31how much of this is changing all the
- 1:33time. So I know I'm hopefully this will
- 1:34be useful to people cuz I know people
- 1:36are excited. So today we're going to be
- 1:39getting started really. I'm going to
- 1:40kind of overview and then I'm going to
- 1:43talk about the various things we'll talk
- 1:44about in the mini series. For this video
- 1:47I want to start by just kind of giving a
- 1:49brief motivation. I think
- 1:51Marcus you sort of reach a lot of
- 1:52people. Some people are going to be more
- 1:53excited about this than others. I wanted
- 1:55to give kind of two brief motivations
- 1:57about what you can think about. I think
- 1:59for one is that I found that these
- 2:01tools, especially for coding and for
- 2:03empirical research,
- 2:04really kind of let you do more faster.
- 2:07The distance, kind of how quickly you
- 2:09can go from oh, I have a brief idea to
- 2:10something that looks like an empirical
- 2:12result is
- 2:13is just
- 2:14so so much quicker than it is before. I
- 2:17think cleaning data, doing things I'm
- 2:20not totally sold or convinced on this
- 2:21idea that the raw AI ideas that you're
- 2:24getting without any kind of key insight
- 2:26yourself is that compelling yet. I think
- 2:30people sometimes refer to this as taste,
- 2:32but really the execution and the speed
- 2:34is kind of remarkable. It's really
- 2:35amazing. It really helps if you're an
- 2:37empirical researcher. I mean, just clean
- 2:38as we kind of all know, like cleaning,
- 2:41debugging, all of that is really
- 2:43painful. Um, it's important, but it's
- 2:45it's really quite painful. And the other
- 2:47thing is that it's going to really
- 2:48encourage coding work that often times
- 2:51will have a much better um
- 2:53reproducibility framework. So, you know,
- 2:56keep track of your path. Because you're
- 2:57doing it, the computer is doing it and
- 2:59doing it relatively quickly. That's one
- 3:00side. I think for people, I hope people
- 3:02will kind of be excited about this. And
- 3:04then the other for the more skeptical
- 3:06folks, I just want to kind of point out
- 3:08that at the minimum you should know kind
- 3:10of how it works and understand what the
- 3:12capabilities are so you can kind of see
- 3:14where the limits are. I think that's
- 3:15really useful to see um, either as a
- 3:18referee, an advisor, or a co-author, you
- 3:20should be kind of calibrated to what's
- 3:22going on. So, that hopefully you'll find
- 3:24this exciting. I think today in this
- 3:26video
- 3:27if you're a person who's already
- 3:28familiar with Claude code, there's going
- 3:30to be some stuff maybe you listen to us
- 3:31on 2x speed, you know, you figure out
- 3:34until where it's interesting. Uh, this
- 3:36is really going to be kind of setting up
- 3:37and giving core concepts of what's going
- 3:39on and kind of giving an overview. Um,
- 3:42we'll try to go over that and Marcus,
- 3:44you let me know if I missed anything
- 3:45that you think would be important. And
- 3:47then we'll kind of move on in the other
- 3:48videos to just building up. I think
- 3:50videos 1 through 3, if you're kind of
- 3:52new to this, will give you kind of the
- 3:53entryway of seeing how this can work.
- 3:56So, next video we'll start with just a
- 3:57really simple data analysis task where
- 3:59we'll pull data from the web, kind of
- 4:01ask it a question
- 4:03about where data is, we'll pull it from
- 4:04the web, and then we'll we'll make some
- 4:06figures with it that are kind of more
- 4:08than just a simple time series, thinking
- 4:10about um home ownership in the United
- 4:12States.
- 4:13And then the third video we'll think
- 4:14about scraping data from Edgar. So, if
- 4:17you haven't used Edgar before, this is
- 4:18just a database of all filings for
- 4:20public firms, lots of different file
- 4:23forms there. It's kind of very
- 4:24complicated unstructured text data.
- 4:27We're going to just do a particular
- 4:28exercise in it. It will kind of show you
- 4:30how you can do a more complicated data
- 4:32exercise and what you can do.
- 4:34And then we'll talk about big data sets.
- 4:37I think one of the really nice things is
- 4:38that um
- 4:40Claude and other LLMs really can teach
- 4:42you how to work better with big data
- 4:45sets, both in terms of structuring
- 4:46databases, parallelizing, working on
- 4:49clusters, like on the if you have a
- 4:51high-performance cluster that at your
- 4:53university.
- 4:54Um so, that's I think really important.
- 4:56Hopefully, we'll spend a bunch of time
- 4:57there.
- 4:58Uh
- 4:59another kind of side one is about
- 5:01writing and writing like sort of
- 5:03thinking about referee responses and so
- 5:05forth. I just kind of want to show this
- 5:07here, not so much of the idea of oh,
- 5:08this can do all your work for you. I
- 5:09think people are very aware of this for
- 5:11like
- 5:12you can have ChatGPT or something write
- 5:14things for you, but I want to show you I
- 5:15think the key one I'm going to try and
- 5:16show you is
- 5:17one related to the idea of
- 5:20you just got an R&R,
- 5:22you know, the you got a editor letter,
- 5:24you got referee responses. This is
- 5:26really lovely skill that was written up
- 5:28by someone where you can use Claude to
- 5:30go through them and kind of construct a
- 5:31task list of things that you need to do,
- 5:33and um and can really execute, which is
- 5:36pretty pretty remarkable and I think
- 5:37useful for everyone, even if you're not
- 5:39a big coder. Then we'll talk about some
- 5:40customization. This is kind of really ad
- 5:42hoc in terms of things that I've used to
- 5:45make
- 5:46um Claude more useful for myself.
- 5:48And also we'll talk about some of the
- 5:49best practices and get workflows. So for
- 5:524 through 7, I think you can mix and
- 5:53match, but we'll kind of try and do
- 5:54those just so that you can have some
- 5:56other extensions and ideas of how to
- 5:58work on stuff.
- 5:59So
- 6:01let's go forward and kind of today what
- 6:02we're going to do in this video is we're
- 6:03going to touch on a number of things.
- 6:05First is just talk about Claude Code,
- 6:07which is going to be the main thing
- 6:08we'll talk about in these videos. And I
- 6:09want to compare it to other tools. And
- 6:11this is really going to be kind of
- 6:12giving you a guideline of what this
- 6:13looks like.
- 6:15We'll kind of briefly go over what the
- 6:16installation looks like. It actually
- 6:17turns out there's not a lot there. It's
- 6:19pretty easy,
- 6:21um which is nice. And we'll talk about
- 6:22what does that entail from a a pricing
- 6:24standpoint like to use it. If you use
- 6:26any If you pay for any AI service, it's
- 6:29kind of comparable. So if you already
- 6:30pay for Claude, you have access to this.
- 6:32Um then we'll talk about the context
- 6:34window, which is an important concept in
- 6:35this. Talk about data and privacy
- 6:37generally, which I know is a thing of
- 6:39people are concerned about. I'll briefly
- 6:41talk about things you can do if you're
- 6:43going to work on the command line to
- 6:44make your life easier. And I'll just
- 6:46kind of end by being like, "Okay, how
- 6:47could one quickly go through this?" And
- 6:49we'll wrap up for today's video.
- 6:52So what is Claude Code? So you might
- 6:55have heard people talk about this. I
- 6:57know people, you know, just refer to
- 6:59Claude. This is just What is this thing
- 7:01that's going on? One way to think about
- 7:02it is it's
- 7:04really kind of an LLM that's running
- 7:05inside your computer. It's on your
- 7:07computer. That's not actually what's
- 7:08going on. It's still going to the
- 7:11internet. But really the one way to
- 7:13think about it is if you've ever seen um
- 7:16you know, videos of the Matrix or
- 7:17something like that, you're kind of
- 7:18typing and and writing all these
- 7:20commands on the on the command line.
- 7:22And it's all these kind of very
- 7:24complicated Unix scripts or other types
- 7:26of things that you need to do. The
- 7:28benefit here is that you open up a a
- 7:30program and instead of having to know
- 7:32all these different scripting languages,
- 7:34you just write in natural English or
- 7:36whatever your preferred language is, and
- 7:38it's going to convert that into code
- 7:41that will do things on your computer. Um
- 7:44it can work on your file system, so it's
- 7:46not like going onto the web. Um
- 7:49really you can think of it as like an RA
- 7:50who's doing stuff for you. So, it can
- 7:52read your code, it can run scripts, it
- 7:53can build things. You're going to talk
- 7:55to it. And the analogy I like to use is
- 7:57that well, what this is when you use the
- 8:00web and you're using these chat programs
- 8:01on the web, this is a lot like
- 8:03exchanging emails with someone very
- 8:05smart. So, if I was trying to get advice
- 8:06from Marcus, you know,
- 8:08uh I'm getting doing emails, I kind of I
- 8:10send something, he has to think about it
- 8:12for a bit, I kind of have to wait for it
- 8:13to come back, I have to sort of be
- 8:15paying attention.
- 8:16Um
- 8:17the benefit, you know, the problem there
- 8:19is sometimes Marcus will ask about
- 8:20something that he doesn't have access to
- 8:22and I forgot to send to him and so
- 8:23forth. Claude code often, you know,
- 8:25it'll be right there.
- 8:27It can write the files, it can pay it
- 8:29can search through files. So, if you've
- 8:31ever had an experience of something like
- 8:34I want to upload a big paper to to
- 8:38something like Claude or ChatGPT to get
- 8:39a summary. Sometimes these files are
- 8:41really big, they're like 100 pages long,
- 8:43very complex. And
- 8:46what the benefit on your computer is
- 8:48that Claude can sort of know that it
- 8:50needs to summarize and search within it
- 8:52because these files are are too big to
- 8:53kind of just read all in one go.
- 8:56So, that's kind of the real benefit of
- 8:58moving to this system. So, you know, one
- 9:00way to think about this is that I've
- 9:02good friend of mine Kyle Jensen has kind
- 9:03of described it this way in a talk that
- 9:05I summarized on my blog if you're
- 9:06interested is like there's this AI, he
- 9:09calls it this path pathway to
- 9:11enlightenment, but these different
- 9:12ladder of where you are. And so, I think
- 9:14a lot of folks are at zero to one. So,
- 9:17they're either using ChatGPT in a
- 9:18browser to kind of co- asking how to
- 9:20code something in ChatGPT, they copy it
- 9:22down, they put it into the editor, then
- 9:23they run that, then there's an error,
- 9:25then they copy it back up, and so on and
- 9:27so forth. Um
- 9:29and level one is something where you
- 9:33have a IDE. So, when I you say IDE, um
- 9:36this is just a an editor, right? So, um,
- 9:40like VS Code, Cursor is another example.
- 9:43I use something called Zed sometimes.
- 9:45Um, these are all ways of editing your
- 9:46code. Um,
- 9:48and what's nice about them is that you
- 9:50can have the LLM's right working in
- 9:52there. So, Copilot, which was very
- 9:54popular program, is the thing that does
- 9:56inline completions and will help write
- 9:58your code. It's really remarkable and is
- 9:59very helpful.
- 10:01You can have a chat with your LLM.
- 10:03It's all kind of embedded in the
- 10:05environment.
- 10:06Um, zero and one is kind of Yeah, go
- 10:09ahead, Marcus. Yeah. What's the
- 10:10Microsoft Copilot?
- 10:11Yeah, so there's a Yeah, VS Code has
- 10:13something called Microsoft Copilot.
- 10:15Yeah, which is coming from
- 10:17um, and that's it's really, uh, you
- 10:20know, Microsoft owns GitHub. GitHub is
- 10:21the one who provides it and so it's all
- 10:23coming They have the same name. It's
- 10:24Copilot. So, there's a Microsoft
- 10:26Copilot, which goes in like when you're
- 10:28in Word or something. Yeah.
- 10:30But that's a distinct one from there's
- 10:31something called GitHub Copilot, which
- 10:33is also owned by Microsoft. But in the
- 10:35end, those are all just using LLM's in
- 10:37the back end and integrating with this
- 10:39this software.
- 10:41The real trick here is that this just
- 10:42uses inline This does like a chat
- 10:45and has inline completions, but it's
- 10:47it's sort of still similar more similar
- 10:49to the ChatGPT in a browser than it is
- 10:51to, um, anything else.
- 10:54Two and three and onwards kind of get
- 10:56more into what people This is what often
- 10:58people call agentic AI. This idea that
- 11:01you have agents, um,
- 11:04that are doing things, that are reading
- 11:05tasks, um, running things, doing things
- 11:07on their own,
- 11:09rather than kind of giving you one
- 11:10response you accept and you go like in
- 11:12the code. It can run its own code. It
- 11:14can search the web in its own way. It
- 11:16can use basically use tools. It's kind
- 11:18of the key thing. So, Cursor, which I
- 11:20think, uh, you said, uh, Ben has talked
- 11:23about, that's a very powerful kind of
- 11:26agentic forward IDE in the sense that it
- 11:30really allows for agents All all of
- 11:32these
- 11:33um editors now to some extent allow
- 11:35agents to work in them.
- 11:37But Cursor is very AI agent forward. And
- 11:41what it means is you can sort of sit
- 11:42there, tell tell your LM to do
- 11:44something, and it will kind of just run
- 11:46all over the screen. It looks like it's
- 11:48kind of running all over the screen
- 11:49doing things. It will edit things. It
- 11:50will kind of look over here. It will
- 11:52read files. You know, you could give it
- 11:53a BibTeX file and
- 11:55tell it to add all these references, for
- 11:57example. But I have I have to ask each
- 12:00and every particular task. So, I have to
- 12:02do or the LM is just
- 12:04>> So, often you'll sort of tell the
- 12:06high-level So, the way that it will work
- 12:08um
- 12:09is that you'll tell it a task, and it
- 12:11will kind of figure out what you're
- 12:12thinking what the tasks need to be, and
- 12:14it will kind of go and do those tasks.
- 12:15So, you'll say, "Update my CV with all
- 12:18the papers that are on my website." It
- 12:20will say, "Okay, first I need to figure
- 12:21out all of the papers that are on
- 12:22Marcus's website." And it will search
- 12:24the web and find your website. It will
- 12:26download those, and then it will
- 12:28dispatch someone to write and update
- 12:30your CV, maybe in in tech in LaTeX, if
- 12:33that's what it is, and it will do that.
- 12:35Um
- 12:37That's kind of This is you know, this is
- 12:39already pretty advanced, and this is
- 12:40this is useful. What has kind of become
- 12:42the new thing that people are using and
- 12:44what we're going to try and push towards
- 12:46today is these dedicated coding agents.
- 12:48So, there's several of them. So, I'm
- 12:51going to talk about Claude Code, but I
- 12:52do hope that people should sort of think
- 12:54about this as being There are many
- 12:56open-source softwares to use this, and
- 12:58we'll talk about Co-worker as well.
- 13:00These are kind of ways of doing kind of
- 13:02you're letting the agents work kind of
- 13:05in these computing environments and
- 13:07doing kind of whatever you allow them to
- 13:09do. So, they can think about a task.
- 13:11They can read files, write files, use
- 13:13tools, execute, create plans, and so
- 13:16forth.
- 13:17Um Codex is kind of the the OpenAI
- 13:20version. Gemini has its own command-line
- 13:22version. Um
- 13:24There are open so There are open-source
- 13:27versions of this. So one is called open
- 13:28code and those let you use different
- 13:31LLMs in the back end. Um
- 13:33So this is they're all programs. The way
- 13:36that you should think about this and
- 13:37we've is that they're all programs that
- 13:40use LLMs in the cloud in some sense or
- 13:44you know, they're using an LLM. So
- 13:47they're kind of like harnesses that sit
- 13:48on top of whatever the machinery is. So
- 13:50or the you know, whatever the horse is.
- 13:52So what's the exact what are they doing
- 13:54in three? I mean in two I employ a bunch
- 13:57of agents to do something that might
- 13:58even interact with each other.
- 13:59>> Two is really going to be within um it's
- 14:02exclusively within an editor. And so
- 14:04kind of the key distinction here is that
- 14:07um
- 14:09it is they're going to be very similar.
- 14:11I think the the boundary between two and
- 14:13three sometimes is not going to be and
- 14:14so you know, Claude co-work in some ways
- 14:16is going to be closer to two than to
- 14:18three.
- 14:19Um the main way that kind of that this
- 14:22changes is that often Claude co-work and
- 14:25these other ones here, you can actually
- 14:27improve them significantly. They can
- 14:29really So
- 14:30the boundary between these two is pretty
- 14:32small in some ways, but the main way is
- 14:34and we'll talk about this in I think
- 14:35video seven where you can really improve
- 14:40the agent itself
- 14:42through updates to either what are
- 14:44called skills or it's it's kind of
- 14:47memory bank. So it's not actually
- 14:48memory, but you keep track of a file
- 14:50which says this is what I'm going to do.
- 14:52That can happen inside these agent modes
- 14:54that these kind of these harnesses all
- 14:57are kind of much more structured to do
- 14:59that kind of work. So
- 15:01I think this is you know, like all
- 15:03ontologies, this is this you know, the
- 15:05the metaphor breaks down eventually.
- 15:07And the kind of key reason why you
- 15:10always have to keep this in mind is that
- 15:11in the end they're all using the same
- 15:12LLMs. And we'll talk about like what
- 15:14these are doing, but LLMs in the end are
- 15:16generative AI models.
- 15:19You can only you know, slice up an AI
- 15:21model so many ways before it's the same
- 15:23idea going on, but you're adding kind of
- 15:24new new tools to it and everyone.
- 15:27I don't want to belabor the rest, but
- 15:29kind of
- 15:30four is a way of adding more tools,
- 15:32often through something called MCPs, to
- 15:33kind of improve and orchestrate how it's
- 15:35working. And five is like you basically
- 15:38create this container where you tell it
- 15:40what it's there and you let it go for an
- 15:42hour and a half by itself and it just
- 15:43works itself to completion. And that's
- 15:46kind of way beyond what we'll do, but we
- 15:48can talk about this at the end of the
- 15:49video series of what one When people
- 15:51post on social media, like, "Oh, AI
- 15:54wrote, you know, a whole paper for me in
- 15:56an half hour" or something, they're
- 15:57really referring to cases like this.
- 16:00Um but it's not inherently like
- 16:02necessarily better, but it just kind of
- 16:04you There's a lot more setup involved in
- 16:06it.
- 16:07So, let's kind of talk about what these
- 16:09are before and then just so that people
- 16:11can kind of get a sense is that
- 16:13I've mentioned a lot Claude Code.
- 16:15There's also Claude Co-work. There's
- 16:17Cursor and and Co-pilot and these other
- 16:20IDE-based ones. Zed AI is another. This
- 16:24is another basically actually Zed
- 16:25typically the the main one is Claude
- 16:27that's in there. These two here are
- 16:29IDEs. Um
- 16:32they are mainly This is so they're
- 16:34they're the level two that we talked
- 16:36about. Claude Code and Claude Co-work
- 16:38are kind of Claude Code is very much
- 16:41level three um and onwards. Claude Code
- 16:44is kind of floating betw- in the between
- 16:45the boundaries of one through three,
- 16:47depending on how you think about it. Um
- 16:50Let me start by saying what Claude Code
- 16:52is, just in case that like people
- 16:54haven't seen it yet and they say, "No."
- 16:56is and you know, I've shown Marcus this
- 16:57is like, you know,
- 16:59Claude Code, you're really sitting at a
- 17:00terminal. You really feel like,
- 17:02depending on your age, you're either
- 17:04somebody in the Matrix or, you know,
- 17:05Marcus was joking about his age is you
- 17:07feel like you're 30 years ago and you're
- 17:08back in the computing lab kind of
- 17:10situation. It's you're at MS-DOS and
- 17:12you're kind of remembering what commands
- 17:14are.
- 17:15Um the joke, of course, there is that
- 17:16like
- 17:17the whole point is that you don't have
- 17:19to do much on your own if you trust
- 17:20Claude code is that you just open it and
- 17:22it will do all the kind of matrix style
- 17:25coding, but it helps to be at least a
- 17:28little bit comfortable with the terminal
- 17:29for that reason. Um, what that will do
- 17:31is it can kind of let what's really
- 17:33powerful there is it lets you
- 17:36see your whole file system. You can
- 17:39um use bash commands, which is part of
- 17:41the shell script. This is the types of
- 17:42command. It is kind of a brainiac when
- 17:44it comes to shell commands and so it can
- 17:46do all this amazing stuff like kind of
- 17:48the best programmer.
- 17:50It's able to run scripts, install
- 17:52things, use get, um, do a lot of stuff
- 17:55in here. It's really like the closest
- 17:57thing to when you're running a real full
- 17:59program um or full project. That's what
- 18:01you want to be doing.
- 18:03Co-work, let me just kind of contrast
- 18:05that with co-work cuz I think um when
- 18:07Marcus and I have talked about this is
- 18:08kind of a really nice if you're really
- 18:10kind of not comfortable, you don't want
- 18:11to be on the command line. This is a
- 18:13nice entryway. I would not encourage
- 18:15this for full time.
- 18:17Um
- 18:18It's it's an app that sits on your
- 18:19computer. You download it. I'll show you
- 18:21in just a second how to do this, but it
- 18:22it's really a web browser a little bit.
- 18:24You're sort of kind of running it's just
- 18:26a Chrome port, I think um a chromium
- 18:28port.
- 18:29But it's like the web browser in there.
- 18:31It's on your computer though. It has
- 18:33access to your computer. You tell it
- 18:35what you want to use and it's going to
- 18:36be very sandboxed in what it does. Um,
- 18:38we talked about this in video seven.
- 18:40Sandboxing means like you're restricting
- 18:42what it can do and we'll talk about one
- 18:44challenge there is that it restricts
- 18:46your access to the internet. You can
- 18:47kind of do things to allow it to get
- 18:49access, but it's still going to be it's
- 18:51not going to be nearly as autonomous as
- 18:53Claude code is, but that has benefits
- 18:55because it's not as risky. Um, I think
- 18:58this is good if you're this is sort of
- 18:59similar if you're using a chat or if you
- 19:00want to do quick exploration with your
- 19:03stuff on your computer. This is great,
- 19:05but it's not really the full coding um
- 19:07stack in the same way.
- 19:09And then I think you've already talked a
- 19:10little bit with Ben about cursor and
- 19:12these other things, so I don't want to
- 19:12belabor it, but this is kind of more of
- 19:15like I'm using Claude code in the things
- 19:16that are open inside my IDE. That's kind
- 19:19of like then I can use Claude in various
- 19:21things within those open ones, but it
- 19:22kind of doesn't have full access to
- 19:24everything that's there or kind of
- 19:25access to kind of bash commands and
- 19:28everything else. The boundary is a
- 19:29little permeable in the sense that if
- 19:31I'm running Claude inside Zed, it could
- 19:34do stuff locally. This is not like Mhm.
- 19:37So, there's an app I just think that
- 19:39like
- 19:40really one way to think about this is
- 19:42that Claude
- 19:44code is kind of a version of what runs
- 19:46inside this, but it's kind of full uh
- 19:48more fully uh more oops, sorry, more
- 19:50fully operationalized.
- 19:52So,
- 19:53um I'm going to focus most on this um
- 19:58on Claude code just cuz I think it's
- 19:59with the closest to research workflows,
- 20:01but it's not exclusively that. So, the
- 20:03one comment I made and Marcus and I have
- 20:05talked about this is that in Claude
- 20:06co-work, it's very sandboxed, so it
- 20:10can't like run Python scripts to scrape
- 20:12the internet. Um we talked to Claude
- 20:15about what you can do, and it turns out
- 20:17um you know, there's a thing you can do.
- 20:19You can fix it. So,
- 20:21inside Claude code, there there's the
- 20:24desktop app or on the website, you can
- 20:26just go and allow it to access the
- 20:28internet and you kind of have to be
- 20:31permissive about what you let in and
- 20:32out.
- 20:34It's um Claude co-work. Co-work.
- 20:36Co-work. This is co-work. Yes, exactly.
- 20:38So, desk Claude desktop is Claude
- 20:40co-work. When you download something
- 20:41Claude Claude desktop, it has the chat,
- 20:44co-work, and something called Claude
- 20:46code as well, which is a version of
- 20:47basically um co-work, but using Git. Um
- 20:56The trick here is you can do things to
- 20:58allow it to be permissible. Mhm. The
- 21:00challenge here, and we talked about this
- 21:02a little Marcus, is that like
- 21:04there are some potentially some bugs
- 21:05here. I think this will all kind of get
- 21:07fixed up. This is probably a very
- 21:08reasonable way to approach these things,
- 21:10but it's not going to be kind of as um
- 21:13incredibly powerful out of the box. You
- 21:16kind of have to do more things, but if
- 21:17you're kind of risk-averse, this might
- 21:18be the thing that you like because in
- 21:20some ways I just wouldn't update too
- 21:22much about AI don't use this and then
- 21:24like not be able to do stuff and say,
- 21:25"Oh, AI is not that powerful." I think
- 21:27one way to think about this is like this
- 21:29is you taking LLMs and put a lot of um
- 21:31put a lot of uh what's it called? Um
- 21:35restrictions on it. So, that that's with
- 21:37the purpose. Code works still goes to
- 21:38the internet like chat?
- 21:41Yes, but it has a very um yes, so the
- 21:43way that it does it just that not to get
- 21:44into details is that it
- 21:46restricts very much what IP addresses it
- 21:48can get to. So, it Claude Claude Code
- 21:51work very much has to query Anthropic to
- 21:53get the LLM responses. Yes. But
- 21:57it has a very restricted way in which it
- 21:58can query the internet. And so, you have
- 22:00to kind of manage what it's allowed to
- 22:01do.
- 22:02I see.
- 22:03That's not the case for Claude Code by
- 22:05default.
- 22:07Okay. So, let me just quickly say like
- 22:09what does it mean to install it? Um
- 22:12you're basically going to search
- 22:14uh
- 22:15um Claude Code
- 22:16>> now? This is either I'll show you this.
- 22:18This is for Claude Code what you'd do.
- 22:20You can either you would just go this
- 22:22and you go to the command line and you
- 22:24would copy this one line. So, you'd open
- 22:25terminal and you'd copy this one line
- 22:28and you'd install it.
- 22:30There's a even a web a guide here. It's
- 22:32new to the terminal see the terminal
- 22:33guide for step-by-step instructions.
- 22:36Alternatively, if you want to download
- 22:37Code work, you're going to search
- 22:39download Code work and there'll be
- 22:40you'll choose choose one of these two
- 22:42and it will be there directly. So, the
- 22:44neither of these
- 22:45in some ways we should not belabor the
- 22:46installation because it is about as
- 22:48user-friendly as it can get.
- 22:50Um
- 22:52Last thing is in terms of costs. Um
- 22:55there's three levels. There's Pro, Max,
- 22:58and Max 20X.
- 23:00Um Pro, if you're using Claude chat
- 23:03functionality online and you're paying
- 23:05for it, this is almost certainly what
- 23:06you're using.
- 23:08Um,
- 23:09this is what I would start with if you
- 23:10want to try this out. I think it's
- 23:11great. If you're not a heavy user yet,
- 23:14it will get you started and you can see
- 23:15what's possible. I pay for the max, but
- 23:18that's in part because I use this
- 23:20huge amount.
- 23:22Um, there are ways to use the API to do
- 23:24things. So, the API means it is like a
- 23:26paper paper use.
- 23:28That's not really what I would do for
- 23:31this that the real kind of default view
- 23:33is that the subscriptions are heavily
- 23:35cross-subsidized in some ways that these
- 23:37are kind of
- 23:39these are really useful for the most
- 23:40part. Um, so I would start with either
- 23:43the 20 or the $100 one. I I don't think
- 23:45you need to move to the 200 um, at all.
- 23:47And that's true for Cohere as well. So,
- 23:49like I think you need at least 20 to be
- 23:51able to use Cohere um, locally.
- 23:54So, let me quickly um, talk about kind
- 23:57of the underlying key concept which is
- 23:58the context window. Um, I think, you
- 24:01know, people seeing this have started to
- 24:02hear this, but like
- 24:04you're going to see something which is
- 24:06going to be you're going to talk to the
- 24:07LLM, you'll see a response, you you
- 24:09know, write things, you'll see a
- 24:10response back and forth. But there's a
- 24:11lot of things there that you don't see.
- 24:13And so, what that looks like is like
- 24:16this. So,
- 24:17you know, this is what an LLM chat looks
- 24:19like. You have some prompt at the
- 24:20beginning
- 24:21which you don't see, which is called the
- 24:23system prompt. This is with ChatGPT, an
- 24:25example.
- 24:26It has all this information about things
- 24:28you can do. It has a developer message
- 24:30about what it should do. Then you see
- 24:32your question. So, it says, "What's new
- 24:35in the latest versions of Polaris?" And
- 24:37then there's a lot of thinking stuff and
- 24:38tool calls that it does. Finally, it it
- 24:41prints some results to itself.
- 24:43And then it has a response that it does
- 24:45in in response to it. Typically, you're
- 24:47only going to see the green part and
- 24:49this black part here. Sometimes,
- 24:51depending on how they do it, they'll
- 24:52talk about the thinking. They'll you can
- 24:54click on a thing, you can say, "Oh, it's
- 24:55thinking." And you click on what it's
- 24:57saying, and it will write this stuff.
- 24:59But what's important to notice is that
- 25:01if I continue this conversation, all of
- 25:03this chat will continue will be sent
- 25:05back. Every time it's sent,
- 25:08every time you query it, you send the
- 25:10whole thing back. It's so it's a cached
- 25:12message. And so,
- 25:15one way to think about it is that every
- 25:17time you say something, all of these
- 25:19things are appended together. When it
- 25:21reads a document, when it responds
- 25:22something. So, say you went down a
- 25:24rabbit hole and you spent, you know, 10
- 25:26minutes about something ridiculous
- 25:28that's irrelevant, all of that's getting
- 25:30sent back and forth.
- 25:31And so, kind of a key idea behind
- 25:34this is something called context
- 25:36engineering. So,
- 25:38there's this idea that it's sort of
- 25:39similar to when people talk about prompt
- 25:41engineering.
- 25:42You know, as you go along, there's all
- 25:44this work that that's kind of like, you
- 25:46know, like you're working on a proof
- 25:48markers or something. You have all this
- 25:49scratch paper which you do. And
- 25:50eventually, you're like, "Okay, let me
- 25:52take all these ideas and kind of write
- 25:53it very concisely on one piece of
- 25:55paper." Part of the reason is that you
- 25:57kind of have lost track of all the like
- 25:59things you care about in this.
- 26:01And so, what you'll And so, the you
- 26:05know, the idea that people say here is
- 26:06that kind of as you go longer and
- 26:09longer, the performance degrades. People
- 26:10say that kind of like
- 26:12as the size increases, performance
- 26:14declines. And kind of the more precise
- 26:16you are, kind of performance increases.
- 26:19So, it's this idea of the per- more
- 26:20precise you are in these things, the
- 26:22kind of better performance will be, but
- 26:24the longer it goes, the kind of worse it
- 26:26will be. And so, the the typical thing
- 26:28that people try to say is to
- 26:31um if as you get longer and longer, the
- 26:34LLM will eventually say, "Hey, I can't
- 26:36keep track of all of this. Let's
- 26:38basically make a memory. So, let's like
- 26:41write all Take everything we did and
- 26:42kind of summarize it." That's when it it
- 26:45will say something like on on a website
- 26:47on the the website, it will simply
- 26:49typically say something like, "Oh, you
- 26:51need to start a new chat."
- 26:53On Claude Code or on Claude Co-work, it
- 26:55will say, "Oh, I'm going to compact
- 26:57what's going on." And so, it will take
- 26:59all of this, it will make a memory, and
- 27:00then it will kind of embed this on here.
- 27:03And
- 27:04um
- 27:05what's better like the brain when you
- 27:07sleep, no, it also
- 27:08>> Exactly, exactly. I mean, this is
- 27:10the analogy, it's very hard to not
- 27:12anthropomorphize these things. I mean,
- 27:14these are There's reasons why these make
- 27:15sense as concepts. Um
- 27:17uh it's not exactly the same, but of
- 27:20course, it's similar. So, typically the
- 27:22way that people talk about improving
- 27:23this is being kind of explicit in the
- 27:26way that you do this. So, what you do is
- 27:28you first start by doing, "Okay, I'm
- 27:30going to think about this. I'm going to
- 27:31do some research. That's like my
- 27:32research thing. I'm going to do this.
- 27:33I'll have an idea." And then I'm going
- 27:34to say, "Okay,
- 27:36summarize all this and write it down in
- 27:37a file. Let's call it our research
- 27:39file."
- 27:40And then I'll say, "Okay, like given
- 27:42that, you know, summarize the things in
- 27:44particular that I wanted." Then I'll
- 27:45say, "All right, I'm going to start a
- 27:46new conversation.
- 27:48Read this research file, and now I want
- 27:50to make a plan of how to implement this.
- 27:51Blah blah blah blah blah. Let's do that.
- 27:53Now, write that plan to a file. Okay,
- 27:56I'll clear everything out. Now, I'm
- 27:57going to read the plan, and I'm going to
- 27:58get started."
- 28:00And this is kind of a way of kind of
- 28:01explicitly trying to be um purposeful in
- 28:05the way you do this. Now, what I'll say
- 28:072 months ago, 3 months ago, this was the
- 28:09way to do everything 2 months ago.
- 28:12Now, these things have gotten a lot
- 28:14better. Claude Code and these others
- 28:15they kind of know, they're much more
- 28:17intentional and better at how to compact
- 28:19things.
- 28:20This matters a little bit less, but this
- 28:22idea of break things into kind of
- 28:24actionable tasks is a really important
- 28:26concept.
- 28:27Can I guide it somehow what to memorize
- 28:30and how to start
- 28:31>> Yes.
- 28:32Yes, so when you're in this, you can
- 28:33write something called compact. So,
- 28:35there's a a skill or a command called
- 28:37compact, and you could say like, for
- 28:39example, imagine you did a bunch of
- 28:40research, you could say
- 28:42"Compact um uh
- 28:44remember let remember all the things
- 28:46related to
- 28:48um
- 28:49you know the
- 28:51you know non-linear programming that we
- 28:52just study like that we just focused on
- 28:54and it will then kind of in the thing
- 28:56that it compacts to here these memories
- 28:58it will be guided in the way that it
- 29:00does that as well.
- 29:01So it yeah it can be very explicit. So
- 29:03kind of the key way to think about this
- 29:04is the context window is kind of the
- 29:05shared resource everything you do
- 29:08takes it and so basically it's kind of
- 29:09like
- 29:10if you come to a meeting unprepared and
- 29:12kind of vague you spend a lot more time
- 29:14spinning your wheels. If you're focused
- 29:17and prepared that works much better and
- 29:19so kind of the idea is if say you feel
- 29:21unfocused it's better to kind of think
- 29:23for a bit with the LLM then you have
- 29:26your ideas settled you write those down
- 29:28and then you start a new session with
- 29:29those ideas.
- 29:31Okay. Let me Let me quickly talk about
- 29:33privacy.
- 29:35So this is something we've talked about
- 29:36is that now that we've talked about what
- 29:38Anthropic is seeing well when you do
- 29:40tool calls it's calling your data and
- 29:42like looking at it or it's reading
- 29:44what's going on and so there is an
- 29:46extent to which
- 29:48Claude code doesn't copy things to your
- 29:50server but
- 29:52your conversation is going there right
- 29:55it's reading stuff and going to the API.
- 29:58So this is the same as going on the
- 30:00website and pasting stuff in and you
- 30:03know they claim they're not training on
- 30:04the data.
- 30:05I will just say that like you know take
- 30:08that as you will and [snorts] it's of
- 30:10course these AI companies all have
- 30:12different views and different things and
- 30:14they say you know what's legal and
- 30:16what's not. So I would say be careful on
- 30:19things like this. I think this is an
- 30:21extent to which it's something you keep
- 30:22on Dropbox or Google Drive I think this
- 30:25is sort of risks are similar in terms of
- 30:26risk profile
- 30:28but
- 30:29um you know that's kind of the boundary.
- 30:31If it's something that is kind of
- 30:32uh you would need to be worried about
- 30:34that's you know something with IRB data
- 30:36for example I would wall that off in
- 30:37some way I would think about making sure
- 30:39like
- 30:40I What I mean by that if it's like um
- 30:41PII data that you really have to keep on
- 30:43like a HIPAA compliant server.
- 30:47You really should be not necessarily
- 30:49running it there. You should like have a
- 30:51different way of doing it. Try not to
- 30:53put in all your API keys or passwords.
- 30:55If you accidentally paste stuff into
- 30:56Claude, often it will say, "Hey, that's
- 30:58an API key. Don't do that. You need to
- 31:00delete that and start a new get make a
- 31:02new password." Um
- 31:05But it's just something to keep in mind
- 31:06that like
- 31:08there it's very much a thing that's
- 31:09there in the future I'll kind of talk
- 31:11about how to sandbox in a way that's
- 31:13similar to what co-work does, but you
- 31:14can have a lot of control over it and
- 31:15mount only the drives that you're
- 31:17interested in.
- 31:18Um I think in the interest of time we
- 31:21can kind of defer this a little bit to
- 31:22the just the slides that we'll post
- 31:24Marcus, but I just want to highlight
- 31:26that if you're a a person who wants to
- 31:28use the terminal, there's lots of nice
- 31:30ways to make the terminal look better.
- 31:32When you see in future videos, I'm going
- 31:33to be using something called Ghosty or
- 31:35Zellij, which are just ways of making it
- 31:37look better.
- 31:39Um
- 31:40And also ways of improving kind of your
- 31:42bash your basically your shell. I use
- 31:45something called Oh My Zsh, which is
- 31:47quite nice and just makes it a little
- 31:48friendlier, but none of these are
- 31:50requirements or policies.
- 31:51>> What is a shell thing different from the
- 31:53previous slide? So a shell is the shell
- 31:56is the underlying commands where you run
- 31:58things. So when you say something like
- 31:59CD for change directory, that's called a
- 32:01shell command and you're executing it.
- 32:04It's so Zsh or bash are two types of
- 32:08programs that run on either Unix or
- 32:11Linux or
- 32:13on a Mac.
- 32:15Windows doesn't use those, they use
- 32:16something else. Okay, so basically in
- 32:18terms of thinking about just to kind of
- 32:20sum up, if you want to you know, if you
- 32:22don't watch the next video and you want
- 32:23to just get started right away, things
- 32:25are just some tips to get started would
- 32:27be you know, be specific. I think it's
- 32:29helpful to kind of the same way that you
- 32:30tell an RA about how to be specific,
- 32:32you'd say, "No say analyze this data."
- 32:35It's going to say, "What data is it
- 32:36talking about? I'm going to look at all
- 32:37these CSVs." You could say, "I want you
- 32:39to load this file, calculate monthly
- 32:41growth rates by sector, and plot it at
- 32:42plot a time series of it."
- 32:45Um second, I would say like, you should
- 32:46iterate. You can do things, but don't
- 32:48necessarily argue with it. It's really
- 32:50kind of a waste. Um you know, saying
- 32:52something like, "Okay, take that graph
- 32:53and make the legend larger." That's
- 32:55fine.
- 32:56But, you know, if Claude is going in
- 32:58circles, I would cancel. So, typically
- 33:00in Claude code, that would be hitting
- 33:01escape to to interrupt it.
- 33:04And you can actually go back. Um you can
- 33:06hit escape again and go back in the
- 33:08context window to where you started and
- 33:10you said like, "Okay, this wasn't clear
- 33:11enough. Forget everything we just did
- 33:12for the last 2 minutes. Let's start
- 33:14again."
- 33:16I would make sure to like catch it early
- 33:18to tell what to do. If you start seeing
- 33:20it use something like Python instead of
- 33:22R or using R instead of Stata or what
- 33:24have you, you know, interrupt, tell it,
- 33:27and then say, "All right, keep going."
- 33:28It will fix itself.
- 33:30And I would, you know, trust what it's
- 33:32doing, but I would verify. I think it's
- 33:33very good. Like, it's a remarkable
- 33:35program
- 33:36um programmer, but it will make
- 33:38mistakes. And so, you know, you want to
- 33:40be kind of careful with edge cases is
- 33:42kind of the key thing. Like,
- 33:44you know, it's going to do stuff, but
- 33:46it's going to be very confident. So, you
- 33:47it definitely have to verify. Like, this
- 33:49is not a
- 33:50We'll talk about ways in which,
- 33:51especially from a data standpoint, you
- 33:52want to structure things so that you can
- 33:54easily check stuff. It's the same way if
- 33:55you have an RA work for you. You know,
- 33:57an RA can make stuff. You still have to,
- 33:59you know, it's going to be your work
- 34:01eventually. You have to trust it and
- 34:02verify in a number of ways.
- 34:04Okay, but when I want to use R or
- 34:06Python, I have to download it first, no?
- 34:08Yes, and it can do that for you or you
- 34:10can it can do the installation for you
- 34:12or
- 34:13um
- 34:14you can do it beforehand. That's one
- 34:15nice thing of using Claude code instead
- 34:17of something that's sandboxed like
- 34:18Claude co-work is that it's all in
- 34:20there. You are it's everything you
- 34:21already use. So, if you don't if, you
- 34:23know, say you use MATLAB instead, you
- 34:25say do it in MATLAB or whatever. Kind of
- 34:27it's irrelevant.
- 34:28>> But, it doesn't use some
- 34:29R in the cloud or something or Python
- 34:32>> No, it doesn't write on your computer.
- 34:33Okay. Yeah.
- 34:36So, let me kind of sum up um you know,
- 34:38what we covered. We talked about the
- 34:40different types of um ways that you can
- 34:42use things. So, Claude Code, which is
- 34:44you know, in your terminal, has full
- 34:46access to everything, your shell.
- 34:49We kind of contrasted this with other
- 34:51types of agentic things that you can
- 34:52use. Claude Co-work, which is this
- 34:54sandbox web environment, has sort of
- 34:56more limited access, um sort of more
- 34:59limited tools, but also it's going to be
- 35:00a much better entry point. And then
- 35:02these agentic um
- 35:04IDEs, like Cursor, which run inside the
- 35:07IDE, but are kind of access to files
- 35:09that are open inside it. But then the
- 35:11boundary's a little blurry there, but
- 35:12that's kind of a good way to think about
- 35:13it. Talk about how installation is very
- 35:15easy. It's kind of if you're already
- 35:17paying $20 a month, you should try it
- 35:19out right now.
- 35:20Talked about the context window. Talked
- 35:22about data privacy. I view it as kind of
- 35:24comparable to Dropbox, but you know,
- 35:26your mileage may vary. And we talked
- 35:28about what you do. I think the basic
- 35:30loop, you should think about it as
- 35:31describe what you want. Claude will
- 35:33write write and run code, and then
- 35:34you'll iterate on it subsequently. And
- 35:36what we're going to do next video is
- 35:38we're just going to talk about how we
- 35:39can do it. We can get some data from the
- 35:41web. We'll make a graph
- 35:43out of it, and we'll sort of see how we
- 35:44can make some really kind of interesting
- 35:45stuff, even if you don't really have an
- 35:48idea of where the stuff comes from. And
- 35:49so, it it kind of can be really
- 35:51powerful. So, with that, um
- 35:54we can stop right there. Thanks a lot,
- 35:56Paul. So, we're looking forward to the
- 35:58next
- 35:59little video
- 36:00to get really accustomed with all this
- 36:02Claude Code and Claude Co-work and
- 36:04whatever we can learn from you. Thanks.
- 36:06Great. All right, wonderful. Thanks for
- 36:08joining.
- 36:10Bye-bye.
- 36:11Bye.
- 36:27>> Mhm.
About this transcript
This page contains the full transcript of Getting Started: Claude Code for Economists with Paul Goldsmith-Pinkham | Markus' Academy | Ep.162-1 by Markus' Academy, generated from the public captions YouTube serves with the video. The transcript has 7,645 words across 1,131 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 choose a caption track available on the video.
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, caption language selection, AI prompts for ChatGPT, Claude, and Gemini, and exports to TXT, SRT, VTT, or Markdown.