0Pricing
NLP Academy · Lesson

The Transformers Library Tour

Models, tokenizers, and pipelines.

The Transformers Library Tour is a free NLP Academy lesson on CoddyKit — lesson 1 of 4. You can read the complete lesson below for free — then practise it hands-on in the browser with a built-in code editor and a 24/7 AI tutor. It is part of the NLP Academy learning path, one of 4 lessons in the course, and your progress syncs across the web and the CoddyKit app.

Meet Transformers

Hugging Face Transformers is the go-to Python library for using and fine-tuning state-of-the-art language models with very little code. 🤗

One Install Away

You add the library to your project with a single pip command, and suddenly thousands of pretrained models are within reach.

pip install transformers

The Three Pillars

Almost everything you do rests on three building blocks: a model, a tokenizer, and a high-level pipeline that ties them together.

What a Model Is

A model holds the learned weights of a transformer like BERT or GPT. It turns input numbers into predictions such as labels or text.

What a Tokenizer Does

A tokenizer converts your raw text into the integer ids the model expects, and converts the output back into readable text.

Pipelines Hide the Wiring

A pipeline bundles a tokenizer and model into one callable, so you can run a task in a single line without manual setup.

from transformers import pipeline
clf = pipeline("sentiment-analysis")

Run Your First Task

Once built, you call the pipeline like a function and it returns a clean result with a label and a confidence score.

print(clf("I love this library!"))

The Model Hub

The Hugging Face Hub hosts shared models you load by name, so you rarely need to train anything from scratch.

Auto Classes

Helpers like AutoModel and AutoTokenizer pick the right class for any checkpoint, so one line of code works across many architectures.

from transformers import AutoTokenizer
tok = AutoTokenizer.from_pretrained("bert-base-uncased")

Tasks You Get for Free

Pipelines cover many jobs out of the box: classification, named-entity recognition, summarization, translation, and question answering.

From Using to Adapting

Pipelines are great for trying models, but to make one truly yours you will fine-tune it on your own data later in this course.

Quick Check

Which piece turns raw text into the integer ids a model can read?

Recap

Transformers gives you models, tokenizers, and pipelines. Load a checkpoint from the Hub and run real NLP tasks in just a few lines. ✅

Frequently asked questions

Is the “The Transformers Library Tour” lesson free?

Yes — the full text of “The Transformers Library Tour” is free to read here on the web, and the NLP Academy course includes 4 lessons in total. To practise it interactively (a built-in code editor and a 24/7 AI tutor) and unlock the rest of the NLP Academy course, upgrade to CoddyKit PRO.

What will I learn in “The Transformers Library Tour”?

Models, tokenizers, and pipelines. You practise NLP Academy with hands-on code you run directly in the browser, and a 24/7 AI tutor answers your questions as you work through the lesson.

Do I need any experience to start NLP Academy?

No prior experience is required. NLP Academy on CoddyKit is structured for beginners through advanced learners; this is — lesson 1 of 4, so you can start here or from the beginning and move at your own pace.

How long does the “The Transformers Library Tour” lesson take?

Most CoddyKit lessons take about 5–10 minutes. Each one is bite-sized and interactive, so you make steady progress and pick up exactly where you left off across the web and the app.

Can I write and run code in this NLP Academy lesson?

Yes. Every NLP Academy lesson includes a built-in code editor, so you write and run real code right in your browser and get instant AI feedback — no local setup required.

All lessons in this course

  1. The Transformers Library Tour
  2. Tokenizing for Transformer Models
  3. Fine-Tuning With the Trainer API
  4. Evaluating and Saving Your Model
← Back to NLP Academy