Book Image

fastText Quick Start Guide

By : Joydeep Bhattacharjee
Book Image

fastText Quick Start Guide

By: Joydeep Bhattacharjee

Overview of this book

Facebook's fastText library handles text representation and classification, used for Natural Language Processing (NLP). Most organizations have to deal with enormous amounts of text data on a daily basis, and gaining efficient data insights requires powerful NLP tools such as fastText.  This book is your ideal introduction to fastText. You will learn how to create fastText models from the command line, without the need for complicated code. You will explore the algorithms that fastText is built on and how to use them for word representation and text classification.  Next, you will use fastText in conjunction with other popular libraries and frameworks such as Keras, TensorFlow, and PyTorch.  Finally, you will deploy fastText models to mobile devices. By the end of this book, you will have all the required knowledge to use fastText in your own applications at work or in projects.
Table of Contents (14 chapters)
Free Chapter
1
First Steps
4
The FastText Model
7
Using FastText in Your Own Models

Word-to-vector representations

Almost all machine learning and deep learning algorithms manipulate vectors and matrices. The reason they work is because of their base mathematics, which is heavily rooted in linear algebra. So, in short, for both supervised and unsupervised learning, you will need to create matrices of numbers. In other domains, this is not an issue as information is generally captured as numbers. For example, in retail, the sales information for how many units were sold or how much revenue the store is making in the current month is all numbers. Even in a more abstract field such as computer vision, the image is always stored as pixel intensity of the three basic colors: red, green, and blue. 0 for a particular color means no intensity and 255 means the highest possible intensity for the screen. Similarly, in the case of sound, it is stored as power spectral density...