Skip to main content


This notebook shows how to use LangChain with GigaChat embeddings. To use you need to install gigachat python package.

%pip install --upgrade --quiet  gigachat

To get GigaChat credentials you need to create account and get access to API


import os
from getpass import getpass

os.environ["GIGACHAT_CREDENTIALS"] = getpass()
from langchain_community.embeddings import GigaChatEmbeddings

embeddings = GigaChatEmbeddings(verify_ssl_certs=False, scope="GIGACHAT_API_PERS")
API Reference:GigaChatEmbeddings
query_result = embeddings.embed_query("The quick brown fox jumps over the lazy dog")

Was this page helpful?

You can also leave detailed feedback on GitHub.