langchain-google API reference
84 public APIs from langchain-google (langchain-ai/langchain-google) — 44 classes, 12 functions, 28 methods. Signatures extracted by static analysis of the actual source.
Repository: langchain-ai/langchain-google
| Kind | Count |
|---|---|
| Classes | 44 |
| Functions | 12 |
| Methods | 28 |
API list
func
libs.community.langchain_google_community._utils.get_user_agent(module:Optional[str]=None) -> Tuple[str, str]Returns a custom user agent header.
func
libs.community.langchain_google_community._utils.import_google() -> Tuple[Request, Credentials, ServiceCredentials]Import google libraries.
func
libs.community.langchain_google_community._utils.import_installed_app_flow() -> InstalledAppFlowImport `InstalledAppFlow` class.
class
libs.community.langchain_google_community.bigquery.BigQueryLoaderLoad documents from Google Cloud BigQuery.
class
libs.community.langchain_google_community.calendar.base.CalendarBaseToolBase class for Google Calendar tools.
method
libs.community.langchain_google_community.calendar.base.CalendarBaseTool.from_api_resource(api_resource:Resource) -> 'CalendarBaseTool'Create a tool from an api resource.
class
libs.community.langchain_google_community.calendar.create_event.CreateEventSchemaInput schema for `CalendarCreateEvent`.
class
libs.community.langchain_google_community.calendar.delete_event.DeleteEventSchemaInput schema for `CalendarDeleteEvent`.
class
libs.community.langchain_google_community.calendar.move_event.MoveEventSchemaInput schema for `CalendarMoveEvent`.
class
libs.community.langchain_google_community.calendar.update_event.UpdateEventSchemaInput schema for `CalendarUpdateEvent`.
func
libs.community.langchain_google_community.calendar.utils.is_all_day_event(start_datetime:str, end_datetime:str) -> boolCheck if the event is all day.
class
libs.community.langchain_google_community.docai.DocAIParserGoogle Cloud Document AI parser.
method
libs.community.langchain_google_community.docai.DocAIParser.lazy_parse(blob:Blob) -> Iterator[Document]Parses a blob lazily.
class
libs.community.langchain_google_community.drive.GoogleDriveLoaderLoad documents from Google Drive.
method
libs.community.langchain_google_community.drive.GoogleDriveLoader.load() -> List[Document]Load documents.
method
libs.community.langchain_google_community.drive.GoogleDriveLoader.validate_credentials_path(v:Any, **kwargs:Any) -> AnyValidate that credentials_path exists.
method
libs.community.langchain_google_community.gcs_directory.GCSDirectoryLoader.load() -> List[Document]Load documents.
class
libs.community.langchain_google_community.gcs_file.GCSFileLoaderLoad documents from Google Cloud Storage file.
method
libs.community.langchain_google_community.gcs_file.GCSFileLoader.load() -> List[Document]Load documents.
class
libs.community.langchain_google_community.geocoding.GoogleGeocodeInputInput schema for `GoogleGeocodingTool`.
class
libs.community.langchain_google_community.geocoding.GoogleGeocodingAPIWrapperWrapper for Google Maps Geocoding API.
method
libs.community.langchain_google_community.geocoding.GoogleGeocodingAPIWrapper.clean_results(results:List[Dict]) -> List[Dict]Clean and format results.
method
libs.community.langchain_google_community.geocoding.GoogleGeocodingAPIWrapper.geocode_async(query:str, language:Optional[str]=None, region:Optional[str]=None) -> Dict[str, Any]Geocode query asynchronously.
method
libs.community.langchain_google_community.geocoding.GoogleGeocodingAPIWrapper.validate_environment(values:Dict) -> AnyValidate that api key exists in environment.
class
libs.community.langchain_google_community.gmail.base.GmailBaseToolBase class for Gmail tools.
method
libs.community.langchain_google_community.gmail.base.GmailBaseTool.from_api_resource(api_resource:Resource) -> 'GmailBaseTool'Create a tool from an api resource.
class
libs.community.langchain_google_community.gmail.create_draft.CreateDraftSchemaInput schema for `CreateDraftTool`.
class
libs.community.langchain_google_community.gmail.create_draft.GmailCreateDraftTool that creates a draft email for Gmail.
class
libs.community.langchain_google_community.gmail.get_message.GmailGetMessageTool that gets a message by ID from Gmail.
class
libs.community.langchain_google_community.gmail.get_message.SearchArgsSchemaInput schema for `GetMessageTool`.
class
libs.community.langchain_google_community.gmail.get_thread.GetThreadSchemaInput schema for `GetThreadTool`.
class
libs.community.langchain_google_community.gmail.get_thread.GmailGetThreadTool that gets a thread by ID from Gmail.
class
libs.community.langchain_google_community.gmail.loader.GMailLoaderLoad chat sessions from Gmail.
class
libs.community.langchain_google_community.gmail.search.ResourceEnumerator of Resources to search.
class
libs.community.langchain_google_community.gmail.search.SearchArgsSchemaInput schema for `SearchGmailTool`.
class
libs.community.langchain_google_community.gmail.send_message.GmailSendMessageTool that sends a message to Gmail.
class
libs.community.langchain_google_community.gmail.send_message.SendMessageSchemaInput schema for `SendMessageTool`.
class
libs.community.langchain_google_community.gmail.toolkit.GmailToolkitToolkit for interacting with Gmail.
method
libs.community.langchain_google_community.gmail.toolkit.GmailToolkit.get_tools() -> List[BaseTool]Get the tools in the toolkit.
func
libs.community.langchain_google_community.gmail.utils.clean_email_body(body:str) -> strClean email body.
class
libs.community.langchain_google_community.model_armor.base_runnable.ModelArmorParamsModel Armor parameters.
method
libs.community.langchain_google_community.model_armor.base_runnable.ModelArmorParams.validate_project() -> 'ModelArmorParams'Validate the project ID.
class
libs.community.langchain_google_community.places_api.GooglePlacesAPIWrapperWrapper around Google Places API.
class
libs.community.langchain_google_community.places_api.GooglePlacesSchemaInput schema for `GooglePlacesTool`.
class
libs.community.langchain_google_community.places_api.GooglePlacesToolTool that queries the Google Places API.
class
libs.community.langchain_google_community.search.GoogleSearchAPIWrapperWrapper for Google Custom Search API.
method
libs.community.langchain_google_community.search.GoogleSearchAPIWrapper.run(query:str) -> strRun query through Google Search and parse result.
class
libs.community.langchain_google_community.sheets.base.SheetsBaseToolBase class for Google Sheets tools.
method
libs.community.langchain_google_community.sheets.base.SheetsBaseTool.from_api_key(api_key:str) -> 'SheetsBaseTool'Create a tool from an API key.
method
libs.community.langchain_google_community.sheets.base.SheetsBaseTool.from_api_resource(api_resource:Resource) -> 'SheetsBaseTool'Create a tool from an API resource.
class
libs.community.langchain_google_community.sheets.enums.DateTimeRenderOptionGoogle Sheets date/time render options.
class
libs.community.langchain_google_community.sheets.enums.MajorDimensionGoogle Sheets major dimension options.
class
libs.community.langchain_google_community.sheets.enums.ValueRenderOptionGoogle Sheets value render options.
class
libs.community.langchain_google_community.sheets.read_sheet_tools.ReadSheetDataSchemaInput schema for `SheetsReadDataTool`.
class
libs.community.langchain_google_community.sheets.toolkit.SheetsToolkitToolkit for interacting with Google Sheets.
method
libs.community.langchain_google_community.sheets.toolkit.SheetsToolkit.get_tools() -> List[BaseTool]Get the tools in the toolkit.
func
libs.community.langchain_google_community.sheets.utils.validate_a1_range(range_name:str) -> boolValidate A1 notation range format.
func
libs.community.langchain_google_community.sheets.utils.validate_range_name(range_name:str) -> strValidate and normalize a range name.
func
libs.community.langchain_google_community.sheets.utils.validate_spreadsheet_id(spreadsheet_id:str) -> strValidate and normalize a Google Spreadsheet ID.
class
libs.community.langchain_google_community.vertex_ai_search.VertexAISearchRetriever`Google Vertex AI Search` retriever.
func
libs.genai.langchain_google_genai._common.get_user_agent(module:str | None=None) -> tuple[str, str]Returns a custom user agent header.
class
libs.genai.langchain_google_genai._image_utils.RouteImage loading route.
class
libs.genai.langchain_google_genai.chat_models.ChatGoogleGenerativeAIGoogle GenAI chat model integration.
method
libs.genai.langchain_google_genai.chat_models.ChatGoogleGenerativeAI.get_num_tokens(text:str) -> intGet the number of tokens present in the text.
method
libs.genai.langchain_google_genai.chat_models.ChatGoogleGenerativeAI.validate_environment() -> SelfValidates params and builds client.
class
libs.genai.langchain_google_genai.embeddings.GoogleGenerativeAIEmbeddingsGoogle Generative AI Embeddings.
method
libs.genai.langchain_google_genai.embeddings.GoogleGenerativeAIEmbeddings.embed_query(text:str, *task_type:str | None=None, *title:str | None=None, *output_dimensionality:int | None=None) -> list[float]Embed a single text.
class
libs.vertexai.langchain_google_vertexai._image_utils.RouteImage Loading Route.
func
libs.vertexai.langchain_google_vertexai._utils.enforce_stop_tokens(text:str, stop:list[str]) -> strCut off the text as soon as any stop words occur.
func
libs.vertexai.langchain_google_vertexai._utils.get_user_agent(module:str | None=None) -> tuple[str, str]Returns a custom user agent header.
func
libs.vertexai.langchain_google_vertexai._utils.load_image_from_gcs(path:str, project:str | None=None) -> ImageLoads an `Image` from GCS.
method
libs.vertexai.langchain_google_vertexai.callbacks.VertexAICallbackHandler.on_llm_end(response:LLMResult, **kwargs:Any) -> NoneCollects token usage.
method
libs.vertexai.langchain_google_vertexai.callbacks.VertexAICallbackHandler.on_llm_new_token(token:str | list[str | dict[str, Any]], **kwargs:Any) -> NoneRuns on new LLM token.
method
libs.vertexai.langchain_google_vertexai.callbacks.VertexAICallbackHandler.on_llm_start(serialized:dict[str, Any], prompts:list[str], **kwargs:Any) -> NoneRuns when LLM starts running.
method
libs.vertexai.langchain_google_vertexai.chat_models.ChatVertexAI.get_num_tokens(text:str) -> intGet the number of tokens present in the text.
class
libs.vertexai.langchain_google_vertexai.embeddings.VertexAIEmbeddingsGoogle Cloud VertexAI embedding models.
method
libs.vertexai.langchain_google_vertexai.embeddings.VertexAIEmbeddings.embed(texts:list[str], embeddings_task_type:EmbeddingTaskTypes | None=None, dimensions:int | None=None, title:str | None=None) -> list[list[float]]Embed a list of strings.
method
libs.vertexai.langchain_google_vertexai.embeddings.VertexAIEmbeddings.embed_documents(texts:list[str], *embeddings_task_type:EmbeddingTaskTypes='RETRIEVAL_DOCUMENT') -> list[list[float]]Embed a list of documents.
method
libs.vertexai.langchain_google_vertexai.embeddings.VertexAIEmbeddings.embed_query(text:str, *embeddings_task_type:EmbeddingTaskTypes='RETRIEVAL_QUERY') -> list[float]Embed a text.
method
libs.vertexai.langchain_google_vertexai.evaluators._core.StringEvaluator.evaluation_name() -> strThe name of the evaluation.
class
libs.vertexai.langchain_google_vertexai.functions_utils.PydanticFunctionsOutputParserParse an output as a pydantic object.
method
libs.vertexai.langchain_google_vertexai.llms.VertexAI.get_num_tokens(text:str) -> intGet the number of tokens present in the text.
class
libs.vertexai.langchain_google_vertexai.vision_models.VertexAIImageGeneratorChatGenerates an image from a prompt.
class
libs.vertexai.langchain_google_vertexai.vision_models.VertexAIVisualQnAChatChat implementation of a visual QnA model.
About this data
These signatures were extracted from the public source of langchain-ai/langchain-google
using Python's ast module. Argument names, default values,
type annotations and return types are taken verbatim from the code.
Implementation bodies are never stored. See
how it works for details.