Skip to main content
Share Your Experience: Take the 2024 Developer Survey

Questions tagged [huggingface]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
-1 votes
0 answers
17 views

In what format should the correspondence data be provided for training the neural network model?

I have correspondence between users and technical support. I want to train an int float/multilingual-e5-large model based on technical support responses. Tell me, please. How can I do this? What ...
7wafer7's user avatar
0 votes
0 answers
14 views

Instruction LLM - extract data from text wrongly continues

I'm trying to fine-tune open sourced LLMs, for now let's stick with Mistral-7b-instruct model. My task is a follow: I have emails, that represents "price requests" for shipments sends by our ...
sagi's user avatar
  • 101
2 votes
1 answer
33 views

Since LoRA parameters are randomly initialized, shouldn't that mean that initially breaks a models output?

I have just tried using LoRA on Llama 3 8B and I found without doing any fine tuning it performed pretty well on my dataset. But then I realized that surely the LoRA parameters are randomly ...
Ameen Izhac's user avatar
0 votes
0 answers
83 views

"No sentence-transformers model found with name" on huggingface even though it exists

I am trying to use infgrad/stella-base-en-v2 on hugging to generate embeddings using langchain The model exists on the huggingface hub The model is listed on the MTEB leaderboard The model has ...
figs_and_nuts's user avatar
0 votes
0 answers
9 views

Not able to use huggingface inference API to get text embeddings

From the tutorials I am using the example that is provided ...
figs_and_nuts's user avatar
1 vote
1 answer
32 views

How do I get model.generate() to omit the input sequence from the generation?

I'm using Huggingface to do inference on llama-3-B. Here is my model: ...
Ameen Izhac's user avatar
0 votes
0 answers
9 views

Does Fine Tuning with Custom Label Build Upon the Capability of Zero Shot Classification or Does It Train from Scratch?

The task is to classify email text bodies into exclusive categories like feedback, complaint etc. I have a labelled dataset available having about 350 samples. I have tried the ...
Della's user avatar
  • 335
1 vote
1 answer
20 views

Public Email Classification Dataset but not Spam vs Ham

Context Working to deliver a POC on automated email classification (in customer service context) to tag emails as related to feedback, complain, lost and found etc. The tags are not entirely exclusive,...
Della's user avatar
  • 335
0 votes
1 answer
31 views

Generate VTT file from speech to text

I was able to generate text from an audio file using huggingface, using this code ...
Kelly Goedert's user avatar
0 votes
0 answers
11 views

Training split generation - Extremely Slow

I am fine-tuning mbert on wikipedia dataset, loaded with Datasets (Hugging face) ...
lingvenvist's user avatar
0 votes
0 answers
8 views

Will hypermeters tuned on sampled dataset work for the whole dataset?

I'm doing multi-label classification on text data using BERT model. Since the dataset is huge, around 50 thousand rows, I was thinking to use stratify sampling on dataset to reduce it to around 2-4 ...
Shaurya Uniyal's user avatar
0 votes
0 answers
6 views

dimensions conflict when trying to use a pretrained wav2vec2-xls-r-300m model

i am trying to use a pretrained model facebook/wav2vec2-xls-r-300m and fine tune it for audio classification and more specifically emotion recognition. i am using an audio labeled dataset ( 12 labels )...
stanley101's user avatar
0 votes
0 answers
24 views

How to find LLM that is best at STS task?

I'm trying to find large language models that maps an embedding vector in proximity if they are semantically similar, in Korean. I tried looking at bunch of leaderboard such as MTEB_ko-ko STS, AI Hub ...
haneulkim's user avatar
  • 469
0 votes
0 answers
9 views

Reducing language bias for text classification, transformer model

I am working on a text classification model predicting classes for text. We have languages from many parts of the world and some of our classes are dominated by specific languages. The model we are ...
Carl Rynegardh's user avatar
0 votes
0 answers
70 views

Safetensors are slower than torch.load. Why?

Lately, I have been testing safetensors. It claims that the safetensors are faster and safer than pickle. So I did my own comparison with the code below: ...
mark's user avatar
  • 103
0 votes
1 answer
26 views

Getting rid of the warning "The following columns ... have been ignored" and "ValueError: batch_size should be a positive integer value ..."

I train a fine-tuning model with the PyTorch Trainer class: ...
questionto42's user avatar
0 votes
1 answer
122 views

Outdated Transformers TextDataset class drops last block when text overlaps. Replace by datasets Dataset class as input of Trainer train_dataset?

Why I try to replace the transformers TextDataset class with datasets Dataset class I stumbled upon this when I tried to make ...
questionto42's user avatar
0 votes
0 answers
17 views

How to perform inference on a finetuned falcon 7b model fine tuned on open assistant dataset

I finetuned a falcon 7b model on the open assistant dataset using the official colab notebook provided by huggingface at https://colab.research.google.com/drive/1BiQiw31DT7-cDp1-0ySXvvhzqomTdI-o?usp=...
Saket Vempaty's user avatar
1 vote
1 answer
42 views

Falcon-7B llm giving random output

I am using a falcon 7B model for a chatbot without any finetuning with the following code ...
Saket Vempaty's user avatar
0 votes
2 answers
423 views

How can you get a Huggingface fine-tuning model with the Trainer class from your own text where you can set the arguments for truncation and padding?

I want to find out the role of truncation and padding in Huggingface Transformers pretrained models and any fine-tuning model on top of that. Therefore I played around with these parameters, but I ...
questionto42's user avatar
2 votes
2 answers
924 views

Should you care about truncation and padding in an LLM even if it has a very large tokenizer.max_length so that truncation will never happen?

I want to find out the role of truncation and padding in Huggingface Transformers pretrained models and/or any fine-tuning models on top. Taking a large language model like the German GPT2 shows that ...
questionto42's user avatar
1 vote
0 answers
60 views

Could someone help with fine-tuning dolphin-2.2.1?

Could someone help with fine-tuning dolphin-2.2.1? I have a problem with training: my train\loss - 0 and validation\loss - 0.000... after 800-1000 steps and this is overfitting ...
kabba62's user avatar
  • 11
0 votes
1 answer
28 views

Multilingual sentence generation with Hugging Face

For an application I need to generate some random sentences, i.e. I don't need the output sentences to have any specific link to the prompt other than using the same language. If possible I need this ...
Erwan's user avatar
  • 25.5k
0 votes
1 answer
72 views

RuntimeError: mat1 and mat2 shapes cannot be multiplied (25x7 and 1x512)

I am dealing with multivariate time series forecasting using Transformers. below is my code step by step: After some preprocessing and windowing time series dataset … 1- Creating Mask function ...
Amir's user avatar
  • 1
1 vote
1 answer
40 views

Understanding processors in huggingface tokenizer library

tl;dr What are the :0 and :1 in the following huggingface processors reference usage given on their page: ...
figs_and_nuts's user avatar
1 vote
0 answers
111 views

Fine-tuning Hugging Face’s Llama Model with Unlabelled Data from PDFs from niche domain

I’m unsure about the next steps. Specifically, I have the following questions: How can I prepare my unlabelled data for the fine-tuning process? What’s the best way to fine-tune the Llama model with ...
Divya Patel's user avatar
0 votes
0 answers
56 views

What happens when I set is_decoder to True in the bert API from huggingface?

Please help me understand the implications of initialising the bert model from huggingface with is_decoder parameter set to True ...
figs_and_nuts's user avatar
0 votes
1 answer
155 views

Open-Source Large Language Models (LLM): Your experience and recommendation

I’m looking for an open-source LLM for a new project. I want to use it for instructions and to fine-tune the model to a specific domain like legal and rights. Some LLMs are open-source, but they didn’...
Christian01's user avatar
0 votes
0 answers
35 views

F1 and Exact-Match (EM) Score in Extractive QA NLP

I have a question as to how the F1 should be calculated in NLP and whether the text normalization is optional or not. So I have been working on a project where we created a closed-domain extractive QA ...
tt40kiwi's user avatar
  • 101
0 votes
0 answers
64 views

How to use Bertweet model for topic modeling

The problem is implementation of Bertweet in a topic-modeling project with understandable output like BERTopic, i want to use it on a relatively large (20k tweets) unlabelled dataset to segment it ...
Rossin's user avatar
  • 1
0 votes
0 answers
306 views

How to get Llama-2 Rotary Embeddings?

I want to get the Llama-2 rotary embeddings. I do print(model) and get the following output: In the picture I highlight the rotary embeddings. How can get the ...
Christian01's user avatar
0 votes
0 answers
28 views

Errors in results after saving model vs using directly from memory

I am trying to save a Fine Tuned model using trainer.save_model() but after I load the saved_model it just responds with the input back again and does not give any ...
Nikhil Verma's user avatar
0 votes
0 answers
220 views

Specifying arguments of HuggingFaceHub

In this tutorial, when specifying llm = HuggingFaceHub( repo_id=repo_id, model_kwargs={"temperature": 0.5, "max_length": 64}) only ...
Karl 17302's user avatar
1 vote
1 answer
444 views

How to Use Multiple Adapters with a Pretrained Model in Hugging Face Transformers for Inference?

I have a pretrained Llama-2 model in the models_hf directory and two fine-tuned adapters: a summarization adapter in ...
Aun Zaidi's user avatar
1 vote
0 answers
68 views

Deploying a model with GPU and pay-per-inference

I may have the wrong stack exchange. If that's the case, could someone point me to a stack that could help with this. Anyways... My backend employs a sentence transformer model from HuggingFace. Since ...
AlwaysLearning's user avatar
0 votes
0 answers
25 views

How can BERT/Transformer models accept input batches of different sizes?

I understand that all inputs in a batch need to be of the same size. However, it seems BERT/Transformers models can accept batches with different sizes as input. How is that possible? I thought we ...
PS1's user avatar
  • 101
0 votes
0 answers
14 views

Create samples out of documents for Causal Language Modelling

I want to create an input source for Causal Language model using Llama 2 model in hugging face. I have a set of documents which are scraped from a specific website and want to fine-tune on them. Each ...
Dimits's user avatar
  • 11
0 votes
0 answers
421 views

Adapting a BERT-based model from HuggingFace for NER (named entity recognition) and RE (relation extraction)?

Context: NER (named entity recognition) and RE (relation extraction) from sentences obtained from radiology reports (medical text). There is a BERT-based model from HuggingFace I would like to use for ...
Pablo Messina's user avatar
0 votes
0 answers
19 views

Decoder model selection for sequence-to-sequence ASR with XLS-R

I am new to building models for Speech ASR. I want to build a model for Speech Transcription in Urdu. I used XLS-R (following the example by Patric von Platen on Huggingface Colab notebook. My ...
Aun Zaidi's user avatar
0 votes
0 answers
139 views

Fine-Tune Llama on main and auxiliary task

I am trying to fine-tune Llama model on two task at the same time, using hugging face library: Main task: Causal language model like the model was initially trained for A classification task based on ...
Dimits's user avatar
  • 11
0 votes
1 answer
824 views

Can I run falcon-7b on a free google colab?

I'm a beginner at ML and AI. Background: I wanted to try out falcon-7b, the example I'm trying out: https://colab.research.google.com/drive/1BiQiw31DT7-cDp1-0ySXvvhzqomTdI-o?usp=sharing (Falcon-...
hungryWolf's user avatar
0 votes
0 answers
22 views

Sentiment extraction with hugging face ready to use model

I have a set of reviews for which I need to extract their sentiments and use those sentiments as an independent variable in an econometric model. I used one of the ready-to-use models of hugging face ...
m sh's user avatar
  • 3
0 votes
0 answers
40 views

Which language model to use for this use case? [Finetuning on custom dataset]

An example from my train data is as follows: ...
ksgr5566's user avatar
  • 101
0 votes
0 answers
185 views

Multiple CSV files input for hugging face table question-answering in Python

I am trying to write a code in HuggingFace Python to input multiple CSV files and feed them to the tokenizer for table question-answering. If I were to input only one CSV file, the code would look ...
Ramin Salimi's user avatar
0 votes
0 answers
13 views

Large Language model for regression on urls

I am trying to fit a BERT model for a URL regression task. I have a URL as a feature and I have to predict a metric M for it. Keeping a learning rate like $10^{-5}$, the model is overfitting in about ...
guesta's user avatar
  • 1
1 vote
0 answers
210 views

How to load Hugginface model on CPU?

My system runs out of memory on GPU. But I want just to test if it works and want to load it on CPU. How do I do that? Adding device = torch.device(‘cpu’) before ...
Myron's user avatar
  • 123
0 votes
0 answers
19 views

"Probabilistic" One-Hot-Encoder for transformers library

I'm using the transformers library to fine-tune a LLM for classification. However, my problem is a bit particular, as the labels are hierarchical, that is, in the form A-1, A-2, B-1, B-2 etc. ...
EzrielS's user avatar
  • 323
2 votes
1 answer
162 views

How can someone evaluate llama index model?

I have built a openAI llama index based model which takes multiple pdf and able to give chatbot based response. I want to evaluate the llm for accuracy. I already know method such as Rouge and Bleu. ...
Prashant Pandya's user avatar
3 votes
1 answer
2k views

LMM Fine Tuning - Supervised Fine Tuning Trainer (SFTTrainer) vs transformers Trainer

When should one opt for the Supervised Fine Tuning Trainer (SFTTrainer) instead of the regular Transformers Trainer when it comes to instruction fine-tuning for Language Models (LLMs)? From what I ...
Marvin Martin's user avatar
0 votes
0 answers
71 views

What is exactly the difference between Huggingface, MLserver and seldon core?

Kind of a newbie to practical ML development. As far as I can understand, huggingface provides packaged, ready to deploy, pre trained ML models, whereas MLserver and seldon core are used to actually ...
thoraway121's user avatar