Get up and running with Kimi, GLM, MiniMax, DeepSeek, gpt-oss, Qwen, Gemma and other models.
add embed model command and fix question invoke (#4766)
Shubham60323e08057d
diff --git a/docs/tutorials/langchainpy.md b/docs/tutorials/langchainpy.mdindex 9a1bca0dd..06543a070 100644--- a/docs/tutorials/langchainpy.md+++ b/docs/tutorials/langchainpy.md@@ -45,7 +45,7 @@ all_splits = text_splitter.split_documents(data)```It's split up, but we have to find the relevant splits and then submit those to the model. We can do this by creating embeddings and storing them in a vector database. We can use Ollama directly to instantiate an embedding model. We will use ChromaDB in this example for a vector database. `pip install chromadb`-+We also need to pull embedding model: `ollama pull nomic-embed-text````pythonfrom langchain.embeddings import OllamaEmbeddingsfrom langchain.vectorstores import Chroma@@ -68,7 +68,8 @@ The next thing is to send the question and the relevant parts of the docs to the```pythonfrom langchain.chains import RetrievalQAqachain=RetrievalQA.from_chain_type(ollama, retriever=vectorstore.as_retriever())-qachain.invoke({"query": question})+res = qachain.invoke({"query": question})+print(res['result'])```The answer received from this chain was: