LangChain – Using Hugging Face Models locally (code walkthrough)
AI技術はますます進化し、私たちの生活やビジネスに革新的な変化をもたらしています。その中でも、HuggingFaceというプラットフォームは、自然言語処理(NLP)に特化したモデルやリソースを提供することで注目を集めています。
HuggingFaceの魅力は、APIエンドポイントを介して利用できないモデルをローカルで読み込むことができる点にあります。このColab Code Notebookでは、エンドポイントの使用方法だけでなく、ローカルでモデルを読み込む方法や埋め込みモデルをローカルで利用する方法も紹介されています。
さらに、著者のSam Witteveen氏はTwitterやLinkedinなどのSNSプラットフォームで積極的に情報発信しており、Github上でも関連するチュートリアルやプロジェクトを公開しています。彼の情熱と専門知識が詳細な記事や手順書に反映されており、AI技術への理解を深める手助けとなっています。
HuggingFaceとSam Witteveen氏が提供する情報は、AI技術への関心が高まる中で必見です。彼らの取り組みは、AI技術の普及と発展に貢献しており、今後も注目が集まること間違いありません。
really good!
is there a way to compile a huggingface repo to a single safetensors file? (compiled from a repo that has the separate directories: scheduler, text_encoder, text_encoder_2, tokenizer, etc…)
saved me from hours of debugging and research! thanks a ton
Hello. Can you please make a video on how to use the SeamlessM4T HuggingFace model with langchain ? Particularly for text to text translation. I am trying to do some prompt engineering with the model using Langchain's LLMChain module. But it does not seem to work …
How can I load the model for some time later, once I download it on the local drive
and how can I use big models from huggingface ? I can't load them into memory because many of them are bigger than 15gb, some of them are 130gb+ . Any thoughts?
Please make a video on how to convert Safetensors to. GUFF format or format that can be used for Ollama? Thanks for these great AI videos!
thx! helped a lot! but stuck at loading model…it says google/flan-t5-xl is too large to be loaded automatically (11GB > 10GB)….qaq
This is helpful because in some industries like banking or telcos, it's impossible to use open source things. So we need to host.
Hello, Thanks for your video. for now it's : llm_chain = LLMChain(prompt=prompt,
llm=HuggingFaceHub(repo_id="google/flan-t5-xxl",
model_kwargs={"temperature":0.9,
"max_length":64}))
temperature must bu >0 and model : flan-t5-xxl
Great video sam , i don't know how i missed this
Hi Sam, Is there any way to generate question answer from a given text in a .txt file and save those questions answers in another .txt file with the help of free huggingface model?
how to do telegram chatbot with this
Thanks for the content!! Is there a way to run a HuggingfacePipeline loaded model using M1/M2 processors on Mac? How would one set that up?
I was trying to utlize the nootebook on collab , lot of errrors and needs to debug
Ok, great tutorial, but as a French from Bordeaux, I am deeply disappointed by the answer of google about the best area to grow wine.
Loire valley ? Seriously ???? Name one great wine coming from Loire, Google, I dare you.
They are in the b league at best.
The answer is obviously Bordeaux, I would maybe had accepted Agen (wrong) or even Bourg*gne (very very wrong).
But Loire, it's outrageous and this answer made me certain that I will never use this cursed model.
If we cannot afford to get A100, what's the cheaper option you would recommend to run these? I understand the models differ in size also. Thanks Sam.
Great tutorial. I need to train a model on some private company documents that aren't publicly released yet and this looks like it could be a big help to me. Subbed!!
u are not doing it locally in this video…..
how to fine tune this model so that it can follow instructions on data provided
How can the ready-made projects on the platform be linked to Blogger blogs? I have long days searching to no avail
Stupid question, so I'll take a link to another video/docs/anything. Which Python version, cuda version, pytorch is the best to use for this work? I see many using python 3.9 or 3.10.6 specifically. The pytorch site recommends 3.6/3.7/3.8 on the install page. Then the cuda version 11.7 or 11.8 – it looks 11.8 is experimental? Then when I look at my nvcc output its says 11.5, but my nvidia-smi says cuda Version 12.0 .. head explodes… I'm on Ubuntu 22.04. I will google some more, but if someone know the ideal setup.. or at least the it works setup.. I appreciate it!!! Thank you
Just curious, do you need to redownload the model everytime you run scripts like these? Is there a way to save the model and use it after it's been downloaded?
Hi.. i would like to know that, Can we chain 2 models like a classification model and a pretrained model using langchain?
Would be useful if you explained what program your using, or what page your looking at, seems like waste of time if you don't know anything about the programs or what your doing 1/5