Intro0:00
Okay, I'm getting rolling, and uh, welcome aboard. We've just had a little technical issues, but we resolved them. So, my name is Frank Coyle. I am a computer science guy, I've been teaching computer science for over 30 years, and I'm now teaching at Berkeley.
And one of the problems that all my students past and present are having is AI, because computer science is no longer the magic pathway to a job. So I've been trying to figure out ways to help them, come up with schemes to help them get ready for this world of agentic AI.
And one of the things that sort of dropped into my plate was the something called the Claude Certified Architect exam, which I will be talking about today, and it has a number of aspects to it. And I think if you're interested in a career in agentic AI, then certainly take a look at least what the exam is about, because I feel that Anthropic knows how people are using their system and what the issues are going to be.
So before we jump into that, I want to give a little bit of my philosophy.
Philosophy1:20
Whoop, whoop, whoop.
I may have to do this manually, I'm getting stuck. So, this is a quote from a woman named Sister Corrida Kent: "Nothing is a mistake, there's no win and no fail, there's only make." Bottom line here is experiment, experiment, experiment.
Not only should you read, but you should do, you should make stuff. Now, what happens when you make stuff? A lot of times things don't work. Thomas Edison said, "I have not failed, I've only found 10,000 ways that don't work."
And what I want to emphasize here is that what this shows us are something that in the design patterns movement, which came around in the early 1990s with object-oriented programming, we had patterns for objects, we now have patterns for agents, but there's also anti-patterns.
And I think anti-patterns are a key to understanding what you should not do, because understanding what you should not do is the key to leading you to what you should do.
So, a little bit about the Claude Certified exam. Released in March, so it's brand new. It is based on scenarios, it is timed, it is proctored, it is available to companies in the Claude ecosystem, the Anthropic ecosystem, but individuals can pay $99 and take the exam once every six months.
Exam Overview2:45
And it's not just multiple choice questions, it is multiple choice, but they are based on realistic constraints and realistic scenarios. The five domains. There are five domains that are covered, and they give you the percentages of each. So agentic architecture, 27%.
Claude code, how to configure the Claude code system and workflow, 20%. How to do prompt engineering, structuring your output using JSON all over the place. Tool design, model context protocol integration. These are topics that you should understand and know whether you're going to take the exam or not.
This is going to help you get ready for whatever the agentic world is going to throw at you. And then there's going to be contact management and reliability. So these are the areas of the kind of questions you're going to run into.
Then there are, and they provide you with six production scenarios, and your exam will randomly choose four, and all the questions will be centered around the four that they choose. And what I'm going to do is walk you through
the production scenarios and give you some anti-patterns to be aware of, because there's a number of ways you can solve the problem, but one of the big things is what not to do, and that often can be the key to getting these questionsright.
So, number one, customer support resolution agents. So we have agentic loops control, something called stop reason, which is what Claude code has. Every time something happens, there's a stop reason, and you need to take a look at that because that can give you a lot of information about what's going on.
Scenarios4:48
Scenario two, code generation. Three, multi-agent research system, which we'll look at. How do you distribute your agents? How been spoke, who's the orchestrator, how much information should they know? All these are important factors. Scenario four, developer productivity with code.
So how do you do subtask isolation, keep your tasks in their little universes? And this harkens back to what we learn in computer science from doing multi-threaded programming. When you have multiple threads operating and sharing memory, then you get into issues with synchronization, you got to put locks in, keep the little threads independent, keep your agents independent.
And then some Claude code for continuous integration, and then we'll look at some patterns for structured data extraction. Okay, that's kind of where we're going to go. Now, here's something that I like to point out. Everybody's talking about loops,right?
Loops5:55
The loop is the new thing.
Boris Cherný says he doesn't write code, but his job is to write loops. And Peter Steinberger, master of Open Claw, says, "I don't code anymore, I just design loops that prompt your agents." So loops are the new big thing,right?
Well, no, they're not. Okay? Back in the day, early days of computing, we had programming languages were exploding. We had Fortran, we had COBOL, and there were big fights. My programming language is better than yours. It can do more.
No, it can't. We can do this. Beam and Jacopini, 1966, proved that if you want a language to be turn complete, which means can compute anything that computers are possibly able to compute, then you need only three things.
The ability to write statements sequentially, okay? To have if-then conditionals, and the third piece is the loop. If you add the loop, you have Turing computability. And now we are seeing this being resurrected in the agentic world with the focus on loops, because up to now we've had sort of sequences, you have prompts, you have maybe if-then, but now we have a loop.
And now this is what's giving us the power. This is where the agentic stuff is getting very exciting. Okay, let's start with scenario one, customer support resolution. So here we have
Stop Reason7:55
a loop operating, and I'm going to jump to the anti-pattern. What you don't want is just to let the agent go and do something and get the response back and use it, okay? What you want to do is you want to loop with something called the stop reason.
So I'm going to show you a little code here. So here we have while loop, it's a while true, it's a loop. We're loopingright here, okay? So the first little block is where we call the model, okay? And we pass it the messages.
The messages are essentially the sequence of prompts that exist in the context window, okay? And we are asking the, and we have a prompt, and we have the context, and we have a tool. And we're asking the LLM to do something with this tool and help us out.
The problem is the LLM can't do anything. It is just a probabilistic next word predictor. It can't execute tools. So what it does, though, is it can figure out. If you point it to a tool, it can figure out how to set things up so that you or your code can execute it.
So it's important to understand that the LLM is not executing these tools. It can't do anything except talk back to you, very intelligently sometimes, but all it can do is talk back to you. So when it finishes this task and has a result, which is basically, here is, I know what you want, I know what the tool can do, here's how it sets up the parameters that can then be used to actually execute the tool.
So this second block, you see, why did the LLM come back to us? That's our stop reason. Tool use. Oh, okay. We've stopped because the LLM wants to use the tool. So let's just run the tool. So that's what this second block is.
Run tool. The response is what the LLM said, and it's basically the parameters that it has extracted from the data that you provided it, okay? Then it executes that. Then it goes back, then it continues. Continues means the LLM sees it, says, "Oh, successful run."
So okay, come back down. We're not running a tool anymore. We're ended our loop. Bingo. Now, then we take the answer, and this is an opportunity for you to have a human in the loop potentially. You check the confidence.
If it looks good, you keep it. If you don't, then you escalate to a human. So, now there's another reason why you need to make sure you check your stop reason. One of the stop reasons may be you have run out of tokens, and this response is based on partial when the LLM had to stop.
And it's going to give you a response, but if you have run out of tokens, then you need to take action. Okay,
next scenario. Code generation with Claude. So Claude code has this concept of the Claude MD file, a markdown file where you put all the things you wanted to know. What Anthropic recommends is you have three levels of Claude.
Code Generation11:16
One, that you have at the top level of your project. The other, that you have inside your sort of the project folder, and then within directories you can also specify. So the idea is to have a hierarchical set of rules that then control how the system is going to respond.
Okay, movingright along. We have a multi-agent research system. So here we're going to have, the problem is, how do I get my agents to go off and do stuff and bring the answers back in a reasonable way? The anti-pattern, you have one agent and you load it up with tools, allright?
Multi-Agent12:10
So I like to think about, you hire somebody to come to your house, you hire a carpenter to come to the house, and the guy shows up with
plumbing tools, carpenter tools, electrical tools. He says, "I can do anything." Well, maybe you don't want this guy, maybe you want a professional carpenter. So that's the kind of idea. And this kind of takes us back to some of the functional programming ideas that functions should be do one thing.
And if you can get your agents to do one thing, with maybe one or two tools available to it, then that's going to be a win, and that's going to help you with this exam. So specialize, don't overload.
The other part of this is don't let your agents' context spill over into the main context, because context means tokens, tokens mean money, and the more context you have, the more confused the LLM is going to be in giving you an answer.
So even though, "Oh, a million token context window, I can put everything in there." No, no, don't put everything in there. Limit what's going to go in there, because then you're going to get a much more accurate system.
So here's
an example of a specialized sub-agents. You're giving it, so this would be the critic. So let's say you've run some stuff, now you want to get an agent to look at what's happened. What you want to do is just give it what it needs to solve that critic problem.
I'm only giving it here, we're passing it the claim and the evidence. So your claim is sort of how we're going to solve the problem. Here's the evidence, but you're not giving it the thought processes that went into creating this claim.
Why?
When you get a bunch of agents together, collaborating and talking to each other, there's a tendency to have group think, and all the agents seem to kind of devolve into one idea. I mean, it's like you're in a group, you're at a party, and everybody wants pizza except you, but then people talk you into,
you don't want to be, you don't want to spoil the party, so you go along. And it seems that agents kind of work in the same way. So you're going to return, basically you're going to give each agent only a slice.
I didn't think about the pizza analogy, but yes. Every agent gets its own slice, and it should come through. Okay,
Context Isolation15:17
fourth scenario. Developer productivity. So the anti-pattern, let every subtask dump its full output into the primary thread, crowding out the context. Again, this is what I was just talking about. This is bad. Let the context grow unbounded, bad,right, for the reasons we just talked about.
You want to isolate your subtask output, and you want to compact long sessions. I'm going to take a second to talk about that. So here's
an example of a pattern. You want to have your agent
look at the logs and create a summary of where the problems are in the log. So here's your task, scan all the logs for error. Context fork. So you're forking the agent into a separate thread where whatever the agent does and thinks and adds tokens to does not come back and pollute
the main context. Now, you see here what happens, then you take this summation, and then you add that summation without all the other stuff into the overriding context. Now, this last little block is kind of interesting, I think, because you can check your token count, and you can determine how big the token count is.
And if you can set some limit, if you have more than 150,000 tokens, then what you want to do is you can run a compact. So Anthropic and Claude have these compaction algorithms that take this giant context and compact it in some way, shape, or form.
Not quite sure how the implementation is of that, but there is compaction. Now, a little side effect, a little side channel. I've been walking around, when you walk outside, you see these guys handing out these books, okay? Anybody see these guys handing out these books?
Take them. This is actually a pretty good little book. In fact, I was looking at it last night, and one of the things it had in it was, this is by this guy, Sam Bagwa. I have no connection, I don't even know Sam, but there's an online page 32.
It says, his company provides custom logic for compression of context. So he's got an app, and you can write your own. You can extend his base class and have your own compression of your data, whatever you think is important.
So I think that's kind of an interesting spin on this whole thing. Okay,
CI & Batch18:10
Claude code for continuous integration.
Anti-pattern, always have interactive modes in a pipeline. Well, no, no, no, because interactive modes mean
Claude will stop and ask you, you want to do this, you want to do that, can I have permission for that? So there are ways to set it up so that it'll just run straight through, okay?
The other tip that I'll give you here is there's something called the batch. So you can take your prompts, you can take your work, and you can put them in a batch, and for 50% fewer token cost, you'll get the result they promise in at least 24 hours.
So if you're going to go take a nap, you're going to go on vacation, you're going to go out, take a day off, run your stuff in batch mode, and you're going to have less to pay.
Conclusion19:14
Where am I here? Allright, I've only got a few minutes left, a few seconds left, but I want to conclude with this. Remember, nothing is a mistake. There's no win, there's no fail, there's no exam. Only make. You do it, and you make it, and you're going to succeed.
If you want to reach out to me, reach out to me, Coyle at Berkeley. Look at my websites. I got a website, code supreme AI. I'm a big jazz fan, and I named this website after John Coltrane. Love Supreme, if you know that song.
Great. Anyway, that's my story, and I'm sticking to it, and I'm back to zero time. Okay, thank you.





