Код: Выделить всё
from langchain.embeddings.huggingface import HuggingFaceEmbeddings
from llama_index import LangchainEmbedding, ServiceContext
embed_model = LangchainEmbedding(
HuggingFaceEmbeddings(model_name="thenlper/gte-large")
)
service_context = ServiceContext.from_defaults(
chunk_size=256,
llm=llm,
embed_model=embed_model
)
index = VectorStoreIndex.from_documents(documents, service_context=service_context)
Как я могу решить? Связано ли это с тем, что я работаю над Colab?
Подробнее здесь: https://stackoverflow.com/questions/775 ... lama-index
Мобильная версия