Comments (7)
I recently published a package llm-client that can be very helpful in enabling the support to run other LLM models, including OpenAI, Google, AI21, HuggingfaceHub, Aleph Alpha, Anthropic, Local models with transformers.
from mem0.
Thanks for sharing the codes that have very user-friendly simplified APIs.
First of all, why created the ChromaDB
class when LangChain have Chroma
class? You can find more information at https://python.langchain.com/docs/modules/data_connection/vectorstores/integrations/chroma
By the way, I forked the repo and the following points are written near the top of the readme:
https://github.com/limcheekin/embedchain
- This is the fork of Embedchain to run with OpenAI API compatible llama-cpp-python Web Server. Hence, you can run the Embedchain with any LLMs supported by
llama-cpp-python
package. - The notebook
embedchain.ipynb
is created to quick test the integrations is working fine. It is tested with orca-mini-7b.ggmlv3.q4_0. - Use of
HuggingFaceEmbeddings(model_name="intfloat/e5-large-v2")
instead ofOpenAIEmbeddings
as the embedding endpoint of the llama-cpp-python Web Server is too slow and using too much compute resources to be usable. Hence, you need to install additional dependency, thesentence_transformers
package in order to run the notebook successfully.
You can review all my changes in a single commit.
I'm happy to work out a proper pull request if you're interested to merge my changes.
Thanks.
from mem0.
- Can the LLMs be replaced with Open commercial LLMs like Dolly in place of OpenAI? (from Ranganathan Rajkumar on linkedin)
from mem0.
Yes, you can replace the OpenAI to any open source commercial friendly LLMs listed at https://github.com/eugeneyan/open-llms, including Dolly.
Besides that, you need to replace the text embedding model of OpenAI such as text-embedding-ada-002 to the open source alternatives listed at https://huggingface.co/spaces/mteb/leaderboard.
That's what I did for the chatbot I'm working on currently.
The challenges is find the right models that fulfilled with your use cases and requirements with acceptable quality for given constraints in resources such as computes, memory and storage.
(I replied to the linkedin link too)
from mem0.
For you information, I created a project at https://github.com/limcheekin/open-text-embeddings.
The following is short description of the project extracted from the readme:
The goal of this project is to create an OpenAI API-compatible version of the
embeddings
endpoint, which serves open source models such asintfloat/e5-large-v2
,sentence-transformers/all-MiniLM-L6-v2
,sentence-transformers/all-mpnet-base-v2
, and other sentence-transformers models supported by the LangChain's HuggingFaceEmbeddings class.
Please see the readme on how to use it in your project. By the way, I just added support for https://tfhub.dev/google/universal-sentence-encoder-large/5, please checkout the universal_sentence_encoder
branch of the repo.
from mem0.
I'm trying https://github.com/oobabooga/text-generation-webui/ as a backend since it supports LLaMa-2 and exposes it at http://0.0.0.0:5001/v1
Now how do I point embedchain at it?
I only see in README to do:
import os
from embedchain import Llama2App
os.environ['REPLICATE_API_TOKEN'] = "REPLICATE API TOKEN"
zuck_bot = Llama2App()
# Embed your data
zuck_bot.add("youtube_video", "https://www.youtube.com/watch?v=Ff4fRgnuFgQ")
zuck_bot.add("web_page", "https://en.wikipedia.org/wiki/Mark_Zuckerberg")
from mem0.
We now support most of the popular llm providers so will close this issue now.
from mem0.
Related Issues (20)
- idek
- idek
- idek
- idek
- idek
- idek
- idek
- Sth wrong with using Ollama +qdrant:Vector dimension error: expected dim: 1536, got 768 HOT 10
- Groq not worked HOT 1
- Azure OpenAI LLM not working
- how the memory adaptive learn or forget ability realize
- mem0 doesn't have a license HOT 3
- Integrate Portkey LLM Gateway
- [Improt error]mem0.embeddings.huggingface: ModuleNotFoundError: No module named 'embedding'
- [Bug]The huggingface embedding method name should be `embed`
- Update azure_openai.py to use langchain_openai.embeddings HOT 1
- User id of memory is missing after updated HOT 3
- Redundant Vector Store Creation in Memory Initialization
- Pytests for embedchain - openai fail
- Support OpenAI-compatible API request
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from mem0.