GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • LangChain Reference home page
  • GitHub
  • Main Docs
  • Deep Agents
  • LangChain
  • LangGraph
  • Integrations
  • LangSmith

This view

  • Original page
  • New address

GeezerVison is showing reference.langchain.com — langchain_google_vertexai

  • Overview
  • Google GenAI (Gemini)
    Google Vertex AI
    IBM
    ⌘I

    Menu

    Google GenAI (Gemini)
    Google Vertex AI
    IBM
    Language
    Theme

    langchain-google-vertexai

    Description

    PyPI - Version PyPI - License PyPI - Downloads

    LangChain integration for Google's Vertex AI Platform.

    Vertex AI consolidation

    As of langchain-google-vertexai 3.2.0, certain classes are deprecated in favor of equivalents in langchain-google-genai 4.0.0, which uses the consolidated google-genai SDK.

    Refer to the provider docs and release notes for more information.

    Modules

    Usage documentation

    Refer to the docs for a high-level guide on how to use each module. These reference pages contain auto-generated API documentation for each module, focusing on the "what" rather than the "how" or "why" (i.e. no end-to-end tutorials or conceptual overviews).

    ChatVertexAI

    Deprecated: Use ChatGoogleGenerativeAI from langchain-google-genai instead.

    VertexAI

    Deprecated: Use GoogleGenerativeAI from langchain-google-genai instead.

    VertexAIEmbeddings

    Deprecated: Use GoogleGenerativeAIEmbeddings from langchain-google-genai instead.

    Classes

    Class

    ToolsOutputParser

    Class

    PydanticFunctionsOutputParser

    Parse an output as a pydantic object.

    This parser is used to parse the output of a chat model that uses Google Vertex function format to invoke functions.

    The parser extracts the function call invoc

    Class

    Route

    Image Loading Route.

    Class

    ImageBytesLoader

    Loads image bytes from multiple sources given a string.

    Currently supported:

    • Google cloud storage URI
    • B64 Encoded image string
    • Local file path
    • URL
    Class

    VertexAIImageCaptioning

    Implementation of the Image Captioning model as an LLM.

    Class

    VertexAIImageCaptioningChat

    Implementation of the Image Captioning model as a chat.

    Class

    VertexAIVisualQnAChat

    Chat implementation of a visual QnA model.

    Class

    VertexAIImageGeneratorChat

    Generates an image from a prompt.

    Class

    VertexAIImageEditorChat

    Given an image and a prompt, edits the image.

    Currently only supports mask free editing.

    Class

    VertexAICallbackHandler

    Callback Handler that tracks VertexAI info.

    Class

    AnthropicTool

    Class

    VertexAIModelGarden

    Large language models served from Vertex AI Model Garden.

    Class

    ChatAnthropicVertex

    Class

    VertexMaaSModelFamily

    Class

    VertexModelGardenLlama

    Integration for Llama 3.1 on Google Cloud Vertex AI Model-as-a-Service.

    More information

    Class

    VertexModelGardenMistral

    Class

    DocumentStorage

    Abstract interface of a key, text storage for retrieving documents.

    Class

    GCSDocumentStorage

    Stores documents in Google Cloud Storage.

    For each pair id, document_text the name of the blob will be {prefix}/{id} stored in plain text format.

    Class

    DataStoreDocumentStorage

    Stores documents in Google Cloud DataStore.

    Class

    VectorSearchVectorStore

    VertexAI VectorStore that handles the search and indexing using Vector Search and stores the documents in Google Cloud Storage.

    Class

    VectorSearchVectorStoreGCS

    Alias of VectorSearchVectorStore for consistency with the rest of vector stores with different document storage backends.

    Class

    VectorSearchVectorStoreDatastore

    VectorSearch with DataStore document storage.

    Class

    Searcher

    Abstract implementation of a similarity searcher.

    Class

    VectorSearchSearcher

    Class to interface with Vector Search indexes (v1) and collections (v2).

    Class

    VectorSearchSDKManager

    Class in charge of building all Google Cloud SDK Objects needed to build VectorStores from project_id, credentials or other specifications.

    Abstracts away the authentication layer.

    Class

    StringEvaluator

    Grade, tag, or otherwise evaluate predictions relative to their inputs and/or reference labels.

    Class

    PairwiseStringEvaluator

    Compare the output of two models (or two outputs of the same model).

    Class

    VertexStringEvaluator

    Evaluate the perplexity of a predicted string.

    Class

    VertexPairWiseStringEvaluator

    Evaluate the perplexity of a predicted string.

    Class

    VertexAIEmbeddings

    deprecated

    Google Cloud VertexAI embedding models.

    Class

    VertexAI

    deprecated

    Google Vertex AI text completion large language models (legacy LLM).

    Vertex AI Platform Support

    Added in langchain-google-genai 4.0.0.

    ChatGoogleGenerativeAI now sup

    Class

    ChatVertexAI

    deprecated

    Google Cloud Vertex AI chat model integration.

    Functions

    Function

    create_context_cache

    Creates a cache for content in some model.

    Function

    image_bytes_to_b64_string

    Encodes image bytes into a b64 encoded string.

    Function

    create_text_content_part

    Create a dictionary that can be part of a message content list.

    Function

    create_image_content_part

    Create a dictionary that can be part of a message content list.

    Function

    get_image_str_from_content_part

    Parses an image string from a dictionary with the correct format.

    Function

    get_text_str_from_content_part

    Parses an string from a dictionary or string with the correct format.

    Function

    create_retry_decorator

    Creates a retry decorator for Vertex / Palm LLMs.

    Function

    raise_vertex_import_error

    Raise ImportError related to Vertex SDK being not available.

    Function

    get_user_agent

    Returns a custom user agent header.

    Function

    get_client_info

    Returns a ClientInfo object with a custom user agent header.

    Function

    load_image_from_gcs

    Loads an Image from GCS.

    Function

    get_generation_info

    Function

    enforce_stop_tokens

    Cut off the text as soon as any stop words occur.

    Function

    replace_defs_in_schema

    Given an OpenAPI schema with a property $defs replaces all occurrences of referenced items in the dictionary.

    Function

    convert_to_anthropic_tool

    Function

    create_base_retry_decorator

    Create a retry decorator for a given LLM and provided a list of error types.

    Function

    get_vertex_maas_model

    Return a corresponding Vertex MaaS instance.

    A factory method based on model's name.

    Function

    acompletion_with_retry

    Use tenacity to retry the async completion call.

    Function

    completion_with_retry

    Function

    stream_update_index

    Updates an index using stream updating.

    Function

    batch_update_index

    Updates an index using batch updating.

    Function

    to_data_points

    Converts triplets id, embedding, metadata into IndexDataPoints instances.

    Only metadata with values of type string, numeric or list of string will be considered for the filtering.

    Function

    data_points_to_batch_update_records

    Given a list of datapoints, generates a list of records in the input format required to do a bactch update.

    Function

    upsert_datapoints

    Upserts data points into a Vertex AI Vector Search 2.0 Collection.

    Function

    find_neighbors

    Searches for neighbors in a Vertex AI Vector Search 2.0 Collection.

    Function

    remove_datapoints

    Deletes data points from a Vertex AI Vector Search 2.0 Collection.

    Function

    get_datapoints_by_filter

    Gets datapoint IDs that match a filter in a Vertex AI Vector Search 2.0.

    Retrieves IDs from the Collection matching the given filter.

    Function

    semantic_search

    Performs semantic search in a Vertex AI Vector Search 2.0 Collection.

    Semantic search automatically generates embeddings from the search text using Vertex AI models, so you don't need to manually cre

    Function

    text_search

    Performs text search in a Vertex AI Vector Search 2.0 Collection.

    Text search performs traditional keyword/full-text search on data fields without using embeddings.

    Note: Text search does not suppor

    Function

    hybrid_search

    Performs hybrid search combining semantic and text search with RRF.

    Hybrid search runs both semantic search (with auto-generated embeddings) and text search (keyword matching) in parallel, then combi

    Function

    get_output_parser

    deprecated

    Get the appropriate function output parser given the user functions.

    Function

    create_structured_runnable

    deprecated

    Create a runnable sequence that uses OpenAI functions.

    Modules

    Module

    langchain_google_vertexai

    LangChain Google Generative AI integration (VertexAI).

    This module contains the LangChain integrations for Vertex AI service - Google foundational models and thi

    Module

    embeddings

    Module

    chains

    DEPRECATED

    Module

    utils

    Module

    functions_utils

    Module

    llms

    Module

    vision_models

    Module

    chat_models

    Wrapper around Google VertexAI chat-based models.

    Vertex supports both v1 and v1beta1 endpoints (endpoint_version parameter).

    Module

    callbacks

    DEPRECATED

    Module

    model_garden

    Module

    model_garden_maas

    Module

    llama

    Module

    mistral

    Module

    vectorstores

    Module

    document_storage

    Module

    vectorstores

    Module

    data

    Model profile data. All edits should be made in profile_augmentations.toml.

    Module

    evaluators

    Module

    evaluation

    You are visitor 01402775 — GeezerVison does not store the pages you look up.
    Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.