Skip to Content
直感 LLM ―ハンズオンで動かして学ぶ大規模言語モデル入門
book

直感 LLM ―ハンズオンで動かして学ぶ大規模言語モデル入門

by Jay Alammar, Maarten Grootendorst, 中山 光樹
June 2025
Intermediate to advanced
424 pages
7h 8m
Japanese
O'Reilly Japan, Inc.
Content preview from 直感 LLM ―ハンズオンで動かして学ぶ大規模言語モデル入門

11章分類モデルのファインチューニング

4章 テキスト分類」では、事前学習済みモデルを用いてテキストを分類しました。その際、事前学習済みモデルには手を加えず、そのまま使用することで基本的な分類タスクを解きました。では、このモデルをファインチューニングしたらどうなるのでしょうか。

十分なデータがある場合、ファインチューニングをすることで、モデルの性能をさらに引き出せる可能性があります。ファインチューニングは、事前学習済みモデルに特定のタスク向けの追加学習を施すプロセスで、タスクに特化した性能の向上が期待されます。本章では、BERTをファインチューニングするためのさまざまな方法や活用例を紹介します。

まず、「11.1 教師あり分類」では、分類モデルをファインチューニングする基本的な手順について説明します。その次に、「11.2 Few-shot分類」では、学習用データが少ない場合でも、高い性能を発揮できるSetFitという手法について紹介します。また、「11.3 マスク言語モデリングによる継続事前学習」では、事前学習済みモデルに対して追加で学習する方法を解説します。最後に、「11.4 固有表現認識」では、トークン単位での分類について取り上げます。

なお、本章ではテキスト生成を行うモデルについては扱いません。それについては「12章 生成モデルのファインチューニング」で扱うので、楽しみにしていてください。

11.1 教師あり分類

4章 テキスト分類」では、事前学習済みモデルを用いた教師あり分類について学びました。4章では、図11-1のような2種類のモデルを使用しました。1つは感情を予測するために学習された表現モデル(タスク固有モデル)、もう1つは埋め込みを生成するために学習された表現モデル(埋め込みモデル)です。 ...

Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.

Read now

Unlock full access

More than 5,000 organizations count on O’Reilly

AirBnbBlueOriginElectronic ArtsHomeDepotNasdaqRakutenTata Consultancy Services

QuotationMarkO’Reilly covers everything we've got, with content to help us build a world-class technology community, upgrade the capabilities and competencies of our teams, and improve overall team performance as well as their engagement.
Julian F.
Head of Cybersecurity
QuotationMarkI wanted to learn C and C++, but it didn't click for me until I picked up an O'Reilly book. When I went on the O’Reilly platform, I was astonished to find all the books there, plus live events and sandboxes so you could play around with the technology.
Addison B.
Field Engineer
QuotationMarkI’ve been on the O’Reilly platform for more than eight years. I use a couple of learning platforms, but I'm on O'Reilly more than anybody else. When you're there, you start learning. I'm never disappointed.
Amir M.
Data Platform Tech Lead
QuotationMarkI'm always learning. So when I got on to O'Reilly, I was like a kid in a candy store. There are playlists. There are answers. There's on-demand training. It's worth its weight in gold, in terms of what it allows me to do.
Mark W.
Embedded Software Engineer

You might also like

初めてのTypeScript ―型安全なJavaScriptでWeb開発を加速する

初めてのTypeScript ―型安全なJavaScriptでWeb開発を加速する

Josh Goldberg, 今村 謙士, 原 隆文
生成AIのプロンプトエンジニアリング ―信頼できる生成AIの出力を得るための普遍的な入力の原則

生成AIのプロンプトエンジニアリング ―信頼できる生成AIの出力を得るための普遍的な入力の原則

James Phoenix, Mike Taylor, 田村 広平, 大野 真一朗, 砂長谷 健, 土井 健, 大貫 峻平, 石山 将成
実践 自然言語処理 ―実世界NLPアプリケーション開発のベストプラクティス

実践 自然言語処理 ―実世界NLPアプリケーション開発のベストプラクティス

Sowmya Vajjala, Bodhisattwa Majumder, Anuj Gupta, Harshit Surana, 中山 光樹

Publisher Resources

ISBN: 9784814401154Publisher Website