Search icon
Subscription
0
Cart icon
Close icon
You have no products in your basket yet
Arrow left icon
All Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Newsletters
Free Learning
Arrow right icon
Natural Language Processing with Java and LingPipe Cookbook

You're reading from  Natural Language Processing with Java and LingPipe Cookbook

Product type Book
Published in Nov 2014
Publisher
ISBN-13 9781783284672
Pages 312 pages
Edition 1st Edition
Languages

Table of Contents (14) Chapters

Natural Language Processing with Java and LingPipe Cookbook
Credits
About the Authors
About the Reviewers
www.PacktPub.com
Preface
1. Simple Classifiers 2. Finding and Working with Words 3. Advanced Classifiers 4. Tagging Words and Tokens 5. Finding Spans in Text – Chunking 6. String Comparison and Clustering 7. Finding Coreference Between Concepts/People Index

Introduction


This chapter will tell us how to work with spans of text that typically cover one or more words/tokens. The LingPipe API represents this unit of text as a chunk with corresponding chunkers that produce chunkings. The following is some text with character offsets indicated:

LingPipe is an API. It is written in Java.
012345678901234567890123456789012345678901
          1         2         3         4           

Chunking the preceding text into sentences will give us the following output:

Sentence start=0, end=18
Sentence start =20, end=41

Adding in a chunking for named entities adds entities for LingPipe and Java:

Organization start=0, end=7
Organization start=37, end=40

We can define the named-entity chunkings with respect to their offsets from the sentences that contain them; this will make no difference to LingPipe, but Java will be:

Organization start=17, end=20

This is the basic idea of chunks. There are lots of ways to make them.

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 $15.99/month. Cancel anytime}