提交 d73efea4 编写于 作者: Z Zeyu Chen

update english readme also

上级 1888a751
...@@ -4,45 +4,46 @@ ...@@ -4,45 +4,46 @@
<img src="./docs/imgs/paddlenlp.png" width="520" height ="100" /> <img src="./docs/imgs/paddlenlp.png" width="520" height ="100" />
</p> </p>
------------------------------------------------------------------------------------------
PaddleNLP 2.0拥有丰富的模型库、简洁易用的API与高性能的分布式训练的能力,旨在为飞桨开发者提升文本建模效率,并提供基于PaddlePaddle 2.0的NLP领域最佳实践。
![License](https://img.shields.io/badge/license-Apache%202-red.svg) ![License](https://img.shields.io/badge/license-Apache%202-red.svg)
![python version](https://img.shields.io/badge/python-3.6+-orange.svg) ![python version](https://img.shields.io/badge/python-3.6+-orange.svg)
![support os](https://img.shields.io/badge/os-linux%2C%20win%2C%20mac-yellow.svg) ![support os](https://img.shields.io/badge/os-linux%2C%20win%2C%20mac-yellow.svg)
## 简介
# 特性 PaddleNLP 2.0拥有丰富的模型库、简洁易用的API与高性能的分布式训练的能力,旨在为飞桨开发者提升文本建模效率,并提供基于PaddlePaddle 2.0的NLP领域最佳实践。
## 特性
- **丰富的模型库** - **丰富的模型库**
- 涵盖了NLP主流应用相关的前沿模型,包括中文词向量、预训练模型、词法分析、文本分类、文本匹配、文本生成、机器翻译、通用对话、问答系统等。更多介绍请查看[PaddleNLP模型库](./exmaples/README.md) - 涵盖了NLP主流应用相关的前沿模型,包括中文词向量、预训练模型、词法分析、文本分类、文本匹配、文本生成、机器翻译、通用对话、问答系统等,更多详细介绍请查看[PaddleNLP模型库](./exmaples/README.md)
- **简洁易用的API** - **简洁易用的API**
- 深度兼容飞桨2.0的高层API体系,提供更多可复用的文本建模模块,可大幅度减少数据处理、组网、训练环节的代码开发,提高开发效率。 - 深度兼容飞桨2.0的高层API体系,提供可复用的文本建模模块,可大幅度减少数据处理、组网、训练环节的代码开发量,提升文本建模开发效率。
- **高性能分布式训练** - **高性能分布式训练**
- 通过深度优化的Transformer网络实现,结合混合精度与Fleet分布式训练API,可充分利用GPU集群资源,高效完成大规模预训练模型的分布式训练。 - 通过深度优化的混合精度训练策略与Fleet分布式训练API,可充分利用GPU集群资源,高效完成大规模预训练模型的分布式训练。
# 安装 ## 安装
## 环境依赖 ### 环境依赖
- python >= 3.6 - python >= 3.6
- paddlepaddle >= 2.0.0 - paddlepaddle >= 2.0.0
``` ```
pip install paddlenlp==2.0.0rc pip install paddlenlp==2.0.0rc
``` ```
# 快速开始 ## 快速开始
## 数据集快速加载 ### 数据集快速加载
```python ```python
from paddlenlp.datasets import ChnSentiCorp from paddlenlp.datasets import ChnSentiCorp
...@@ -52,7 +53,7 @@ train_dataset, dev_dataset, test_dataset= ChnSentiCorp.get_datasets(['train', 'd ...@@ -52,7 +53,7 @@ train_dataset, dev_dataset, test_dataset= ChnSentiCorp.get_datasets(['train', 'd
可参考[Dataset文档](./docs/datasets.md)查看更多数据集。 可参考[Dataset文档](./docs/datasets.md)查看更多数据集。
## 一键加载中文词向量 ### 一键加载中文词向量
```python ```python
from paddlenlp.embeddings import TokenEmbedding from paddlenlp.embeddings import TokenEmbedding
...@@ -67,7 +68,7 @@ wordemb.cosine_sim("艺术", "火车") ...@@ -67,7 +68,7 @@ wordemb.cosine_sim("艺术", "火车")
内置50+中文词向量,更多使用方法请参考 [Embedding文档](./examples/word_embedding/README.md) 内置50+中文词向量,更多使用方法请参考 [Embedding文档](./examples/word_embedding/README.md)
## 一键加载高质量中文预训练模型 ### 一键加载高质量中文预训练模型
```python ```python
from paddlenlp.transformers import ErnieModel, BertModel, RobertaModel, ElectraModel from paddlenlp.transformers import ErnieModel, BertModel, RobertaModel, ElectraModel
...@@ -83,7 +84,7 @@ electra = ElectraModel.from_pretrained('chinese-electra-small') ...@@ -83,7 +84,7 @@ electra = ElectraModel.from_pretrained('chinese-electra-small')
请参考 [Pretrained-Models](./docs/transformers.md)查看目前支持的预训练模型。 请参考 [Pretrained-Models](./docs/transformers.md)查看目前支持的预训练模型。
# 模型库及其应用 ## 模型库及其应用
- [词向量](./examples/word_embedding/README.md) - [词向量](./examples/word_embedding/README.md)
- [词法分析](./examples/lexical_analysis/README.md) - [词法分析](./examples/lexical_analysis/README.md)
...@@ -98,7 +99,7 @@ electra = ElectraModel.from_pretrained('chinese-electra-small') ...@@ -98,7 +99,7 @@ electra = ElectraModel.from_pretrained('chinese-electra-small')
- [阅读理解](./exmaples/machine_reading_comprehension) - [阅读理解](./exmaples/machine_reading_comprehension)
# API 使用文档 ## API 使用文档
- [Transformer API](./docs/transformers.md) - [Transformer API](./docs/transformers.md)
...@@ -111,7 +112,7 @@ electra = ElectraModel.from_pretrained('chinese-electra-small') ...@@ -111,7 +112,7 @@ electra = ElectraModel.from_pretrained('chinese-electra-small')
- [Metrics API](./docs/metrics.md) - [Metrics API](./docs/metrics.md)
# 交互式Notebook教程 ## 交互式Notebook教程
- [使用Seq2Vec模块进行句子情感分类](https://aistudio.baidu.com/aistudio/projectdetail/1283423) - [使用Seq2Vec模块进行句子情感分类](https://aistudio.baidu.com/aistudio/projectdetail/1283423)
- [如何通过预训练模型Fine-tune下游任务](https://aistudio.baidu.com/aistudio/projectdetail/1294333) - [如何通过预训练模型Fine-tune下游任务](https://aistudio.baidu.com/aistudio/projectdetail/1294333)
...@@ -124,7 +125,7 @@ electra = ElectraModel.from_pretrained('chinese-electra-small') ...@@ -124,7 +125,7 @@ electra = ElectraModel.from_pretrained('chinese-electra-small')
更多教程参见[PaddleNLP on AI Studio](https://aistudio.baidu.com/aistudio/personalcenter/thirdview/574995) 更多教程参见[PaddleNLP on AI Studio](https://aistudio.baidu.com/aistudio/personalcenter/thirdview/574995)
# 社区贡献与技术交流 ## 社区贡献与技术交流
- 欢迎您加入PaddleNLP的SIG社区,贡献优秀的模型实现、公开数据集、教程与案例、外围小工具。 - 欢迎您加入PaddleNLP的SIG社区,贡献优秀的模型实现、公开数据集、教程与案例、外围小工具。
- 现在就加入PaddleNLP的QQ技术交流群,一起交流NLP技术吧!⬇️ - 现在就加入PaddleNLP的QQ技术交流群,一起交流NLP技术吧!⬇️
...@@ -134,6 +135,6 @@ electra = ElectraModel.from_pretrained('chinese-electra-small') ...@@ -134,6 +135,6 @@ electra = ElectraModel.from_pretrained('chinese-electra-small')
</div> </div>
# License ## License
PaddleNLP遵循[Apache-2.0开源协议](./LICENSE) PaddleNLP遵循[Apache-2.0开源协议](./LICENSE)
...@@ -4,13 +4,15 @@ English | [简体中文](./README.md) ...@@ -4,13 +4,15 @@ English | [简体中文](./README.md)
<img src="./docs/imgs/paddlenlp.png" width="520" height ="100" /> <img src="./docs/imgs/paddlenlp.png" width="520" height ="100" />
</p> </p>
---------------------------------------------------------------------------------
![License](https://img.shields.io/badge/license-Apache%202-red.svg) ![License](https://img.shields.io/badge/license-Apache%202-red.svg)
![python version](https://img.shields.io/badge/python-3.6+-orange.svg) ![python version](https://img.shields.io/badge/python-3.6+-orange.svg)
![support os](https://img.shields.io/badge/os-linux%2C%20win%2C%20mac-yellow.svg) ![support os](https://img.shields.io/badge/os-linux%2C%20win%2C%20mac-yellow.svg)
## Introduction ## Introduction
PaddleNLP aims to accelerate NLP applications through powerful model zoo, easy-to-use API with detailed tutorials, It's also the NLP best practice for PaddlePaddle 2.0 API system. PaddleNLP aims to accelerate NLP applications through powerful model zoo, easy-to-use API with detailed tutorials. It's also the NLP best practice for PaddlePaddle 2.0 API system.
**This project is still UNDER ACTIVE DEVELOPMENT.** **This project is still UNDER ACTIVE DEVELOPMENT.**
...@@ -70,13 +72,28 @@ roberta = RobertaModel.from_pretrained('roberta-wwm-ext') ...@@ -70,13 +72,28 @@ roberta = RobertaModel.from_pretrained('roberta-wwm-ext')
electra = ElectraModel.from_pretrained('chinese-electra-small') electra = ElectraModel.from_pretrained('chinese-electra-small')
``` ```
For more pretrained model selection, please refer to [PretrainedModels](./paddlenlp/transformers/README.md) For more pretrained model selection, please refer to [Pretrained-Models](./paddlenlp/transformers/README.md)
## API Usage ## Model Zoo and Applications
- [Word Embedding](./examples/word_embedding/README.md)
- [Lexical Analysis](./examples/lexical_analysis/README.md)
- [Language Model](./examples/language_model)
- [Text Classification](./examples/text_classification/README.md)
- [Text Generation](./examples/text_generation/README.md)
- [Semantic Matching](./examples/text_matching/README.md)
- [Named Entity Recognition](./examples/named_entity_recognition/README.md)
- [Text Graph](./examples/text_graph/README.md)
- [General Dialogue](./examples/dialogue)
- [Machine Translation](./exmaples/machine_translation)
- [Question Answering](./exmaples/machine_reading_comprehension)
## API Usage
- [Transformer API](./docs/transformers.md) - [Transformer API](./docs/transformers.md)
- [Data API](./docs/data.md)
- [Dataset API](./docs/datasets.md) - [Dataset API](./docs/datasets.md)
- [Embedding API](./docs/embeddings.md) - [Embedding API](./docs/embeddings.md)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册