From ad9f8023efe2c4ecd2c37c15fa9880bba42d4586 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=80=AA=E5=93=89GuaiZai?= Date: Tue, 28 Apr 2026 23:24:22 +0800 Subject: [PATCH 1/2] docs(README_zh-hans): clarify conditions for not using Transformers Rephrase section title for clarity regarding the use of Transformers. --- i18n/README_zh-hans.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/i18n/README_zh-hans.md b/i18n/README_zh-hans.md index 480ab91207c7..b7fbfadea662 100644 --- a/i18n/README_zh-hans.md +++ b/i18n/README_zh-hans.md @@ -258,7 +258,7 @@ pipeline( Hugging Face Enterprise Hub
-## 为什么我不该用 Transformers? +## 什么情况下我不该用 Transformers? - 该库不是一个可自由拼搭的神经网络模块化工具箱。模型文件中的代码刻意减少额外抽象,以便研究者能快速在各个模型上迭代,而无需深入更多抽象或文件跳转。 - 训练 API 优化用于 Transformers 提供的 PyTorch 模型。若需要通用的机器学习训练循环,请使用其它库,如 [Accelerate](https://huggingface.co/docs/accelerate)。 From 997aed0336df57c104adf9455cfe24f5201ce0aa Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=80=AA=E5=93=89GuaiZai?= Date: Tue, 28 Apr 2026 23:50:59 +0800 Subject: [PATCH 2/2] docs(README): update section title in README.md --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 2b0204a72859..7af560a73510 100644 --- a/README.md +++ b/README.md @@ -238,7 +238,7 @@ pipeline( Hugging Face Enterprise Hub
-## Why shouldn't I use Transformers? +## When shouldn't I use Transformers? - This library is not a modular toolbox of building blocks for neural nets. The code in the model files is not refactored with additional abstractions on purpose, so that researchers can quickly iterate on each of the models without diving into additional abstractions/files. - The training API is optimized to work with PyTorch models provided by Transformers. For generic machine learning loops, you should use another library like [Accelerate](https://huggingface.co/docs/accelerate).