Claude On Google Cloud
← All lessons
Lesson 27Claude On Google Cloud

Introducing tool use

Summary audio

Spoken summary — press play to read along: the line being spoken stays near the top.

Study notes

Tool Use in Claude: Study Notes

**I. Core Concepts**

  • Knowledge Limitation: By default, Claude's knowledge is limited to the data it was trained on. It generally lacks information about recent or current events.
  • Purpose of Tools: Tools enable Claude to access information from the outside world, overcoming its inherent knowledge limitations (e. g. , retrieving current weather).

**II. The General Tool Use Flow**

The process of using tools involves a multi-step interaction between the user, Claude, and external code:

  • Initial Request: The user sends a question or task to Claude.
  • Tool Instructions: The initial request includes instructions detailing how Claude can access external data (i. e. , how to use the tools).
  • Decision Phase: Claude analyzes the request and determines if external data is necessary to provide a complete answer.
  • Tool Call: If needed, Claude responds by requesting specific data, providing details on the required information.
  • Execution (Server Side): External code (running on a server) executes the tool/API call to retrieve the requested information.
  • Follow-up Request: The retrieved, real-time data is sent back to Claude in a follow-up request.
  • Final Response: Claude uses the original prompt plus the new external data to generate a final, improved response for the user.

**III. Example: Current Weather Retrieval**

  • Initial Query: User asks for current weather in a specific location.
  • Tool Integration: The initial prompt includes instructions on how to access a third-party weather API.
  • Action: Claude decides it must call the weather API.
  • Data Retrieval: The server runs code to contact the external weather API and fetch live details.
  • Augmentation: The live weather data is sent back to Claude.
  • Output: Claude generates a final response that is augmented with the up-to-date weather information.

Takeaways

  • Claude's knowledge is inherently limited to its training data, meaning it lacks information on recent or current events.
  • Tools enable Claude to overcome these limitations by accessing real-time information from the outside world.
  • The tool use process begins when Claude analyzes a user request and determines if external data is necessary.
  • If required, Claude requests specific data, which is then executed by external code on a server.
  • The retrieved external data is sent back to Claude, allowing it to generate a final response augmented with up-to-date information.
Flashcards 9 cards
Question
click to reveal · ←/→
Answer
click to flip back
Export to Anki (.tsv) ↓
Knowledge check 6 questions