Search icon CANCEL
Subscription
0
Cart icon
Your Cart (0 item)
Close icon
You have no products in your basket yet
Save more on your purchases! discount-offer-chevron-icon
Savings automatically calculated. No voucher code required.
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Newsletter Hub
Free Learning
Arrow right icon
timer SALE ENDS IN
0 Days
:
00 Hours
:
00 Minutes
:
00 Seconds
Arrow up icon
GO TO TOP
Mastering spaCy

You're reading from   Mastering spaCy Build structured NLP solutions with custom components and models powered by spacy-llm

Arrow left icon
Product type Paperback
Published in Feb 2025
Publisher Packt
ISBN-13 9781835880463
Length 238 pages
Edition 2nd Edition
Languages
Tools
Concepts
Arrow right icon
Authors (2):
Arrow left icon
Déborah Mesquita Déborah Mesquita
Author Profile Icon Déborah Mesquita
Déborah Mesquita
Duygu Altınok Duygu Altınok
Author Profile Icon Duygu Altınok
Duygu Altınok
Arrow right icon
View More author details
Toc

Table of Contents (17) Chapters Close

Preface 1. Part 1: Getting Started with spaCy
2. Chapter 1: Getting Started with spaCy FREE CHAPTER 3. Chapter 2: Core Operations with spaCy 4. Part 2: Advanced Linguistic and Semantic Analysis
5. Chapter 3: Extracting Linguistic Features 6. Chapter 4: Mastering Rule-Based Matching 7. Chapter 5: Extracting Semantic Representations with spaCy Pipelines 8. Chapter 6: Utilizing spaCy with Transformers 9. Part 3: Customizing and Integrating NLP Workflows
10. Chapter 7: Enhancing NLP Tasks Using LLMs with spacy-llm 11. Chapter 8: Training an NER Component with Your Own Data 12. Chapter 9: Creating End-to-End spaCy Workflows with Weasel 13. Chapter 10: Training an Entity Linker Model with spaCy 14. Chapter 11: Integrating spaCy with Third-Party Libraries 15. Index 16. Other Books You May Enjoy

Text classification with spaCy

spaCy models are very successful for general NLP purposes, such as understanding a sentence’s syntax, splitting a paragraph into sentences, and extracting entities. However, sometimes, we work on very specific domains that spaCy pre-trained models didn’t learn how to handle.

For example, X (formerly Twitter) text contains many non-regular words, such as hashtags, emoticons, and mentions. Also, X sentences are usually just phrases, not full sentences. Here, it’s entirely reasonable that spaCy’s POS tagger performs in a substandard manner as the POS tagger is trained on full, grammatically correct English sentences.

Another example is the medical domain. It contains many entities, such as drug, disease, and chemical compound names. These entities are not expected to be recognized by spaCy’s NER model because it has no disease or drug entity labels. NER does not know anything about the medical domain at all.

In...

lock icon The rest of the chapter is locked
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at $19.99/month. Cancel anytime