1
00:00:00,440 --> 00:00:05,520
And so with this, we now turn to the other category, the second category of agents.

2
00:00:05,720 --> 00:00:13,320
So by contrast with the workflow patterns with agents, the process is more open ended.

3
00:00:13,440 --> 00:00:15,200
It's something that can keep going.

4
00:00:15,680 --> 00:00:17,320
It has feedback loops.

5
00:00:17,360 --> 00:00:24,240
It's typically a design that allows for information to come back and be processed multiple times.

6
00:00:24,520 --> 00:00:29,720
And importantly, there's no fixed path through the design pattern.

7
00:00:29,760 --> 00:00:35,440
It's not like there's a series of steps as we had in those prior patterns, but rather it's something

8
00:00:35,440 --> 00:00:37,400
that's fluid and dynamic.

9
00:00:37,520 --> 00:00:41,160
And as as a result, it's something which can be much more powerful.

10
00:00:41,360 --> 00:00:42,480
There's many more.

11
00:00:42,680 --> 00:00:48,960
There's a much greater kind of problem that could be taken on by this sort of agent pattern, but it's

12
00:00:48,960 --> 00:00:50,280
less predictable.

13
00:00:50,320 --> 00:00:56,920
And so there are absolutely concerns about robustness, about guardrails, about how do you get the

14
00:00:56,920 --> 00:01:03,320
best out of this kind of flexibility, but still have a system that can run in production and be guaranteed

15
00:01:03,360 --> 00:01:05,800
to complete in a certain time and so on.

16
00:01:06,600 --> 00:01:12,730
And this is the diagram that I would bring up, which is fairly generic kind of diagram that's just

17
00:01:12,730 --> 00:01:17,010
meant to show that you have the inputs and outputs now shown as a human.

18
00:01:17,010 --> 00:01:18,410
But but we don't really have output anymore.

19
00:01:18,410 --> 00:01:24,490
We have environment that's meant to reflect some, some sort of outside world that can be interacted

20
00:01:24,490 --> 00:01:30,210
with, such as the lights that I wore around me, that the human can make a request that goes to an

21
00:01:30,210 --> 00:01:30,730
LM.

22
00:01:30,850 --> 00:01:37,050
The LM is able to take actions on the environment, as you can see, and the LM is able to get back

23
00:01:37,090 --> 00:01:39,690
information from the environment in some way.

24
00:01:39,890 --> 00:01:42,730
And then this is simply a repeating loop.

25
00:01:42,770 --> 00:01:50,170
The LM can continually make other actions and get back feedback, and at such time as it desires, it

26
00:01:50,170 --> 00:01:51,330
can choose to stop.

27
00:01:51,570 --> 00:01:54,130
And so this is the the the diagram.

28
00:01:54,290 --> 00:02:01,970
And there aren't more specific design patterns because it is in itself this sort of open ended design

29
00:02:01,970 --> 00:02:02,650
pattern.

30
00:02:02,650 --> 00:02:05,730
It's saying this is a it's almost a sort of meta design.

31
00:02:05,730 --> 00:02:12,330
It's saying the the LM gets to choose its own design for how it's going to solve the problem.

32
00:02:12,570 --> 00:02:17,460
And that's really it's it's quite hand-wavy, but that's the way to distinguish it.

33
00:02:17,500 --> 00:02:23,420
If we look back at this pattern, I mean, this pattern arguably also could keep going forever.

34
00:02:23,420 --> 00:02:28,940
It's not as if this has a fixed stop, but there's clearly more certainty about what's happening for

35
00:02:28,940 --> 00:02:35,300
what reason than with the agentic patterns, where it is more fluid by its nature.

36
00:02:35,620 --> 00:02:43,500
So that's really the core idea behind the agent patterns, that there is much more flexibility that

37
00:02:43,500 --> 00:02:51,140
allows us to to be able to solve much more complex problems where Llms can really plot their own paths.

38
00:02:51,140 --> 00:02:56,940
But it does introduce some new issues, such as not knowing how long it will take before it will will

39
00:02:56,980 --> 00:03:01,700
complete its task, not knowing whether it will complete its task at all, not knowing what kind of

40
00:03:01,700 --> 00:03:05,260
quality outputs we will get, and not knowing how much it will cost.

41
00:03:05,300 --> 00:03:11,740
These are all the kinds of challenges that agent developers like ourselves need to face, and they are

42
00:03:11,740 --> 00:03:15,020
the sorts of things that we will be tackling in the coming weeks.

43
00:03:15,740 --> 00:03:20,240
And so if this feels a bit unsatisfying that the design patterns for workflows are so clear.

44
00:03:20,240 --> 00:03:22,760
And now this looks just so loose.

45
00:03:23,000 --> 00:03:29,200
Then all I can say is, as we put this into practice, as we code different real agent environments,

46
00:03:29,200 --> 00:03:33,400
this is going to become more and more concrete, and you're going to be able to you'll see this as second

47
00:03:33,400 --> 00:03:34,560
nature before too long.

48
00:03:34,880 --> 00:03:40,680
Now let's just quickly say a few more words about some of the drawbacks that I alluded to a second ago

49
00:03:40,720 --> 00:03:45,480
with using agent frameworks and agentic AI and design patterns.

50
00:03:45,800 --> 00:03:49,680
So obviously there is this sense that you have an unpredictable path.

51
00:03:49,720 --> 00:03:55,320
You don't actually know what order tasks will take place in or even what tasks will happen.

52
00:03:55,920 --> 00:03:58,120
You don't know what the output will be.

53
00:03:58,200 --> 00:04:00,840
There's no guarantees that you're going to get a great output.

54
00:04:01,000 --> 00:04:07,800
Now, this this whole Agentic architecture allows us to take on much bigger, harder problems than we've

55
00:04:07,800 --> 00:04:09,280
ever been able to take on before.

56
00:04:09,600 --> 00:04:16,200
But it does have this inherent uncertainty associated with giving Llms autonomy over how they tackle

57
00:04:16,200 --> 00:04:16,880
problems.

58
00:04:17,360 --> 00:04:19,160
There's also unpredictable costs.

59
00:04:19,160 --> 00:04:23,240
I alluded to that as well a moment ago, but because you don't know how long it's going to take, you

60
00:04:23,240 --> 00:04:29,810
don't know how much it's going to cost in terms of running the APIs and potentially building up a big

61
00:04:29,810 --> 00:04:30,330
bill.

62
00:04:31,370 --> 00:04:36,610
And so as a result, there's a couple of mitigations that are incredibly important, both of which we

63
00:04:36,610 --> 00:04:39,170
will spend plenty of time on in the coming weeks.

64
00:04:39,410 --> 00:04:45,290
One of them is, of course, monitoring, being sure that you have the kinds of visibility into what's

65
00:04:45,290 --> 00:04:51,650
going on behind the scenes so you can understand what's going on with your models, with their interactions,

66
00:04:51,650 --> 00:04:55,690
particularly when you have potentially many agents all interacting.

67
00:04:55,730 --> 00:04:57,930
And we're going to see that with open AI SDK.

68
00:04:57,970 --> 00:05:02,730
We're going to see that the trace, the ability to to watch different agents interacting.

69
00:05:02,730 --> 00:05:06,010
When we look at a graph, we're going to see Lang Smith their tooling.

70
00:05:06,010 --> 00:05:11,690
So we're going to see a lot of the ways that you can have this visibility into what is going on under

71
00:05:11,690 --> 00:05:13,370
the hood in your agent systems.

72
00:05:13,690 --> 00:05:15,410
And then guardrails.

73
00:05:15,450 --> 00:05:22,290
Guardrails is the name for the kinds of protections that you can write in software that makes sure that

74
00:05:22,290 --> 00:05:27,610
your models are doing what they should be doing, or that they're not sort of leaving some, some constraints,

75
00:05:27,650 --> 00:05:29,690
some, some rails that you put in place.

76
00:05:29,930 --> 00:05:35,860
And in fact, that quote that I put here comes straight from the OpenAI agents SDK, which has a ton

77
00:05:35,900 --> 00:05:42,300
of functionality dedicated to guardrails, and they say that it ensures they behave safely, consistently

78
00:05:42,300 --> 00:05:44,820
and within the boundaries that you wish.

79
00:05:45,060 --> 00:05:49,860
And so we will be building those guardrails ourselves in week two.

80
00:05:50,540 --> 00:05:54,300
And with that, that does actually conclude the day.

81
00:05:54,340 --> 00:05:58,580
Two lectures, as I promised you, it was shorter than day one.

82
00:05:58,620 --> 00:06:00,620
And I hope you didn't mind that we covered a lot of theory.

83
00:06:00,620 --> 00:06:03,500
It's really interesting stuff, these gigantic design patterns.

84
00:06:03,500 --> 00:06:09,420
I hope now you've got some clarity on what agents are and that there is ambiguity on this, but but

85
00:06:09,460 --> 00:06:14,580
ways that you can talk about it and think about what it means to be autonomous and what it means to

86
00:06:14,580 --> 00:06:16,980
be able to plot your own path.

87
00:06:17,140 --> 00:06:21,180
Let let an LLM decide the path that things will take.

88
00:06:21,540 --> 00:06:25,940
And so with that, congratulations on completing day two and day three.

89
00:06:25,940 --> 00:06:28,300
We're going to talk about orchestrating Llms.

90
00:06:28,300 --> 00:06:31,180
It's going to be more and more coding, more hands on, which will be fun.

91
00:06:31,180 --> 00:06:34,980
We're going to build with a lot of APIs and get ready for that.

92
00:06:34,980 --> 00:06:37,940
And after that we're going to move on to tools.

93
00:06:38,140 --> 00:06:39,700
So I will see you next time.