From 005f12ce87bb67d2c579fa595c278d8cc81d913e Mon Sep 17 00:00:00 2001 From: "Caroline Frasca (Lu)" <42614552+carolinedlu@users.noreply.github.com> Date: Thu, 21 Dec 2023 10:22:47 -0500 Subject: [PATCH 01/18] Add Streamlit to list of integrations --- docs/integrations/index.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/docs/integrations/index.md b/docs/integrations/index.md index 119ca6c..d1f890e 100644 --- a/docs/integrations/index.md +++ b/docs/integrations/index.md @@ -18,6 +18,7 @@ We welcome pull requests to add new Integrations to the community. | [🦙 LlamaIndex](/integrations/llama-index) | ✅ | :soon: | | [Braintrust](/integrations/braintrust) | ✅ | ✅ | | [🔭 OpenLLMetry](/integrations/openllmetry) | ✅ | :soon: | +| [🎈 Streamlit](/integrations/streamlit) | ✅ | ✖️ | *Coming soon* - integrations with LangSmith, JinaAI, and more. @@ -25,4 +26,4 @@ We welcome pull requests to add new Integrations to the community. ### 🧬 Embeddings -Are you looking for how Chroma integrates with embeddings providers like OpenAI, Cohere, Google PaLM and others? View [🧬 Embeddings](/embeddings) integrations. \ No newline at end of file +Are you looking for how Chroma integrates with embeddings providers like OpenAI, Cohere, Google PaLM and others? View [🧬 Embeddings](/embeddings) integrations. From 612443174954342615ed327bf64c85cd761f2920 Mon Sep 17 00:00:00 2001 From: "Caroline Frasca (Lu)" <42614552+carolinedlu@users.noreply.github.com> Date: Thu, 21 Dec 2023 11:04:25 -0500 Subject: [PATCH 02/18] template --- docs/integrations/streamlit.md | 103 +++++++++++++++++++++++++++++++++ 1 file changed, 103 insertions(+) create mode 100644 docs/integrations/streamlit.md diff --git a/docs/integrations/streamlit.md b/docs/integrations/streamlit.md new file mode 100644 index 0000000..8d38664 --- /dev/null +++ b/docs/integrations/streamlit.md @@ -0,0 +1,103 @@ +--- +slug: /integrations/langchain +title: 🦜️🔗 LangChain +--- + +LangChain is a popular open-source framework for developing applications powered by language models. + + + +[MIT License](https://github.com/langchain-ai/langchain/blob/master/LICENSE)  • [Site](https://www.langchain.com/) + +| Languages | Docs | Github | +|---|---|--|--| +|Python | [Docs](https://python.langchain.com/docs/get_started/introduction) | [Code](https://github.com/langchain-ai/langchain) +|JS | [Docs](https://js.langchain.com/docs/get_started/introduction) | [Code](https://github.com/langchain-ai/langchainjs) + +### Install + +`pip install langchain` / `yarn add langchain` + +### Main Benefits + +- Common Patterns for chain-of-thought and prompt templating +- Many integrations and data loaders +- Deep integration to LangSmith monitoring (developed by the same team) + +### Simple Example + +#### Python + +```python +import chromadb +from langchain.vectorstores import Chroma +from langchain.embeddings.sentence_transformer import SentenceTransformerEmbeddings + +# Chroma code +persistent_client = chromadb.PersistentClient() +collection = persistent_client.get_or_create_collection("collection_name") +collection.add(ids=["1", "2", "3"], documents=["a", "b", "c"]) + +# LangChain Code +embedding_function = SentenceTransformerEmbeddings(model_name="all-MiniLM-L6-v2") + +langchain_chroma = Chroma( + client=persistent_client, + collection_name="collection_name", + embedding_function=embedding_function, +) +# Important! - the embedding functiion passed to langchain is their wrapper, not Chroma's + + +print("There are", langchain_chroma._collection.count(), "in the collection") +``` + +#### Javascript + +```js +import { OpenAI } from "langchain/llms/openai"; +import { ConversationalRetrievalQAChain } from "langchain/chains"; +import { Chroma } from "langchain/vectorstores/chroma"; +import { OpenAIEmbeddings } from "langchain/embeddings/openai"; +import { RecursiveCharacterTextSplitter } from "langchain/text_splitter"; +import * as fs from "fs"; + +// to run this first run a chroma server with `chroma run --path /path/to/data` + +export const run = async () => { + /* Initialize the LLM to use to answer the question */ + const model = new OpenAI(); + /* Load in the file we want to do question answering over */ + const text = fs.readFileSync("state_of_the_union.txt", "utf8"); + /* Split the text into chunks */ + const textSplitter = new RecursiveCharacterTextSplitter({ chunkSize: 1000 }); + const docs = await textSplitter.createDocuments([text]); + /* Create the vectorstore */ + const vectorStore = await Chroma.fromDocuments(docs, new OpenAIEmbeddings(), { + collectionName: "state_of_the_union", + }); + /* Create the chain */ + const chain = ConversationalRetrievalQAChain.fromLLM( + model, + vectorStore.asRetriever() + ); + /* Ask it a question */ + const question = "What did the president say about Justice Breyer?"; + const res = await chain.call({ question, chat_history: [] }); + console.log(res); +}; +``` + +### Resources + +- [LangChain + Chroma Announcement Post](https://blog.langchain.dev/langchain-chroma/) on the LangChain blog +- [LangChain's Chroma Documentation](https://python.langchain.com/en/latest/modules/indexes/vectorstores.html?highlight=chroma#langchain.vectorstores.Chroma) + +#### Tutorials + + - [Chroma and LangChain tutorial](https://github.com/grumpyp/chroma-langchain-tutorial) - The demo showcases how to pull data from the English Wikipedia using their API. The project also demonstrates how to vectorize data in chunks and get embeddings using OpenAI embeddings model. + - [Create a Voice-based ChatGPT Clone That Can Search on the Internet and local files](https://betterprogramming.pub/how-to-create-a-voice-based-chatgpt-clone-that-can-search-on-the-internet-24d7f570ea8) +- [Harrison's `chroma-langchain` demo repo](https://github.com/hwchase17/chroma-langchain) + - [question answering over documents](https://github.com/hwchase17/chroma-langchain/blob/master/qa.ipynb) - ([Replit version](https://replit.com/@swyx/LangChainChromaStarter#main.py)) + - [to use Chroma as a persistent database](https://github.com/hwchase17/chroma-langchain/blob/master/persistent-qa.ipynb) + From 05a735cfdb361c2e366b561b97ed3bd477a50d21 Mon Sep 17 00:00:00 2001 From: "Caroline Frasca (Lu)" <42614552+carolinedlu@users.noreply.github.com> Date: Thu, 21 Dec 2023 12:02:24 -0500 Subject: [PATCH 03/18] Update streamlit.md --- docs/integrations/streamlit.md | 50 ++++------------------------------ 1 file changed, 6 insertions(+), 44 deletions(-) diff --git a/docs/integrations/streamlit.md b/docs/integrations/streamlit.md index 8d38664..5869fea 100644 --- a/docs/integrations/streamlit.md +++ b/docs/integrations/streamlit.md @@ -1,22 +1,21 @@ --- -slug: /integrations/langchain -title: 🦜️🔗 LangChain +slug: /integrations/streamlit +title: 🎈 Streamlit --- LangChain is a popular open-source framework for developing applications powered by language models. - + -[MIT License](https://github.com/langchain-ai/langchain/blob/master/LICENSE)  • [Site](https://www.langchain.com/) +[Apache 2.0 License](https://github.com/langchain-ai/langchain/blob/master/LICENSE)  • [Site]([https://www.langchain.com/](https://streamlit.io/)) | Languages | Docs | Github | |---|---|--|--| -|Python | [Docs](https://python.langchain.com/docs/get_started/introduction) | [Code](https://github.com/langchain-ai/langchain) -|JS | [Docs](https://js.langchain.com/docs/get_started/introduction) | [Code](https://github.com/langchain-ai/langchainjs) +|Python | [Docs](https://docs.streamlit.io/) | [Code](https://github.com/langchain-ai/langchain) ### Install -`pip install langchain` / `yarn add langchain` +`pip install streamlit` ### Main Benefits @@ -52,42 +51,6 @@ langchain_chroma = Chroma( print("There are", langchain_chroma._collection.count(), "in the collection") ``` -#### Javascript - -```js -import { OpenAI } from "langchain/llms/openai"; -import { ConversationalRetrievalQAChain } from "langchain/chains"; -import { Chroma } from "langchain/vectorstores/chroma"; -import { OpenAIEmbeddings } from "langchain/embeddings/openai"; -import { RecursiveCharacterTextSplitter } from "langchain/text_splitter"; -import * as fs from "fs"; - -// to run this first run a chroma server with `chroma run --path /path/to/data` - -export const run = async () => { - /* Initialize the LLM to use to answer the question */ - const model = new OpenAI(); - /* Load in the file we want to do question answering over */ - const text = fs.readFileSync("state_of_the_union.txt", "utf8"); - /* Split the text into chunks */ - const textSplitter = new RecursiveCharacterTextSplitter({ chunkSize: 1000 }); - const docs = await textSplitter.createDocuments([text]); - /* Create the vectorstore */ - const vectorStore = await Chroma.fromDocuments(docs, new OpenAIEmbeddings(), { - collectionName: "state_of_the_union", - }); - /* Create the chain */ - const chain = ConversationalRetrievalQAChain.fromLLM( - model, - vectorStore.asRetriever() - ); - /* Ask it a question */ - const question = "What did the president say about Justice Breyer?"; - const res = await chain.call({ question, chat_history: [] }); - console.log(res); -}; -``` - ### Resources - [LangChain + Chroma Announcement Post](https://blog.langchain.dev/langchain-chroma/) on the LangChain blog @@ -100,4 +63,3 @@ export const run = async () => { - [Harrison's `chroma-langchain` demo repo](https://github.com/hwchase17/chroma-langchain) - [question answering over documents](https://github.com/hwchase17/chroma-langchain/blob/master/qa.ipynb) - ([Replit version](https://replit.com/@swyx/LangChainChromaStarter#main.py)) - [to use Chroma as a persistent database](https://github.com/hwchase17/chroma-langchain/blob/master/persistent-qa.ipynb) - From b4824412e837847c3817a4f57747251dc27a8104 Mon Sep 17 00:00:00 2001 From: "Caroline Frasca (Lu)" <42614552+carolinedlu@users.noreply.github.com> Date: Thu, 21 Dec 2023 12:04:27 -0500 Subject: [PATCH 04/18] Update streamlit.md --- docs/integrations/streamlit.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/integrations/streamlit.md b/docs/integrations/streamlit.md index 5869fea..c52734f 100644 --- a/docs/integrations/streamlit.md +++ b/docs/integrations/streamlit.md @@ -3,11 +3,11 @@ slug: /integrations/streamlit title: 🎈 Streamlit --- -LangChain is a popular open-source framework for developing applications powered by language models. +Streamlit is an open-source Python library that makes it easy to create and share beautiful, custom web apps for machine learning and data science. In just a few minutes you can build and deploy powerful data apps. -[Apache 2.0 License](https://github.com/langchain-ai/langchain/blob/master/LICENSE)  • [Site]([https://www.langchain.com/](https://streamlit.io/)) +[Apache 2.0 License](https://github.com/langchain-ai/langchain/blob/master/LICENSE)  • [Site](https://streamlit.io/) | Languages | Docs | Github | |---|---|--|--| From 61527dde84e42dfc470bb0338c4b27d7c7e1eb1a Mon Sep 17 00:00:00 2001 From: "Caroline Frasca (Lu)" <42614552+carolinedlu@users.noreply.github.com> Date: Thu, 21 Dec 2023 12:05:00 -0500 Subject: [PATCH 05/18] Update streamlit.md --- docs/integrations/streamlit.md | 1 - 1 file changed, 1 deletion(-) diff --git a/docs/integrations/streamlit.md b/docs/integrations/streamlit.md index c52734f..2ec21e6 100644 --- a/docs/integrations/streamlit.md +++ b/docs/integrations/streamlit.md @@ -10,7 +10,6 @@ Streamlit is an open-source Python library that makes it easy to create and shar [Apache 2.0 License](https://github.com/langchain-ai/langchain/blob/master/LICENSE)  • [Site](https://streamlit.io/) | Languages | Docs | Github | -|---|---|--|--| |Python | [Docs](https://docs.streamlit.io/) | [Code](https://github.com/langchain-ai/langchain) ### Install From fc9d3bf4b74a2d7041b41d4378621af3ff557bfd Mon Sep 17 00:00:00 2001 From: "Caroline Frasca (Lu)" <42614552+carolinedlu@users.noreply.github.com> Date: Thu, 21 Dec 2023 12:05:45 -0500 Subject: [PATCH 06/18] Update streamlit.md --- docs/integrations/streamlit.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/integrations/streamlit.md b/docs/integrations/streamlit.md index 2ec21e6..f3fbef4 100644 --- a/docs/integrations/streamlit.md +++ b/docs/integrations/streamlit.md @@ -9,8 +9,8 @@ Streamlit is an open-source Python library that makes it easy to create and shar [Apache 2.0 License](https://github.com/langchain-ai/langchain/blob/master/LICENSE)  • [Site](https://streamlit.io/) -| Languages | Docs | Github | -|Python | [Docs](https://docs.streamlit.io/) | [Code](https://github.com/langchain-ai/langchain) +| Languages | Docs | Github |
+|Python | [Docs](https://docs.streamlit.io/) | [Code](https://github.com/streamlit/streamlit) ### Install From 666c7c2609561fbd70c9e36a34c500fb6dd486d1 Mon Sep 17 00:00:00 2001 From: "Caroline Frasca (Lu)" <42614552+carolinedlu@users.noreply.github.com> Date: Thu, 21 Dec 2023 14:00:21 -0500 Subject: [PATCH 07/18] Update streamlit.md --- docs/integrations/streamlit.md | 58 +++++++++++++++++----------------- 1 file changed, 29 insertions(+), 29 deletions(-) diff --git a/docs/integrations/streamlit.md b/docs/integrations/streamlit.md index f3fbef4..5247352 100644 --- a/docs/integrations/streamlit.md +++ b/docs/integrations/streamlit.md @@ -7,58 +7,58 @@ Streamlit is an open-source Python library that makes it easy to create and shar -[Apache 2.0 License](https://github.com/langchain-ai/langchain/blob/master/LICENSE)  • [Site](https://streamlit.io/) +[Apache 2.0 License](https://github.com/streamlit/streamlit/blob/develop/LICENSE)  • [Site](https://streamlit.io/) | Languages | Docs | Github |
|Python | [Docs](https://docs.streamlit.io/) | [Code](https://github.com/streamlit/streamlit) ### Install +Install Streamlit: `pip install streamlit` +Install the streamlit-chromadb-connection, which makes it easy to connect your Streamlit app to Chroma DB with [`st.connection`](https://docs.streamlit.io/1.11.0/library/api-reference/connections/st.connection)" +`pip install streamlit-chromadb-connection` + ### Main Benefits -- Common Patterns for chain-of-thought and prompt templating -- Many integrations and data loaders -- Deep integration to LangSmith monitoring (developed by the same team) +- Easy to get started with Streamlit's straightforward syntax +- Built-in [chatbot functionality](https://docs.streamlit.io/library/api-reference/chat) +- Pre-built integration with Chroma via `streamlit-chromadb-connection` +- Deploy apps for free on [Streamlit Community Cloud](https://share.streamlit.io/) ### Simple Example #### Python ```python -import chromadb -from langchain.vectorstores import Chroma -from langchain.embeddings.sentence_transformer import SentenceTransformerEmbeddings - -# Chroma code -persistent_client = chromadb.PersistentClient() -collection = persistent_client.get_or_create_collection("collection_name") -collection.add(ids=["1", "2", "3"], documents=["a", "b", "c"]) - -# LangChain Code -embedding_function = SentenceTransformerEmbeddings(model_name="all-MiniLM-L6-v2") +import streamlit as st +from streamlit_chromadb_connection.chromadb_connection import ChromadbConnection -langchain_chroma = Chroma( - client=persistent_client, - collection_name="collection_name", - embedding_function=embedding_function, -) -# Important! - the embedding functiion passed to langchain is their wrapper, not Chroma's +configuration = { + "client": "PersistentClient", + "path": "/tmp/.chroma" +} +collection_name = "documents_collection" -print("There are", langchain_chroma._collection.count(), "in the collection") +conn = st.connection("chromadb", + type=ChromaDBConnection, + **configuration) +documents_collection_df = conn.get_collection_data(collection_name) +st.dataframe(documents_collection_df) ``` ### Resources -- [LangChain + Chroma Announcement Post](https://blog.langchain.dev/langchain-chroma/) on the LangChain blog -- [LangChain's Chroma Documentation](https://python.langchain.com/en/latest/modules/indexes/vectorstores.html?highlight=chroma#langchain.vectorstores.Chroma) +- [Guide to using vector databases with Streamlit](https://pub.towardsai.net/vector-databases-for-your-streamlit-ai-apps-56cd0af7bbba) +- [Streamlit's `st.connection` documentation](https://docs.streamlit.io/library/api-reference/connections/st.connection) +- [Demo app for `streamlit-chromadb-connection`](https://app-chromadbconnection-mfzxl3nzozmaxh3mrkd6zm.streamlit.app/) #### Tutorials - - [Chroma and LangChain tutorial](https://github.com/grumpyp/chroma-langchain-tutorial) - The demo showcases how to pull data from the English Wikipedia using their API. The project also demonstrates how to vectorize data in chunks and get embeddings using OpenAI embeddings model. - - [Create a Voice-based ChatGPT Clone That Can Search on the Internet and local files](https://betterprogramming.pub/how-to-create-a-voice-based-chatgpt-clone-that-can-search-on-the-internet-24d7f570ea8) -- [Harrison's `chroma-langchain` demo repo](https://github.com/hwchase17/chroma-langchain) - - [question answering over documents](https://github.com/hwchase17/chroma-langchain/blob/master/qa.ipynb) - ([Replit version](https://replit.com/@swyx/LangChainChromaStarter#main.py)) - - [to use Chroma as a persistent database](https://github.com/hwchase17/chroma-langchain/blob/master/persistent-qa.ipynb) +- [Build an "Ask the Doc" app using Chroma, Streamlit, and LangChain](https://blog.streamlit.io/langchain-tutorial-4-build-an-ask-the-doc-app/) +- [Summarize documents with Chroma, Streamlit, and LangChain](https://alphasec.io/summarize-documents-with-langchain-and-chroma/)(https://alphasec.io/summarize-documents-with-langchain-and-chroma/) +- [Build a custom chatbot with Chroma, Streamlit, and LangChain](https://blog.streamlit.io/how-in-app-feedback-can-increase-your-chatbots-performance/) +- [Build a RAG bot using Chroma, Streamlit, and LangChain](https://levelup.gitconnected.com/building-a-generative-ai-app-with-streamlit-and-openai-95ec31fe8efd) +- [Build a PDF QA chatbot with Chroma, Streamlit, and OpenAI](https://www.confident-ai.com/blog/how-to-build-a-pdf-qa-chatbot-using-openai-and-chromadb)https://www.confident-ai.com/blog/how-to-build-a-pdf-qa-chatbot-using-openai-and-chromadb From 61e366587037edbd447ff41b8cfde9ff8da396d5 Mon Sep 17 00:00:00 2001 From: "Caroline Frasca (Lu)" <42614552+carolinedlu@users.noreply.github.com> Date: Thu, 21 Dec 2023 14:01:29 -0500 Subject: [PATCH 08/18] Update streamlit.md --- docs/integrations/streamlit.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/integrations/streamlit.md b/docs/integrations/streamlit.md index 5247352..5895d87 100644 --- a/docs/integrations/streamlit.md +++ b/docs/integrations/streamlit.md @@ -17,7 +17,7 @@ Streamlit is an open-source Python library that makes it easy to create and shar Install Streamlit: `pip install streamlit` -Install the streamlit-chromadb-connection, which makes it easy to connect your Streamlit app to Chroma DB with [`st.connection`](https://docs.streamlit.io/1.11.0/library/api-reference/connections/st.connection)" +Install `streamlit-chromadb-connection`, which connects your Streamlit app to Chroma DB through [`st.connection`](https://docs.streamlit.io/1.11.0/library/api-reference/connections/st.connection): `pip install streamlit-chromadb-connection` ### Main Benefits From 3af74f23d23acd1466a7be1738d4b1dd1233be99 Mon Sep 17 00:00:00 2001 From: "Caroline Frasca (Lu)" <42614552+carolinedlu@users.noreply.github.com> Date: Thu, 21 Dec 2023 14:01:48 -0500 Subject: [PATCH 09/18] Update streamlit.md --- docs/integrations/streamlit.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/integrations/streamlit.md b/docs/integrations/streamlit.md index 5895d87..aceabc8 100644 --- a/docs/integrations/streamlit.md +++ b/docs/integrations/streamlit.md @@ -14,10 +14,10 @@ Streamlit is an open-source Python library that makes it easy to create and shar ### Install -Install Streamlit: +Install Streamlit:
`pip install streamlit` -Install `streamlit-chromadb-connection`, which connects your Streamlit app to Chroma DB through [`st.connection`](https://docs.streamlit.io/1.11.0/library/api-reference/connections/st.connection): +Install `streamlit-chromadb-connection`, which connects your Streamlit app to Chroma DB through [`st.connection`](https://docs.streamlit.io/1.11.0/library/api-reference/connections/st.connection):
`pip install streamlit-chromadb-connection` ### Main Benefits From 3627dda8b80ab53331d47a2dfb319701265f47bb Mon Sep 17 00:00:00 2001 From: "Caroline Frasca (Lu)" <42614552+carolinedlu@users.noreply.github.com> Date: Thu, 21 Dec 2023 14:02:11 -0500 Subject: [PATCH 10/18] Update streamlit.md --- docs/integrations/streamlit.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/integrations/streamlit.md b/docs/integrations/streamlit.md index aceabc8..e8a330a 100644 --- a/docs/integrations/streamlit.md +++ b/docs/integrations/streamlit.md @@ -10,7 +10,7 @@ Streamlit is an open-source Python library that makes it easy to create and shar [Apache 2.0 License](https://github.com/streamlit/streamlit/blob/develop/LICENSE)  • [Site](https://streamlit.io/) | Languages | Docs | Github |
-|Python | [Docs](https://docs.streamlit.io/) | [Code](https://github.com/streamlit/streamlit) +| Python | [Docs](https://docs.streamlit.io/) | [Code](https://github.com/streamlit/streamlit) ### Install From 594c8a4eae2613e85571caa4921a0b947aed8bb6 Mon Sep 17 00:00:00 2001 From: "Caroline Frasca (Lu)" <42614552+carolinedlu@users.noreply.github.com> Date: Thu, 21 Dec 2023 15:01:17 -0500 Subject: [PATCH 11/18] Update streamlit.md --- docs/integrations/streamlit.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/integrations/streamlit.md b/docs/integrations/streamlit.md index e8a330a..9766c69 100644 --- a/docs/integrations/streamlit.md +++ b/docs/integrations/streamlit.md @@ -58,7 +58,7 @@ st.dataframe(documents_collection_df) #### Tutorials - [Build an "Ask the Doc" app using Chroma, Streamlit, and LangChain](https://blog.streamlit.io/langchain-tutorial-4-build-an-ask-the-doc-app/) -- [Summarize documents with Chroma, Streamlit, and LangChain](https://alphasec.io/summarize-documents-with-langchain-and-chroma/)(https://alphasec.io/summarize-documents-with-langchain-and-chroma/) +- [Summarize documents with Chroma, Streamlit, and LangChain](https://alphasec.io/summarize-documents-with-langchain-and-chroma/) - [Build a custom chatbot with Chroma, Streamlit, and LangChain](https://blog.streamlit.io/how-in-app-feedback-can-increase-your-chatbots-performance/) - [Build a RAG bot using Chroma, Streamlit, and LangChain](https://levelup.gitconnected.com/building-a-generative-ai-app-with-streamlit-and-openai-95ec31fe8efd) -- [Build a PDF QA chatbot with Chroma, Streamlit, and OpenAI](https://www.confident-ai.com/blog/how-to-build-a-pdf-qa-chatbot-using-openai-and-chromadb)https://www.confident-ai.com/blog/how-to-build-a-pdf-qa-chatbot-using-openai-and-chromadb +- [Build a PDF QA chatbot with Chroma, Streamlit, and OpenAI](https://www.confident-ai.com/blog/how-to-build-a-pdf-qa-chatbot-using-openai-and-chromadb) From 5a5ca65181bb62ed169b7bf1743ceb974f6940f1 Mon Sep 17 00:00:00 2001 From: "Caroline Frasca (Lu)" <42614552+carolinedlu@users.noreply.github.com> Date: Thu, 21 Dec 2023 16:31:00 -0500 Subject: [PATCH 12/18] Update streamlit.md --- docs/integrations/streamlit.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/integrations/streamlit.md b/docs/integrations/streamlit.md index 9766c69..90ac847 100644 --- a/docs/integrations/streamlit.md +++ b/docs/integrations/streamlit.md @@ -17,7 +17,7 @@ Streamlit is an open-source Python library that makes it easy to create and shar Install Streamlit:
`pip install streamlit` -Install `streamlit-chromadb-connection`, which connects your Streamlit app to Chroma DB through [`st.connection`](https://docs.streamlit.io/1.11.0/library/api-reference/connections/st.connection):
+Install `streamlit-chromadb-connection`, which connects your Streamlit app to Chroma through [`st.connection`](https://docs.streamlit.io/1.11.0/library/api-reference/connections/st.connection):
`pip install streamlit-chromadb-connection` ### Main Benefits From 40496336eb78a79f0244734d002a5397d5567a8a Mon Sep 17 00:00:00 2001 From: "Caroline Frasca (Lu)" <42614552+carolinedlu@users.noreply.github.com> Date: Thu, 21 Dec 2023 17:54:58 -0500 Subject: [PATCH 13/18] Update streamlit.md --- docs/integrations/streamlit.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/docs/integrations/streamlit.md b/docs/integrations/streamlit.md index 90ac847..660b5e9 100644 --- a/docs/integrations/streamlit.md +++ b/docs/integrations/streamlit.md @@ -51,9 +51,10 @@ st.dataframe(documents_collection_df) ### Resources +- [Instructions for using `streamlit-chromadb-connection` to connect your Streamlit app to Chroma](https://github.com/Dev317/streamlit_chromadb_connection/blob/main/README.md) +- [Demo app for `streamlit-chromadb-connection`](https://app-chromadbconnection-mfzxl3nzozmaxh3mrkd6zm.streamlit.app/) - [Guide to using vector databases with Streamlit](https://pub.towardsai.net/vector-databases-for-your-streamlit-ai-apps-56cd0af7bbba) - [Streamlit's `st.connection` documentation](https://docs.streamlit.io/library/api-reference/connections/st.connection) -- [Demo app for `streamlit-chromadb-connection`](https://app-chromadbconnection-mfzxl3nzozmaxh3mrkd6zm.streamlit.app/) #### Tutorials From f12f72fcfc79dde9736bf4142c5f2e93316cbbca Mon Sep 17 00:00:00 2001 From: "Caroline Frasca (Lu)" <42614552+carolinedlu@users.noreply.github.com> Date: Thu, 21 Dec 2023 17:55:24 -0500 Subject: [PATCH 14/18] Update streamlit.md --- docs/integrations/streamlit.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/integrations/streamlit.md b/docs/integrations/streamlit.md index 660b5e9..969353f 100644 --- a/docs/integrations/streamlit.md +++ b/docs/integrations/streamlit.md @@ -53,8 +53,8 @@ st.dataframe(documents_collection_df) - [Instructions for using `streamlit-chromadb-connection` to connect your Streamlit app to Chroma](https://github.com/Dev317/streamlit_chromadb_connection/blob/main/README.md) - [Demo app for `streamlit-chromadb-connection`](https://app-chromadbconnection-mfzxl3nzozmaxh3mrkd6zm.streamlit.app/) +- - [Streamlit's `st.connection` documentation](https://docs.streamlit.io/library/api-reference/connections/st.connection) - [Guide to using vector databases with Streamlit](https://pub.towardsai.net/vector-databases-for-your-streamlit-ai-apps-56cd0af7bbba) -- [Streamlit's `st.connection` documentation](https://docs.streamlit.io/library/api-reference/connections/st.connection) #### Tutorials From 01049e0834ac4645219dd67d9145a286c4322750 Mon Sep 17 00:00:00 2001 From: "Caroline Frasca (Lu)" <42614552+carolinedlu@users.noreply.github.com> Date: Thu, 21 Dec 2023 17:55:40 -0500 Subject: [PATCH 15/18] Update streamlit.md --- docs/integrations/streamlit.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/integrations/streamlit.md b/docs/integrations/streamlit.md index 969353f..f769b03 100644 --- a/docs/integrations/streamlit.md +++ b/docs/integrations/streamlit.md @@ -53,7 +53,7 @@ st.dataframe(documents_collection_df) - [Instructions for using `streamlit-chromadb-connection` to connect your Streamlit app to Chroma](https://github.com/Dev317/streamlit_chromadb_connection/blob/main/README.md) - [Demo app for `streamlit-chromadb-connection`](https://app-chromadbconnection-mfzxl3nzozmaxh3mrkd6zm.streamlit.app/) -- - [Streamlit's `st.connection` documentation](https://docs.streamlit.io/library/api-reference/connections/st.connection) +- [Streamlit's `st.connection` documentation](https://docs.streamlit.io/library/api-reference/connections/st.connection) - [Guide to using vector databases with Streamlit](https://pub.towardsai.net/vector-databases-for-your-streamlit-ai-apps-56cd0af7bbba) #### Tutorials From ccfc84840415c23733acdaa81495fd64f22fc797 Mon Sep 17 00:00:00 2001 From: "Caroline Frasca (Lu)" <42614552+carolinedlu@users.noreply.github.com> Date: Thu, 21 Dec 2023 17:57:48 -0500 Subject: [PATCH 16/18] Update index.md --- docs/integrations/index.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/integrations/index.md b/docs/integrations/index.md index d1f890e..77e45dc 100644 --- a/docs/integrations/index.md +++ b/docs/integrations/index.md @@ -18,7 +18,7 @@ We welcome pull requests to add new Integrations to the community. | [🦙 LlamaIndex](/integrations/llama-index) | ✅ | :soon: | | [Braintrust](/integrations/braintrust) | ✅ | ✅ | | [🔭 OpenLLMetry](/integrations/openllmetry) | ✅ | :soon: | -| [🎈 Streamlit](/integrations/streamlit) | ✅ | ✖️ | +| [🎈 Streamlit](/integrations/streamlit) | ✅ | ➖ | *Coming soon* - integrations with LangSmith, JinaAI, and more. From b4f13baec19c8fb4b3e4598da99b1e9d262424ca Mon Sep 17 00:00:00 2001 From: Jeffrey Huber Date: Fri, 22 Dec 2023 11:44:11 -0500 Subject: [PATCH 17/18] fix
--- docs/integrations/streamlit.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/docs/integrations/streamlit.md b/docs/integrations/streamlit.md index f769b03..93ad15a 100644 --- a/docs/integrations/streamlit.md +++ b/docs/integrations/streamlit.md @@ -9,15 +9,15 @@ Streamlit is an open-source Python library that makes it easy to create and shar [Apache 2.0 License](https://github.com/streamlit/streamlit/blob/develop/LICENSE)  • [Site](https://streamlit.io/) -| Languages | Docs | Github |
+| Languages | Docs | Github |
| Python | [Docs](https://docs.streamlit.io/) | [Code](https://github.com/streamlit/streamlit) ### Install -Install Streamlit:
+Install Streamlit:
`pip install streamlit` -Install `streamlit-chromadb-connection`, which connects your Streamlit app to Chroma through [`st.connection`](https://docs.streamlit.io/1.11.0/library/api-reference/connections/st.connection):
+Install `streamlit-chromadb-connection`, which connects your Streamlit app to Chroma through [`st.connection`](https://docs.streamlit.io/1.11.0/library/api-reference/connections/st.connection):
`pip install streamlit-chromadb-connection` ### Main Benefits From 2bf3c15939126677333e9aff8a670f8666ae7dfd Mon Sep 17 00:00:00 2001 From: Jeffrey Huber Date: Fri, 22 Dec 2023 11:46:16 -0500 Subject: [PATCH 18/18] add to sidebar --- sidebars.js | 1 + 1 file changed, 1 insertion(+) diff --git a/sidebars.js b/sidebars.js index 09aba83..3dd25e5 100644 --- a/sidebars.js +++ b/sidebars.js @@ -67,6 +67,7 @@ const sidebars = { 'integrations/llama-index', 'integrations/braintrust', 'integrations/openllmetry', + 'integrations/streamlit', ], }, ],