Questions tagged [stanford-nlp]
Questions on the open source natural language processing software from the Stanford University NLP Group, in Java, Python, and C, including Stanford CoreNLP, Stanza, and GloVe.
3,300
questions
-4
votes
0
answers
22
views
My manager has asked me to make the custom GloVe model and he also mentioned that take any available data for training . So how can i do this? [closed]
I am trying but not able to get on the right track. Please you guys explain from the scratch
0
votes
0
answers
5
views
What is the key difference between graph-based QA and QA by semantic parsing?
Folowing D. Jurafsky handbook, i struggle with the chapter on QA.
It defines 2 paradigms of QA knowledge based which are:
graph-based QA (1)
QA by semantic parsing (2)
For (1) it takes the exemple: &...
0
votes
1
answer
24
views
Named Entity Recognition by dictionary in text
I need to extract keywords from text. I have a dictionary of keywords, let's say
apache-spark
java
pathon
amazon-web-services
apache-kafka
and I have a job post for example:
Design, develop and ...
0
votes
1
answer
31
views
Can someone explain how to create a PTB Dataset And/Or Train my own model using StanfordNLP?
I'm learning about sentiment analysis and I can't seem to find anything online that outlines how to create a PTB Dataset. I'm using StanfordNLP with Java. I've downloaded the test, dev and validate ...
0
votes
0
answers
13
views
Unable to get SVO Triples when using a different unit of measure
I am experiencing something that I think should work in CoreNLP. I am using openjdk 11.0.18 2023-01-17 LTS on CentOS and a very simple OpenIE example. I wired up corenlp 4.5.2, as show in my build....
0
votes
0
answers
13
views
Calculating Syntactic Similarity between two sentences using Stanford Parser
I'm calculating syntactic similarities between two sentences by generating a parse tree and calculating the difference between two trees and using Stanford Parser. It's working well. But the thing is, ...
0
votes
2
answers
32
views
Stanza based auto-py-to-exe GUI app throws exception (Windows 10)
I am building a Window based .exe for a python script using auto-py-to-exe. It uses Stanza. I am able to build and run the Console based version of the app (the GUI + Console). But the GUI only .exe (...
2
votes
1
answer
20
views
Identify and correct mistakes in Q&A datasets for natural language processing (NLP)
How do you identify and correct mistakes in Q&A datasets that contain errors, such as incorrect answers or missing information, and ensure the accuracy of the dataset?
Let's say I got thousands of ...
0
votes
0
answers
21
views
getting error for the Sandford nlp lib as couldn't find the jar file
I was trying this lib in python
from nltk.parse import stanford
import os
# Set the path to the Stanford Parser JAR file and models
os.environ['CLASSPATH'] = '/path/to/stanford-parser.jar'
os.environ[...
1
vote
1
answer
44
views
How to see if one Nokogiri::XML::Node contains parts of another Nokogiri::XML::Node?
Using ruby Nokogiri I have a Nokogiri::XML::Node object (ConstituencyXMLNode inherits from Nokogiri::XML::Node) that is a tree object like such:
#(ConstituencyXMLNode:0xc3c8 {
name = "PP",
...
0
votes
0
answers
27
views
Stanza Visualizations using SpaCy Interface
The attached code comes from the stanza library and from what I’ve gathered converts a stanza object to space to visualize a NER object. The code returns nothing if I run it in a notebook but using ...
0
votes
0
answers
22
views
Why can't i load stanza models?
I'm trying to use the python packages stanza and when i'm simply trying to download a model (french or english)
using : stanza.download('en')
I get an error when i'm around 5/6 %
I'm expecting to be ...
0
votes
1
answer
49
views
How to store Stanza Span in MongoDB collection?
I am trying to add a list of dictionaries (whose name is stanzanerlist) like the following:
stanzanerlist = [{
"text": "Harry Potter",
"type": "PER",
&...
0
votes
1
answer
37
views
How do I merge rows of data with the same ID but different data in other columns and remove duplicate contiunous words?
I have a set of data in a pandas dataframe
ID
Date
Location
Text
123456
01/01/23
Paris
Reported Problem:
123456
01/01/23
Paris
Reported Problem: One Plus One Is Not Three
123456
01/01/23
Paris
...
0
votes
0
answers
32
views
Eclipse edu.stanford.nlp Error: Could not find or load main class
Been working on this error since 2 days and cant find a solution: I'm trying to run edu.stanford.nlp. in my java project in Eclipse.
Done so far:
Installed maven, extracted the latest stanfordnlp-...
0
votes
0
answers
23
views
Stanford CoreNLP in R: adding Italian language
I would like to use the Stanford CoreNLP package in R for processing text in Italian, but the Italian language is not included:
coreNLP::downloadCoreNLP(type="italian") Error in match.arg(...
1
vote
1
answer
121
views
Challenging problem: How to find near duplicates for string?
I have a dataset that consists of over 50000 names. There are a lot of near duplicates inside because of how these names were entered into the system.
The ideal solution should flag clusters of ...
0
votes
0
answers
30
views
Suggested approaches to Named Entity Linking of PERsons after Stanford's STANZA NER (NLP)
I am using a Stanza pipeline to do NER on news article in Italian and am satisfied with the PERsons spans that it detects.
How would you suggest I attempt linking the identified PERson entities with ...
1
vote
0
answers
20
views
Ratios of co-occurrence probabilities can encode meaning components
I'studying NLP these days through CS224N, which is NLP lecture in Stanford, and I had a question of co-occurrence probability.
I can understand that each first row and second row shows co-occurrence ...
0
votes
0
answers
9
views
Nouns with hyphens or slashes in coreNLP
The code below works well for full nouns but I have text where a single noun can have hyphens or slashes in them. What should I do to accommodate that?
c/h, for instance, is a valid abbreviation as in ...
0
votes
0
answers
16
views
How to Detect Present Simple Tense in English Sentences using a Rule-Based Approach?
I have a straightforward task of determining the sentence structure, specifically to identify if a sentence written in plain English is in the "present simple" tense. I am aware of a couple ...
0
votes
0
answers
28
views
Where do I find Stanford NLP Tagger training files for: english-left3words-distsim.tagger
I am trying to understand how to train my own tagger in Stanford NLP. How do I get the training files for:
english-left3words-distsim.tagger
It lists these files in the props file, but not too sure on ...
0
votes
0
answers
46
views
How to get original token position in string from Stanza constituency parse tree?
I am using Stanza to extract noun phrases from texts. I am using this code to extract the NPs and store them according to their depth.
nlp = stanza.Pipeline('en', tokenize_pretokenized=True)
...
1
vote
1
answer
36
views
NoneType erorr when calling .lower() method on annotated text
I have annotated articles in a list (len=488), and I want to apply the .lower() method on the lemmas. I get the following error message AttributeError: 'NoneType' object has no attribute 'lower'. Here'...
0
votes
0
answers
23
views
stanza: add double linebreaks in list of articles (batching to speed up stanza nlp pipeline)
I have a list of articles and want to apply stanza nlp to them, but running the code (in Google Colab), stanza never finishes. Online (https://github.com/stanfordnlp/stanza) I found that separating ...
1
vote
1
answer
73
views
fine tuning word2vec on a specific article, using transfer learning
i try to fine tune an exicting model on specific article. I have tried transfer learning using genism build_vocab, adding gloveword2vec to a base model i trained on the article. but the build_vocab ...
0
votes
0
answers
21
views
Facing error while loading GloVe word vectors in python dictionary
I've downloaded pretrained word vector glove.840B.300d.txt from GloVe: Global Vectors for Word Representation. Now, I want to load them into a python dictionary but getting an error.
for line in open(&...
0
votes
0
answers
21
views
Glove Vector based model prediction
I trained a model to multilabel input text using glove Vectors.
The model is trained and the tokenizer is also ready but i dont kow how to predict a new input
i tried
X=tokenizer.texts_to_sequences([&...
0
votes
0
answers
216
views
`TypeError: Couldn't build proto file into descriptor pool: duplicate symbol 'edu.stanford.nlp.pipeline.Language'` while importing corenlp in Python
TypeError: Couldn't build proto file into descriptor pool: duplicate symbol 'edu.stanford.nlp.pipeline.Language'
I am getting this error for this code in Python:
import corenlp
I've been on this issue ...
0
votes
0
answers
51
views
how to use glove in nlpaug
I'm trying to create a word augmenter using glove. This is my code:
import nlpaug.augmenter.word.word_embs as nawwe
aug = nawwe.WordEmbsAug(model_type='glove',model_path='/content/drive/MyDrive/data/...
1
vote
1
answer
48
views
NLP task of arranging words in the correct order?
Is there any state-of-the-art deep learning model that can acomplish the task of arranging a bunch of words in the correct order?
For example,
Input: boy that killed have must they
Expected output: ...
0
votes
1
answer
93
views
Stanford's Stanza NLP: find all words ids for a given span
I am using a Stanza pipeline that extracts both words and named entities.
The sentence.entities gives me a list of recognized named entities with their start and end characters. Here is an example:
{
...
0
votes
0
answers
13
views
Stanze ca spacy, or how to Asse Euro Signs to spacy
Currently I try to measure specificity and text. Among other things I want to include Euro Sign as Money Value, but unfortunately spacy does only recognize a dollar sign.
I tried all the english ...
0
votes
1
answer
41
views
Stanza: Count words without punctuation
I currently want to count words in a text with stanza, but without punctuation and without removing punctuation.
Currently I try:
text = """ Q1 revenue reached €12 .7 billion ."&...
1
vote
0
answers
72
views
Stanford Stanza NLP to networkx: superimpose NER entities onto graph of words
Here is a sample program which will take a text (example is in italian but Stanza supports many languages) and builds and displays a graph of the words (only certain Parts of Speech) and their ...
0
votes
1
answer
105
views
Obtaining data from both token and word objects in a Stanza Document / Sentence
I am using a Stanford STANZA pipeline on some (italian) text.
Problem I'm grappling with is that I need data from BOTH the Token and Word objects.
While I'm able to access one or the other separately ...
3
votes
1
answer
142
views
Converting a dataset to CoNLL format. Label remaining tokens with O
I have a manually annotated dataset that contains records in the following format:
{
"id": 1,
"text": "At the end of each fiscal quarter, for the four consecutive ...
1
vote
1
answer
31
views
Retain original document element index of argument passed through sklearn's CountVectorizer() in order to access corresponding part of speech tag
I have a data frame with sentences and the respective part of speech tag for each word (Below is an extract of the data I'm working with (data taken from SNLI corpus). For each sentence in my ...
0
votes
1
answer
24
views
How to convert a list of words into multiple sentences in python
Eg:
Input:
Name: ['FirstName','LastName','FirstNameLastName']
Customer Account Number: ['Customer', 'Account', 'Number', 'Customer Account', 'Customer Number', 'Customer Account Number']
output:
...
0
votes
1
answer
75
views
Exception in thread "main" java.lang.OutOfMemoryError: GC overhead limit exceeded using Stanford CoreNLP
While setting up Stanford CoreNLP, I am running into following exception since a long time:
Exception in thread "main" java.lang.OutOfMemoryError: GC overhead limit exceeded
at java.lang....
0
votes
0
answers
28
views
how to Extract nouns and then store on csv file
I am trying to extract nouns from a huge file and then store on another csv file .but when i am trying to write only last line is written
looking for the solution to extract nouns and stored on a ...
0
votes
0
answers
21
views
Confidence level for CoreNLP Open IE Json format
I'm using the python wrapper for CoreNLP Open IE and outputting in json format, but I cannot see the confidence scores.
I tried adjusting the properties following this answer: Stanford CoreNLP OpenIE ...
0
votes
0
answers
287
views
Break Complex/Compound Sentences into Simple Sentences using NLP
I want to break sentences i.e complex/compound sentences, the sentences that are larger in size and consist of more than two sentences.
for eg: I like to eat apples but I hate apple juice.
Here the ...
0
votes
0
answers
13
views
Is there a Stanford NLP Group program for comparing two essays?
I'm trying to find an NLP program that will take two essays (long), compare the, and spit out some number representing a similarity score. Does Stanford NLP Group have one?
I have tried a Twinword's ...
0
votes
0
answers
25
views
how to use model.predict fucntion on new data
'''
Hi All,
I m new to machine Learning and I m doing a project on suicidal text classification.
Im able to run the model and evaluate the model using x_text and use the model.predict function on ...
0
votes
0
answers
314
views
java.io.IOException: Unable to open "edu/stanford/nlp/models/pos-tagger/english-left3words-distsim.tagger" as class path, filename or URL
I wanted to get started with the StanfordCorenlp library in Java. I added the edu.stanford.nlp.corenlp:4.4.0 library with the correct dependencies to the project. After that I wrote a simple program ...
0
votes
0
answers
96
views
How to visualize Stanford Stanza NER results with BRAT
I am using Stanza Biomedical i2b2 processor to identify PROBLEM, TREATMENT and TEST entities in drugs data.
Python code is as follows:
import stanza
stanza.download(
"en",
package=&...
0
votes
0
answers
16
views
having problems getting NER labels when using stanfordnlp
I started playing with NER using stanfordNLP and found their NERDemo code out on the web as a nice starting point.
I am classifying a line containing a recipe ingredient. When I run the NERDemo I see ...
1
vote
0
answers
24
views
is there a method to extract noun-adjs pairs for french?
i want to extract from a sentence a noun-adj pairs :
i tried this code :
import stanza
nlp = stanza.Pipeline("fr")
doc = nlp("La voiture est belle et jolie, et grand. Le tableau qui ...
0
votes
1
answer
89
views
Converting word to vector using GloVe
I loaded my glove package as follows:
import gensim.downloader as api
model = api.load("glove-wiki-gigaword-100")
and would want to create a function where I pass in a word and the GloVe ...