📱

Get Our Mobile App

Take your business learning on the go!

Download on the App StoreGet it on Google Play

How Claude Does Web Search?

KodeKloud1:38

Transcription

How exactly does Claude or chat GPT search the web? When you ask Claude or chat GPT some question, there is a status line that shows up and it says, "Searching the web, running code, etc." Do you think the AI model is actually making these web search calls?

The answer is no. The AI model doesn't do the web search or make API calls by itself. And the real answer will change how you look at every AI product out there.

Claude has a large language model, let's say Opus. And when you prompt it, the model does exactly one thing. It reads your prompt and it writes text back. It physically cannot open a connection to the internet.

So, how does the web search happen? Let's take a real example. You ask Claude, "What's the weather in Amsterdam right now?" The model doesn't know the current weather because it was probably trained months ago. But the model does know one useful thing, that a tool called web search exists and it is available. How does it know the web search exists? Because the Claude application told it.

So, the model writes a small structured note that says, "Please run web search with the query Amsterdam weather right now." At this point, nothing has actually happened. That note is just text.

This text lands in Claude's infrastructure. And Claude's infrastructure is normal software running on real servers. It can make web searches and API calls like any other program. So, the infrastructure reads the model's note, makes the real search request, and gets back the results. The infrastructure converts those results back into plain text and returns that text to the model as part of the conversation.

Now, the model reads that text and picks out the important information that matters to you, 21° and cloudy, and writes the final answer back to you.