Anthropic’s Claude 3 Opus and tool use are generally available on Vertex AI

In April, we made Anthropic’s most intelligent model, Claude 3 Opus, available in public preview on Vertex AI Model Garden for customers to start experimenting with. Now, we’re announcing that Claude 3 Opus is generally available on Vertex AI. We’re also excited to announce that tool use is available for all Claude 3 models on Vertex AI, helping to enable more agentic workflows, and provisioned throughput is now available for enterprise-grade reliability and performance.

The addition of Claude 3 Opus represents a milestone, with the entire Claude 3 model family — Opus, Sonnet, and Haiku — now generally available on Vertex AI.

  • Claude 3 Opus: Anthropic’s most capable and intelligent model yet, ideal for navigating complex tasks like in-depth analysis, research, and task automation.
  • Claude 3 Sonnet: Anthropic’s best combination of skills and speed, ideal for scaled AI deployments like powering intelligent virtual assistants and chatbots.
  • Claude 3 Haiku: Anthropic’s fastest and most compact model, ideal for applications requiring rapid responses and efficient resource utilization.

Opus use cases across industries

Claude 3 Opus is designed to tackle complex tasks with remarkable comprehension and fluency. Some example applications include:

  • For financial institutions, Opus enables advanced market analysis, sophisticated financial modeling, automated compliance processes, and robust risk management strategies.
  • In the life sciences field, Opus accelerates drug discovery through literature synthesis, expedites research into novel patient treatments, and generates hypotheses for exploration.
  • Across internal operations, Opus facilitates the migration of entire legacy codebases, automates common workflows and tasks, and enhances productivity through seamless process automation.

Assured performance with provisioned throughput

Vertex AI now offers provisioned throughput for Anthropic’s Claude 3 models, enabling a subscription-based pricing model with guaranteed performance and cost predictability. The existing pay-as-you-go option remains available. Provisioned throughput provides:

  • Assured capacity and performance: Reserve the required throughput (tokens/sec) with the confidence of Google-backed availability and prioritized execution for consistent low latency.
  • Predictable costs: Fixed pricing simplifies budgeting and forecasting for AI workloads. 
  • Flexibility: Combine provisioned throughput for baseload capacity with pay-as-you-go for excess demand, optimizing cost and performance. 

To get started with provisioned throughput, please contact your Google Cloud sales representative.

Tool use: extending Claude’s capabilities

Tool use, also known as function calling, allows foundation models to autonomously interact with external data sources, APIs, and other tools. This enables Claude to act as an autonomous agent, reasoning about which tools to leverage and executing sequences of tool interactions to accomplish complex goals that may require real-time data or computations.

For teams that want more control and flexibility in defining how Claude uses tools, you can use:

  • Tool use streaming: Build more engaging, human-like interactions by reducing perceived and actual wait times for end-users.
  • Forced tool use: Instruct Claude to reliably select the appropriate tool in various scenarios, including whether to use any tool, always use one, or use a specific tool you define.
  • Vision: Tools work with images. You can instruct Claude to consistently follow a predefined format when working with images, or incorporate image inputs as part of a live assistant and chat application. 

Tool use, meet Google APIs

Developers can now harness the power of the Claude 3 models and combine it with external tools including the capabilities of Google’s extensive collection of APIs and services. The example below shows how to provide the Google Places API as a tool to Claude, enabling the capability to search for nearby restaurants based on price and open hours.

The code sets up the AnthropicVertex client, defines the Google Places API tool with its input schema, and then sends a message to Claude instructing it to use the provided tool to find affordable and good Italian restaurants that are currently open in San Francisco.

from anthropic import AnthropicVertex

MODEL = "claude-3-opus@20240229"
PROJECT_ID = 'your-project-id'
REGION = "us-east5"

client = AnthropicVertex(region=REGION, project_id=PROJECT_ID)
response = client.messages.create(
    model = MODEL,
    max_tokens = 1024,
    tools = [
      {
        "name": "text_search_places_api",
        "description": "returns information about a set of places based on a string",
        "input_schema": {
          "type": "object",
          "properties": {
            "textQuery": {
              "type": "string",
              "description": "The text string on which to search"
            },
            "priceLevels": {
              "type": "array",
              "description": "Price levels to query places, value can be one of [PRICE_LEVEL_INEXPENSIVE, PRICE_LEVEL_MODERATE, PRICE_LEVEL_EXPENSIVE, PRICE_LEVEL_VERY_EXPENSIVE]",
            },
            "openNow": {
              "type": "boolean",
              "description": "whether those places are open for business."
            },
          },
          "required": ["textQuery"]
        }
      }
    ],
    messages = [
      {
        "role": "user",
        "content": "What are some affordable and good Italian restaurants open now in San Francisco??"
      }
    ],
)
print(response)
#Claude response
Message(
id =
  'msg_vrtx_01PVYodbvgeRibsC8mppez8m',
  content = [
    TextBlock(
      text =
      '<thinking>\nTo find affordable and good Italian restaurants open now in San Francisco, I will need to use the text_search_places_api tool. Let\'s look at the required parameters:\n\ntextQuery (required): The user\'s request provides a good text query to search for - "affordable and good Italian restaurants in San Francisco". So this parameter is satisfied.\n\nopenNow (optional): The user specified they want places open now, so I should set this optional parameter to true.\n\npriceLevels (optional): The user asked for affordable restaurants. Translating "affordable" to price levels, I think it\'s reasonable to include PRICE_LEVEL_INEXPENSIVE and PRICE_LEVEL_MODERATE. The user didn\'t ask for a specific price level, so I don\'t need to include the more expensive levels.\n\nIn summary, I have enough information to make the text_search_places_api call with the textQuery and openNow parameters, and can reasonably infer values for the optional priceLevels parameter based on the user\'s request for "affordable" restaurants. No other tools are needed to answer this query.\n</thinking>',
      type = 'text'
    ),
    ToolUseBlock(id =
      'toolu_vrtx_01AUxyh2YPF8uW6vxQx63hh4',
      input = {
        'textQuery': 'affordable and good Italian restaurants in San Francisco',
        'openNow': True,
        'priceLevels': [
          'PRICE_LEVEL_INEXPENSIVE',
          'PRICE_LEVEL_MODERATE'
        ]
      },
      name = 'text_search_places_api',
      type = 'tool_use')
  ], model = 'claude-3-opus-20240229',
  role = 'assistant', stop_reason =
  'tool_use', stop_sequence = None,
  type = 'message', usage = Usage(
    input_tokens = 727, output_tokens =
    372)
)

Build on a unified AI platform with Vertex AI

Vertex AI provides a comprehensive and enterprise-ready platform for building, deploying, and managing AI models at scale. By building on Vertex AI, you can confidently leverage the power of Claude 3 models while taking advantage of a unified AI development platform designed to support your generative AI workflows from start to finish.

  • Build applications with Vertex AI’s generative AI tools: Vertex AI provides an integrated environment to develop, evaluate, and deploy generative AI applications. This includes Auto SxS for model evaluation, LangChain integration for custom application building, and Colab Enterprise for iterative development.
  • Optimize performance and cost: Vertex AI’s scalable infrastructure and flexible pricing models empower you to experiment, deploy, and scale your generative AI applications efficiently.
  • Maximize the power of your data with BigQuery: Seamlessly integrate your enterprise data with Claude 3’s advanced capabilities, leveraging tools like BigQuery to extract valuable insights and drive informed decision-making. 
  • Deploy responsibly with enterprise-grade security, compliance, and data governance: Leverage Google Cloud’s built-in security, privacy, data governance, and compliance capabilities tailored to adhere to enterprise-level standards.

Get started with Claude 3 on Vertex AI

  1. Visit Vertex AI Model Garden and select “Browse Model Garden”.
  2. Navigate to the foundation models section. 
  3. Select the Claude 3 Opus, Claude 3 Sonnet, or Claude 3 Haiku tile from the available models. 
  4. Select “Enable” and follow the proceeding instructions.
  5. You should now have API access to integrate Opus into your workflows. Deploy your AI applications and monitor their performance using Vertex AI’s comprehensive tools. Use our sample notebook to get started.

To learn more about Anthropic’s Claude 3 models on Google Cloud, explore the Claude 3 on Vertex AI documentation.

By: Nenshad Bardoliwalla (Director, Product Management, Vertex AI)
Originally published at: Google Cloud Blog



For enquiries, product placements, sponsorships, and collaborations, connect with us at hello@globalcloudplatforms.com. We'd love to hear from you!


Our humans need coffee too! Your support is highly appreciated, thank you!

Total
0
Shares
Previous Article
goswifties_number-crunching_202405_wm

Of Nuggets And Tenders. To Know Or Not To Know, Is Not The Question. How To Become, Is.

Next Article
citi.io-i-want-ai-to-do-my-laundry-and-dishes

This AI Was Not Our AI Dream.

Related Posts

IBM Collaborated with the City of Seoul, South Korea to Develop an AI-based Virtual Assistant for its Citizens using IBM Watson

The city of Seoul's 'I Care You' project is using IBM Watson Assistant running on IBM public cloud to gather citizens' opinions on the COVID-19 pandemic ARMONK, N.Y., Aug. 20, 2020 /PRNewswire/ -- IBM (NYSE: IBM) and the city of Seoul, South Korea, have launched an AI-based virtual assistant for Seoul citizens using IBM Watson Assistant. The virtual assistant is part of the city's "I Care You" project, which is designed to survey the changes to daily life and difficulties that citizens are experiencing due to the COVID-19 pandemic to help inform policy decisions moving forward. With cases in more than 216 countries, areas or territories according to the World Health Organization, COVID-19 is changing what normal means for customers, citizens, businesses, government agencies and healthcare organizations all over the world. "Through this survey using an AI-based virtual assistant, we have an opportunity to understand the situation and social problems of citizens due to COVID-19," said Seon-Ae Jeong, the Director-General of Seoul Innovation. "This collaboration with IBM is a meaningful example of a public-private partnership. In the future, the results will be utilized to help develop various policies in Seoul City." The city of Seoul's new AI-based virtual assistant will survey Seoul citizens and then perform categorization and analysis of the gathered information to help policymakers. The survey contains questions about the changes caused by COVID-19, such as changes in health, problems with social isolation or environmental factors leading to vulnerabilities. It also asks about the difficulties caused by overall changes in daily life patterns (e.g. eating habits, free time, social interaction) and those caused by institutional policies. The survey is being carried out through the website of the city of Seoul as well as its social media channels. Any citizen living in the city of Seoul is eligible to take part in the survey. IBM South Korea worked with the city of Seoul throughout the entire process from training and development of the virtual assistant to collecting citizen opinions, analysis and service planning to make the "I Care You" project available for use in just three weeks. The virtual assistant, which is hosted on IBM public cloud, is developed with Watson Assistant for virtual agents and uses the enterprise AI search capabilities of IBM Watson Discovery to perform categorization and analysis of the gathered information. The city of Seoul is the latest organization to use IBM Watson Assistant to manage the high volume of engagement with citizens, using the solution to communicate changes and collect opinions, and provide insights to foster safety, and work smart throughout the pandemic. IBM Watson Assistant has been used in 25 countries and counting to help manage COVID-19 response. For more information about how Watson Assistant is being used in COVID response, visit: https://www.ibm.com/watson/covid-response. For more information about how businesses in any industry can use Watson Assistant, visit: https://www.ibm.com/cloud/watson-assistant/. Media Contact:Sarah MurphyIBM Media Relationssrmurphy@us.ibm.com SOURCE IBM