🚀 MVP
MVPモデルは、Tianyi Tang、Junyi Li、Wayne Xin Zhao、Ji - Rong WenによるMVP: Multi-task Supervised Pre-training for Natural Language Generationで提案されました。
詳細な情報と指示はhttps://github.com/RUCAIBox/MVPで見ることができます。
🚀 クイックスタート
MVPモデルに関する詳細な情報や使い方は、https://github.com/RUCAIBox/MVPを参照してください。
✨ 主な機能
MVPは、ラベル付きデータセットの混合を使用して教師付き事前学習されたモデルです。標準的なTransformerエンコーダ - デコーダアーキテクチャに基づいています。
MVPは自然言語生成に特化して設計されており、要約、データからテキストへの生成、オープンエンド型対話システム、ストーリー生成、質問応答、質問生成、タスク指向型対話システム、常識生成、言い換え生成、テキストスタイル変換、テキスト単純化など、幅広い生成タスクに適応できます。また、シーケンス分類や(抽出型)質問応答などの自然言語理解タスクにも適応可能です。
💻 使用例
基本的な使用法
要約タスクの例
>>> from transformers import MvpTokenizer, MvpForConditionalGeneration
>>> tokenizer = MvpTokenizer.from_pretrained("RUCAIBox/mvp")
>>> model = MvpForConditionalGeneration.from_pretrained("RUCAIBox/mvp")
>>> inputs = tokenizer(
... "Summarize: You may want to stick it to your boss and leave your job, but don't do it if these are your reasons.",
... return_tensors="pt",
... )
>>> generated_ids = model.generate(**inputs)
>>> tokenizer.batch_decode(generated_ids, skip_special_tokens=True)
["Why You Shouldn't Quit Your Job"]
データからテキストへの生成タスクの例
>>> from transformers import MvpTokenizerFast, MvpForConditionalGeneration
>>> tokenizer = MvpTokenizerFast.from_pretrained("RUCAIBox/mvp")
>>> model = MvpForConditionalGeneration.from_pretrained("RUCAIBox/mvp")
>>> inputs = tokenizer(
... "Describe the following data: Iron Man | instance of | Superhero [SEP] Stan Lee | creator | Iron Man",
... return_tensors="pt",
... )
>>> generated_ids = model.generate(**inputs)
>>> tokenizer.batch_decode(generated_ids, skip_special_tokens=True)
['Stan Lee created the character of Iron Man, a fictional superhero appearing in American comic']
📚 ドキュメント
関連モデル
- MVP: https://huggingface.co/RUCAIBox/mvp。
- プロンプトベースのモデル:
- MVP - multi - task: [https://huggingface.co/RUCAIBox/mvp - multi - task](https://huggingface.co/RUCAIBox/mvp - multi - task)。
- MVP - summarization: [https://huggingface.co/RUCAIBox/mvp - summarization](https://huggingface.co/RUCAIBox/mvp - summarization)。
- MVP - open - dialog: [https://huggingface.co/RUCAIBox/mvp - open - dialog](https://huggingface.co/RUCAIBox/mvp - open - dialog)。
- MVP - data - to - text: [https://huggingface.co/RUCAIBox/mvp - data - to - text](https://huggingface.co/RUCAIBox/mvp - data - to - text)。
- MVP - story: [https://huggingface.co/RUCAIBox/mvp - story](https://huggingface.co/RUCAIBox/mvp - story)。
- MVP - question - answering: [https://huggingface.co/RUCAIBox/mvp - question - answering](https://huggingface.co/RUCAIBox/mvp - question - answering)。
- MVP - question - generation: [https://huggingface.co/RUCAIBox/mvp - question - generation](https://huggingface.co/RUCAIBox/mvp - question - generation)。
- MVP - task - dialog: [https://huggingface.co/RUCAIBox/mvp - task - dialog](https://huggingface.co/RUCAIBox/mvp - task - dialog)。
- マルチタスクモデル:
- MTL - summarization: [https://huggingface.co/RUCAIBox/mtl - summarization](https://huggingface.co/RUCAIBox/mtl - summarization)。
- MTL - open - dialog: [https://huggingface.co/RUCAIBox/mtl - open - dialog](https://huggingface.co/RUCAIBox/mtl - open - dialog)。
- MTL - data - to - text: [https://huggingface.co/RUCAIBox/mtl - data - to - text](https://huggingface.co/RUCAIBox/mtl - data - to - text)。
- MTL - story: [https://huggingface.co/RUCAIBox/mtl - story](https://huggingface.co/RUCAIBox/mtl - story)。
- MTL - question - answering: [https://huggingface.co/RUCAIBox/mtl - question - answering](https://huggingface.co/RUCAIBox/mtl - question - answering)。
- MTL - question - generation: [https://huggingface.co/RUCAIBox/mtl - question - generation](https://huggingface.co/RUCAIBox/mtl - question - generation)。
- MTL - task - dialog: [https://huggingface.co/RUCAIBox/mtl - task - dialog](https://huggingface.co/RUCAIBox/mtl - task - dialog)。
📄 ライセンス
このモデルはApache 2.0ライセンスの下で提供されています。
引用
@article{tang2022mvp,
title={MVP: Multi-task Supervised Pre-training for Natural Language Generation},
author={Tang, Tianyi and Li, Junyi and Zhao, Wayne Xin and Wen, Ji-Rong},
journal={arXiv preprint arXiv:2206.12131},
year={2022},
url={https://arxiv.org/abs/2206.12131},
}