NLP using regex in python | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
0

NLP using regex in python

From the string like 'I only eat BROWN BREAD' , need to tokenize BROWN BREAD together. Looking for a regex pattern to perform the operation

26th Oct 2018, 7:26 AM
Bishu Giri
Bishu Giri - avatar
1 Answer
+ 2
So you need a pattern for words in uppercase? I'd try something like r'\b([A-Z]){2,}\b'
26th Oct 2018, 9:46 AM
Anna
Anna - avatar