Skip to main content

llama-index embeddings google genai integration

Project description

Google GenAI Embeddings

This package provides a wrapper around the Google GenAI API, allowing you to use Gemini and Vertex AI embeddings in your projects.

Installation

pip install llama-index-embeddings-google-genai

Usage

from llama_index.embeddings.google_genai import GoogleGenAIEmbedding

embed_model = GoogleGenAIEmbedding(model_name="gemini-embedding-2-preview")

embeddings = embed_model.get_text_embedding("Hello, world!")
print(embeddings)

Vertex AI

embed_model = GoogleGenAIEmbedding(
    model_name="gemini-embedding-2-preview",
    vertexai_config={
        "project": "your-project-id",
        "location": "your-location",
    },
)

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

llama_index_embeddings_google_genai-0.4.0.tar.gz (6.0 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

File details

Details for the file llama_index_embeddings_google_genai-0.4.0.tar.gz.

File metadata

  • Download URL: llama_index_embeddings_google_genai-0.4.0.tar.gz
  • Upload date:
  • Size: 6.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.10.9 {"installer":{"name":"uv","version":"0.10.9","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for llama_index_embeddings_google_genai-0.4.0.tar.gz
Algorithm Hash digest
SHA256 dfd3827b6fcdb2d7e6ecd5c13f88aefd5a18bf33710f678d8da6967e62d4b9f7
MD5 74b40e463236ae0ac06c51ba388de5d7
BLAKE2b-256 b4f6dd8861333b3c70086f925692f2a352cb455031326f8d7a92022215b3bfc6

See more details on using hashes here.

File details

Details for the file llama_index_embeddings_google_genai-0.4.0-py3-none-any.whl.

File metadata

  • Download URL: llama_index_embeddings_google_genai-0.4.0-py3-none-any.whl
  • Upload date:
  • Size: 5.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.10.9 {"installer":{"name":"uv","version":"0.10.9","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for llama_index_embeddings_google_genai-0.4.0-py3-none-any.whl
Algorithm Hash digest
SHA256 12489e9f700a284d0ea46725e451e2ff00de11abd60db3551e18f2e5eaf5a981
MD5 e15632fb1790747e4e1270aa4aa835a1
BLAKE2b-256 5158b55bb25fe4c76e06895fb50479b864be676715aa253da34dddb427ce1485

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page