WEBVTT

00:00.200 --> 00:06.880
And now, as it says, we are going to create our agent using these tools.

00:07.440 --> 00:13.760
So you may remember that when using OpenAI agents SDK instructions is what they call the system prompt.

00:13.960 --> 00:18.160
So we're going to say you browse the internet to accomplish your instructions.

00:18.160 --> 00:25.760
You are highly capable of browsing the internet independently to accomplish your task, including accepting

00:25.760 --> 00:29.880
all cookies and clicking not now as appropriate to get the content that you need.

00:31.400 --> 00:33.520
If one website isn't fruitful, try another.

00:33.560 --> 00:36.000
Be persistent until you've solved your assignment.

00:36.040 --> 00:38.880
Try different options and sites as needed.

00:39.240 --> 00:42.480
Okay then, I've got this as before.

00:42.480 --> 00:50.440
So this is going to create an MCP server, an MCP client, and an MCP server for file management file

00:50.440 --> 00:52.480
parameter passing in the file parameters.

00:52.680 --> 00:55.120
And then the same with the playwright parameters.

00:55.120 --> 01:00.400
So we now have a bunch of these different, uh, sets of tools.

01:00.440 --> 01:03.120
I'm using a parameter cache tools list.

01:03.280 --> 01:08.440
And as, uh, as OpenAI explains in their documentation, that just means that every time you call an

01:08.440 --> 01:12.480
agent, it's not going to re go and reestablish the tools, but it will remember them.

01:12.480 --> 01:17.240
So that's a sort of a best practice if you're using a service where the tools aren't going to change

01:17.560 --> 01:18.240
all the time.

01:18.840 --> 01:21.080
So uh, we're then going to create an agent.

01:21.080 --> 01:22.960
You remember this agent?

01:23.200 --> 01:25.800
Uh, we give it a name investigator.

01:25.960 --> 01:29.160
We give it some instructions, which is the system prompt.

01:29.160 --> 01:30.160
We give it a model.

01:30.160 --> 01:31.680
We'll use GPT four and mini.

01:32.120 --> 01:33.160
And this is new.

01:33.720 --> 01:35.640
Lo and behold, we're not we're not passing in.

01:35.640 --> 01:38.240
We could just pass in the tools that we already got earlier on.

01:38.240 --> 01:39.600
But we're not going to do that.

01:39.640 --> 01:46.480
We're going to pass in these MCP servers that we have, uh, that we've created one for files and one

01:46.480 --> 01:52.320
for browser, and we are passing them in as our MCP servers to use right here.

01:53.280 --> 01:57.440
And then with trace investigate.

01:57.440 --> 02:00.640
So, so, uh, we're setting up a trace called investigate.

02:00.680 --> 02:03.680
We will then call runner run.

02:03.960 --> 02:05.560
Uh, if you remember, run and run.

02:05.560 --> 02:06.960
It seems so long ago that we did this.

02:06.960 --> 02:13.000
But runners run, which is the OpenAI agents SDK way of sending a prompt to an agent.

02:13.240 --> 02:20.200
I'm going to say find a great recipe for banoffee pie and then summarise it and write it to banoffee.

02:22.240 --> 02:24.080
And print the final output.

02:24.120 --> 02:24.720
What do you think?

02:24.760 --> 02:30.520
Is this is it going to be this simple to have hooked up two MCP servers, one for browsing the web,

02:30.520 --> 02:35.520
and it's going to try and run it in a browser and one for writing a file.

02:35.720 --> 02:40.240
So it's off and running and it's thinking about what it's going to do.

02:40.360 --> 02:41.800
And up comes a browser.

02:42.640 --> 02:45.000
I can see it's looked for banoffee pie down there.

02:45.680 --> 02:47.760
We'll give it some time to think it through.

02:49.520 --> 02:50.480
And there we go.

02:50.480 --> 02:51.440
It's finished.

02:52.480 --> 02:57.800
It has, uh, announced it's created a markdown file for the banoffee pie recipe.

02:57.840 --> 02:58.960
Do you know what banoffee pie is?

02:58.960 --> 02:59.440
If you don't?

02:59.480 --> 03:00.320
It's delicious.

03:00.360 --> 03:00.600
It's.

03:00.640 --> 03:01.760
I think it's English.

03:01.960 --> 03:06.240
And, uh, hopefully this this, uh, recipe will give you a good way to do it.

03:06.720 --> 03:09.280
Uh, and, uh, there we go.

03:09.320 --> 03:10.840
We've got our banoffee pie recipe.

03:10.920 --> 03:16.040
It got there, of course, by surfing the web and by writing files.

03:16.040 --> 03:22.080
And it did that by spawning two different processes on my computer.

03:22.080 --> 03:24.760
One of them was an NTP server for file management.

03:24.760 --> 03:28.000
One of them was an MCP server for browser management.

03:28.000 --> 03:31.360
It spawned them by running these commands for browser.

03:31.360 --> 03:35.520
It was running node for this and for the file management.

03:35.920 --> 03:40.400
It was also running node with with this server file system.

03:40.400 --> 03:44.920
So it ran both of those programs and then it communicated to them.

03:44.920 --> 03:49.320
But it did so just by providing tools to the LM to select from.

03:49.320 --> 03:50.680
So all of that happened.

03:50.720 --> 03:52.720
It followed this entire workflow.

03:52.840 --> 03:57.880
And if we look in my sandbox directory, no surprise there is indeed a banoffee.

03:58.920 --> 04:05.120
And if we bring that up, we have a banoffee pie recipe that has been written to my hard drive through

04:05.280 --> 04:13.160
the MCP server file tools after searching the web using a browser that it spawned on my computer.

04:13.640 --> 04:20.760
And that is our first our inaugural use of a couple of MCP servers running locally.

04:21.000 --> 04:23.480
Uh, and I hope you are impressed.

04:23.480 --> 04:30.560
And you may remember that OpenAI agents SDK traces what you do because we we wrapped it in a with trace,

04:30.800 --> 04:33.040
uh, when we, when we called this right here.

04:33.040 --> 04:37.360
And as a result, we can go to the OpenAI platform page and look at our trace.

04:37.560 --> 04:38.760
And here it comes.

04:38.920 --> 04:41.280
The investigator is what we called it.

04:41.280 --> 04:47.960
And you can take a look through and see how it calls the MCP tools for both sets of MCP servers.

04:47.960 --> 04:52.400
And then it makes use of both the browser tool and the file tool.

04:52.400 --> 04:55.600
And you can look through the trace of how that happens.

04:56.120 --> 04:56.480
All right.

04:56.480 --> 05:01.320
So just in case you weren't super impressed by that, maybe you found it anticlimactic.

05:01.760 --> 05:06.600
Let me now reveal what it is about this that makes it so exciting.

05:07.040 --> 05:15.630
It's about the community of MCP servers and how easy it is to access a massive, diverse array of different.

05:15.670 --> 05:19.390
MCP servers out there and just drop them into your project.

05:19.510 --> 05:23.950
So here, for example, are some MCP marketplaces which are just sort of.

05:23.990 --> 05:28.270
Hubs where you can look at different MCP servers that people are offering.

05:28.510 --> 05:31.190
And MCP is one of them.

05:31.350 --> 05:37.790
It's a place where you can find awesome MCP servers, and it has 7200 of them right now, and maybe

05:37.790 --> 05:38.670
more when you look.

05:38.710 --> 05:43.950
It includes the playwright MCP we just looked at from Microsoft, but you'll also see a bunch of others

05:43.950 --> 05:44.230
here.

05:44.230 --> 05:45.710
Something that connects to blender.

05:45.910 --> 05:47.910
Perplexity something.

05:47.950 --> 05:48.750
Let's have a look.

05:48.790 --> 05:50.670
Let's keep going for something that looks interesting here.

05:50.710 --> 05:53.350
GitHub fetch is one that we know, of course.

05:53.670 --> 05:57.790
Um, and uh, there's something that we'll look at the time and time zone.

05:57.790 --> 06:05.630
That's a simple one, a file system, one we know about slack, GitLab, uh, and uh, lots of other

06:05.830 --> 06:13.470
useful MCP servers that you'll see here are whether one to the example that I gave before.

06:13.910 --> 06:16.470
Uh, so much to explore.

06:16.710 --> 06:19.390
So you should come in and look at some of these.

06:19.430 --> 06:24.870
I've got there's another one called glamour II, which has a ton of these MCP servers as well.

06:24.870 --> 06:28.950
This is very popular and it rates them for security license and quality.

06:29.150 --> 06:30.910
And so it's a good way to look at them.

06:30.910 --> 06:35.430
You'll also see there's a way to filter down for the ones that can run remotely, of which there are

06:35.430 --> 06:36.870
just 400 out of there.

06:36.990 --> 06:38.510
Is it 3000 that they have here.

06:38.510 --> 06:39.830
Yeah, 3300.

06:39.950 --> 06:44.990
Uh, so, uh, but but that gives you a sense of what it's like to use a remote MCP server.

06:45.270 --> 06:48.430
But there's lots of stuff here to look at.

06:48.710 --> 06:52.710
And to show you one more Smithery is a popular one.

06:53.070 --> 06:58.190
And here it has it, 4000 MCP servers available here.

06:58.190 --> 07:00.750
And any one of these if you come into them.

07:00.990 --> 07:03.670
Let's find this memory bank one here.

07:03.870 --> 07:06.990
Uh, it's, uh, you'll be able to read about what it does.

07:06.990 --> 07:09.270
You'll be able to read about its tools.

07:09.550 --> 07:14.190
Uh, and so that that is another example of how you can use these.

07:14.550 --> 07:16.150
Um, and if, um.

07:16.150 --> 07:24.190
Yeah, let me let me show you if we're, if we're on something like, um, MCP and we go into the playwright

07:24.510 --> 07:27.150
Mcp1 right here, up it comes.

07:27.190 --> 07:31.710
It gives you the full description of how to use it here as well.

07:32.070 --> 07:35.310
And you can flip over to see the content.

07:35.310 --> 07:37.550
This is this is how you would configure it.

07:37.550 --> 07:43.550
So these are this is the command and the args exactly as we specified it in our code.

07:43.830 --> 07:46.270
And here are the tools that it uses.

07:46.270 --> 07:52.670
So this gives you such a simple way to navigate around a MCP server marketplace.

07:53.110 --> 08:00.030
And then finally I have a link to a great article, a blog post, and Hugging Face community blog,

08:00.310 --> 08:07.270
uh, by someone that talks about, uh, the MCP server marketplaces, why they're big right now, why

08:07.270 --> 08:10.230
why how MCP works, why it's it's so huge.

08:10.510 --> 08:13.110
Uh, and, uh, is is well worth a read.

08:13.110 --> 08:17.390
And I'll put there's another blog post I like that lists out a bunch of different servers.

08:17.390 --> 08:18.790
That's also worth looking at.

08:18.790 --> 08:21.470
So do take a read through these.

08:21.670 --> 08:22.470
Oh, I already did.

08:22.510 --> 08:22.750
Sorry.

08:22.750 --> 08:25.190
This is this is the this is the MCP libraries.

08:25.190 --> 08:29.110
Let's list out MCP and Smithery that we just looked at.

08:29.110 --> 08:32.590
And then a bunch of others that are all worth checking out.

08:33.350 --> 08:35.670
So yeah, two two links to hugging face.

08:35.670 --> 08:37.990
The first is the top MCP servers.

08:37.990 --> 08:44.270
The second is a great community article that talks about what makes MCP so, so popular right now.

08:44.310 --> 08:46.110
What there is to love about it.

08:46.110 --> 08:48.150
But I hope I've given you a good impression.

08:48.150 --> 08:55.910
It's not necessarily that just writing connecting to one MCP server is going to to necessarily show

08:55.910 --> 08:56.950
you the power of this.

08:56.990 --> 09:02.790
It's about how many of them there are, how easy it is just to drop one in with the parameters that

09:02.790 --> 09:03.510
you set.

09:03.550 --> 09:04.310
Just like this.

09:04.310 --> 09:08.630
You set the parameters and then you can just use an MCP server.

09:08.710 --> 09:15.550
It will run typically locally on your box and give you access to a new set of tools, potentially tools

09:15.550 --> 09:18.910
that it's calling to the cloud to do if it's looking for the weather.

09:18.910 --> 09:24.670
But they're tools that are typically running locally on your box and that that is MCP.

09:25.030 --> 09:29.990
And that concludes the first lab of the first day of week six.

09:30.030 --> 09:34.670
And if you're thinking it's a bit of an anti-climax, is that all it is to MCP.

09:34.870 --> 09:35.990
The answer is yes.

09:36.030 --> 09:37.550
And that is the point.

09:37.550 --> 09:38.590
That is all.

09:38.630 --> 09:40.670
MCP is it's really simple.

09:40.670 --> 09:41.590
It's really easy.

09:41.590 --> 09:47.150
It's a few lines of code, and then you suddenly have access to a new set of tools that somebody else

09:47.150 --> 09:47.790
wrote.

09:47.790 --> 09:51.550
And there are thousands of these tools that you can bring them all in.

09:51.550 --> 09:56.670
And during the rest of this week, indeed, we'll work with a zoo of different tools and we'll take

09:56.670 --> 09:58.710
great advantage of all of them.

09:58.910 --> 10:02.510
And that's what makes it so exciting and so fun.

10:02.510 --> 10:05.070
And it's partly because it is so simple.

10:05.510 --> 10:11.230
And with that, that concludes the first day of week six.

10:11.470 --> 10:18.230
And tomorrow we will get into actually building our own MCP server and building our own client.

10:18.990 --> 10:20.110
And it's going to be great.
