0Pricing
NLP Academy · レッスン

Transformers ライブラリをひとめぐり

モデル、トークナイザー、パイプライン

「Transformers ライブラリをひとめぐり」はCoddyKit上の無料NLP Academyレッスンです。 これはレッスン1/4です。 下記で完全なレッスンを無料で読むことができます。その後、ブラウザ内の組み込みコードエディタと24時間対応のAIチューターでハンズオン演習できます。 これはNLP Academy学習パスの一部であり、ウェブとCoddyKitアプリ全体で進捗が同期されます。 NLP Academyコースには全4レッスンが含まれています。

このレッスンの一部はまだ翻訳されておらず、英語で表示されています。

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. ✅

よくある質問

「Transformers ライブラリをひとめぐり」レッスンは無料ですか?

はい。「Transformers ライブラリをひとめぐり」の完全なテキストはこのウェブで無料で読めます。インタラクティブに演習し(組み込みコードエディタと24時間対応のAIチューター)、NLP Academyコースの残りをアンロックするには、CoddyKit PROにアップグレードしてください。 NLP Academyコースには全4レッスンが含まれています。

「Transformers ライブラリをひとめぐり」で何を学びますか?

モデル、トークナイザー、パイプライン ブラウザで直接実行するハンズオンコードでNLP Academyを演習し、24時間対応のAIチューターがレッスンを進める中での質問に答えます。

NLP Academyを始めるのに経験は必要ですか?

事前経験は必要ありません。CoddyKitのNLP Academyは初級者から上級者向けに構成されているため、ここから始めるか最初から始めて、自分のペースで進むことができます。 これはレッスン1/4です。

「Transformers ライブラリをひとめぐり」レッスンにはどのくらい時間がかかりますか?

ほとんどのCoddyKitレッスンは約5~10分かかります。各レッスンはコンパクトでインタラクティブなので、着実に進歩し、ウェブとアプリ全体で正確に前回の場所から再開できます。

このNLP Academyレッスンでコードを書いて実行できますか?

はい。すべてのNLP Academyレッスンに組み込みコードエディタが含まれているため、ブラウザでリアルコードを書いて実行し、即座のAIフィードバックを取得できます。ローカル設定は不要です。

このコースのすべてのレッスン

  1. Transformers ライブラリをひとめぐり
  2. Transformer モデル向けにトークン化する
  3. Trainer API でファインチューニングする
  4. モデルを評価して保存する
← NLP Academyに戻る