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.5.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.5.0.tar.gz.

File metadata

  • Download URL: llama_index_embeddings_google_genai-0.5.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.5.0.tar.gz
Algorithm Hash digest
SHA256 051d7ca0a95e3bc1d0f32f5cc167cca119ce42bc4a516c8117934c589c93b19f
MD5 6d5b71b35f8bf2f461209a90d19cd25c
BLAKE2b-256 4be617f94417627d12cc1a6b103f14ee926b52d86566fc81947bef903126cda6

See more details on using hashes here.

File details

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

File metadata

  • Download URL: llama_index_embeddings_google_genai-0.5.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.5.0-py3-none-any.whl
Algorithm Hash digest
SHA256 25a32ec995785e5e903c08561252bb107fc3f41b79691eb8fabb6a8e09ca238f
MD5 92e9779dbcd0065231a95c662b0b7f19
BLAKE2b-256 8596520691db2af5f606cf2d6f38aaafb29a416b4bc4cc09219c6b55369ead31

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