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

Questions tagged [nlp]

Natural language processing (NLP) is a field of computer science, artificial intelligence, and linguistics concerned with the interactions between computers and human (natural) languages. As such, NLP is related to the area of human–computer interaction. Many challenges in NLP involve natural language understanding, that is, enabling computers to derive meaning from human or natural language input, and others involve natural language generation.

Filter by
Sorted by
Tagged with
0 votes
0 answers
5 views

Custom Named Entity Recognition (NER) Model with spaCy V3

This is my first time building a custom model with SPACY NER. ''' Define a function to create spaCy DocBin objects from the annotated data def get_spacy_doc(file, data): Create a blank spaCy pipeline ...
user163197's user avatar
0 votes
0 answers
14 views

Fine-tuning pretrained model on 2 tasks with 2 labeled dataset

I am having difficulty using BERT for a sentiment analysis task that handles both aspect-based sentiment analysis (ABSA) and comment sentiment analysis. I know that using two separate classification ...
ndycuong's user avatar
0 votes
0 answers
13 views
+50

Calculating weighted cosine similarity between vectors of words

I have two word lists, where each word is representative of each topic. A topic is created from a collection of documents (tweets in this case). Not all words would’ve appeared an equal number of ...
Adam_G's user avatar
  • 91
0 votes
0 answers
19 views

Any resource to learn NLP and latest updates for GEN AI like research papers

Looking to start learning for industry ready(Career change) in NLP and GEN AI. Guidance will help me best like how to start, any course material and which projects to implement, where to implement(any ...
Avinash Baldi's user avatar
0 votes
0 answers
54 views

What are the ways to decrease the inference time for the Orca-mini v3_7b model on an Azure ML real-time endpoint?

What can be done to reduce inference time and achieve low latency for the deployed Orca-mini model in Azure ML? These are the steps that have been tried (more detailed info below): Different GPU SKUs ...
Demon's user avatar
  • 61
0 votes
0 answers
20 views

TF accuracy metric wants a single value - but it should want a list of probabilities [closed]

I am performing a simple seq-to-seq transformer task. I have tried various loss and metrics but none are working. Currently, in model.compile() I am using these: ...
Breck Emert's user avatar
1 vote
1 answer
19 views

Improving GPU Utilization in LLM Inference System

I´m trying to build a distributed LLM inference platform with Huggingface support. The implementation involves utilizing Python for model processing and Java for interfacing with external systems. ...
Cardstdani's user avatar
0 votes
1 answer
19 views

Data generation methods for NLP tasks

I am doing a Natural language processing related project. It is a sentiment analysis task. I need to generate a dataset for the uniqueness of the work. Is there any recommendation on how can I ...
Encipher's user avatar
  • 361
0 votes
1 answer
19 views

What to do if I have a very low metric on one of the classes during multiclass classification?

I trained multiclass text classififer with fasttext. I have a very low metric on one of the classes. Here are results of metrics for each class on test data: ...
user162857's user avatar
0 votes
0 answers
14 views

Unsupervised metrics for search engine

I'm the new one to ML, currently writing search engine with different models (tried LSTM, BERT, sentence-transformers) to get sentence embeddings, there are about 2k documents, and don't know how to ...
speedy's user avatar
  • 1
0 votes
0 answers
4 views

Leveraging Extra Data to Enhance Text Clustering

I want to cluster thousands of text data (called corpus A) and find a label for each cluster. Accuary of clustering is significantly important, because I want to use the texts and their labels for ...
Mohammadreza Riahi's user avatar
0 votes
3 answers
50 views

Why do we use similarity/cosine between Query and Key in attention?

Let's take an example sentence for translation: I am going to my home and play with toy house. For translating 'home', as per my understanding, Query will be 'house'...
Pratham's user avatar
0 votes
0 answers
10 views

jar files downloading very slowly in jupyter notebook in Mac Book(M2 pro)

Required jar files are downloading from maven repository in Jupyter notebook are very slow in Mac book (M2 pro). how can i increase the speed of download?
Tovlk's user avatar
  • 43
1 vote
1 answer
42 views

How OpenAI embeddings work?

I was looking at the Stanford CS224N NLP with Deep Learning lecture, and in the first two videos, we are introduced to word2vec models. The high-level idea mentioned was that we have a 'big corpus' of ...
mw981's user avatar
  • 13
1 vote
1 answer
27 views

Information extraction with word count limit

I have a task which I am not sure which algorithm or model to follow as a start. Suppose I have a corpus of texts. Let's assume that each set of text describes something, and the length of the text ...
Tristan Tran's user avatar
0 votes
0 answers
12 views

How can self-attention be used to combine representations from long text?

The paper "How to Fine-Tune BERT for Text Classification?" discusses using self-attention to combine the representations of a long input text that has been broken into chunks (section 5.3.1)....
suse's user avatar
  • 3
0 votes
0 answers
109 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
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
1 answer
27 views

Implementing Data Isolation in an RAG System in GCP using any of the LLM models

I am currently working on developing a Retrieval Augmented Generation (RAG) system where User-1 and User-2 each have their unique set of documents. My goal is to create a system where User-1's queries ...
ENAT's user avatar
  • 1
3 votes
0 answers
39 views

Weird behaviour when using RobERTA for text classification

I have a dataset with around 70 classes and the dataset is largely balanced ~150 samples per class. I am finetuning RoBERTA-base for 4 epochs with a ...
user1274878's user avatar
1 vote
1 answer
39 views

How to choose a loss function and how to calculate the loss for Text Generation in Generative AI?

For the classification problems, what loss functions can I choose ? For the translation problem how do I decide whether the translation is good and how to choose a loss function? And what about the ...
Qiulang's user avatar
  • 133
1 vote
0 answers
75 views

Using UMAP on text data (euclidean distance on jaccard distance matrix)

I am checking the capabilities of the UMAP dimensionality reduction algorithm, I am not sure whether the approach I am using is valid and does not violate the rules/limitations of this algorithm. ...
rkabuk's user avatar
  • 21
1 vote
0 answers
18 views

Train a LLM to learn the entropy of the use case

I want to train a LLM (prefered Llama-2-13b) to learn the entropy of german texts - to be specific sports news. I use perplexity as training metric and want to check the training success after the ...
Christian01'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
30 views

How do you train a seq2seq model on sequences longer than its sequence length?

I was reading the GPT original paper here and in section 3.5 they mention evaluating on the CoQA dataset. I checked GPT has a sequence length of 512, yet most of the sequences in the CoQA are a few ...
Ameen Izhac's user avatar
0 votes
0 answers
10 views

keyword extraction and link to multiple sources

I have to perform a tech watch over a very rich subject which spans from software to deep physical issues and also, from business news to scientific articles. Usually, I would have first retrieved the ...
deb2014's user avatar
0 votes
0 answers
10 views

Problem when merge two probability distribution [Pointer Network]

I'm trying to re-implement Pointer Gen Net from this paper. Ya but you don't really need to read the paper. To sum up briefly, I have a vector probability distribution over vocabulary called p_vocab. ...
jupyter's user avatar
  • 101
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
0 answers
19 views

Finding accuracy of model that uses different labels than ground truth

I have an nlp model that has ground truth labels and predicted labels (that belong to different group of classes). For example, the ground truth labels are [art, computer science, history] and ...
Vidushi Maheshwari's user avatar
1 vote
1 answer
33 views

Reducing emails token count preprocessing for Large Email Datasets - Feeding LLMs

I have a large email dataset in .txt format and want to feed LLMs (like Gemini and ChatGPT) to provide answers based on email content. The token count for my email data is very high (~1M for 1K emails)...
Rafael Borja's user avatar
4 votes
1 answer
1k views

How do I prompt GPT-4 to look at a PDF in Jupyter Notebook?

I am a beginner. I purchased tokens to use GPT-4 and finally figured out how to import the GPT-4 model into my Jupyter Notebook. ...
Mas's user avatar
  • 55
0 votes
0 answers
29 views

Multilabel Classification - Flat Binary Classifiers vs Hierarchical Binary Classifiers

Was researching on multi label classification to solve the problem of tagging news articles with topics and countries, where tags follow the syntax <topic>-<country>, and would like to ...
curious-24-7's user avatar
0 votes
0 answers
21 views

Fine tuning a model for question-answering task without context on the dataset

I have a small dataset (contains around 2.5k question answer pairs) which I would like to train a T-5 base model on. The code examples that I have came across fine-tune with a dataset which has ...
Nabid Hasan's user avatar
0 votes
0 answers
7 views

Subsequence classification

Given multiple paragraphs, is it possible to classify an entire paragraph while taking into account the surrounding paragraphs? Paragraph1 Paragraph2 Paragraph3 ...
BPDev's user avatar
  • 101
0 votes
0 answers
24 views

How is a causal language model correctly fine-tuned?

I want to fine-tune an SLM like Phi-2 through the huggingface API. I am in doubt how to achieve that, because I see two ways to do that and I am wondering which is the correct way. The task is just a ...
Marcel Braasch's user avatar
0 votes
0 answers
10 views

Which model and embedding to use for portuguese chat with docs

I would like to have a model to read all my personal documents, meeting notes and things like that, all text based, and then be able to ask questions like: what was decided about the feature x? what ...
Kelly Goedert's user avatar
0 votes
0 answers
21 views

Insights about W0rd2Vec

As per my knowledge, Word2Vec is belongs to non-contextual embedding technique. this have only semantic relationship between words. We can implement Word2Vec, either in CBoW or skip-gram model. but i ...
Tovlk's user avatar
  • 43
0 votes
0 answers
11 views

Is this how you would go about this NLP Project?

What do you think of these steps? And where can I find help with this project? I am in a business class and was assigned a data science problem. I was advised to seek out a coder at my school who can ...
Layla M's user avatar
1 vote
1 answer
166 views

How is openAI embedding models trained?

how it the embedding model trained? Are the embeddings simply extracted from chatGPT4 or are they trained differently from the beginning (pre-training stage)?
haneulkim's user avatar
  • 469
0 votes
1 answer
20 views

Question about contextual embeddings?

How do BERT and RoBERTa generate contextual embeddings? The articles I've read keep saying that transformer encoders work bidirectionally. Because of self-attention, they can look at every token, ...
user avatar
0 votes
0 answers
42 views

Stream response from custom RASA actions to the chatbot

I am using RASA PRO with CALM. I was thinking of using openai api within a custom action and stream the streaming response coming from openai to my chatbot. Openai is giving me streaming response and ...
Avatar's user avatar
  • 1
1 vote
0 answers
38 views

Best practises for creating datasets for the purpose of finetuning LLMs

I am working on a problem for which no datasets exist. I have obtained several examples from this domain, and so far have been using them in Large Language Model (LLM) prompts(few shot learning) but I ...
Karl 17302's user avatar
0 votes
0 answers
13 views

Implementing Fuzzy Matching and NLP for Transaction Classification

I’m a trainee at a fintech startup, and I’m working on a project that involves classifying transactions using Natural Language Processing (NLP) and fuzzy matching techniques. The main goal is to ...
RAN's user avatar
  • 1
0 votes
0 answers
9 views

Do LSTM, GRU and Transformer models with less layers and units perform better than larger models when classifying short text sequences?

I am working with a Kaggle dataset with short Twitter messages as text input. I made a copy here. When testing LSTMS, GRUs, bi-directional versions of the GRUs, and the Encoder layers of a Transformer ...
Joachim Rives'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
10 views

Commonly used metric in NLP literature to compare ranked weighted results with variable importance for top-k results

I have two different search engines that always return the same results but in different orders. The results consist of websites along with confidence scores, which range from 100 to 10,000. The ...
hanugm's user avatar
  • 157
4 votes
1 answer
103 views

LLMs for text generation

We know that AI is rapidly growing. do we have any large language models (LLMs) to process images, pdf documents directly (fine-tune approach) for text generation tasks?
Tovlk's user avatar
  • 43
0 votes
0 answers
28 views

Similarity Scores between SQL tables

I'm trying to figure out the best way to get started on a project. I have two separate databases, one is a "Template" db and the other is "Content" db. For each table in the ...
Marc J's user avatar
  • 1
0 votes
0 answers
9 views

Character-wise accuracy for image-to-text models

is it possible to enforce image-to-text models like ViT or a simple CNN+Transformer to achieve character-wise accuracy? Here's the context of my project: I am developing a model to extract some ...
CarlV's user avatar
  • 1
0 votes
1 answer
31 views

What's the purpose of using MLM when pretraining?

If BERT is a stack of transformer encoders, and the encoder already operates bidirectionally, understanding both left and right contexts and generating contextual embeddings, what is the purpose of ...
user avatar

1
2 3 4 5
56