Remove add-new-model in favor of add-new-model-like (#30424)
* Remove add-new-model in favor of add-new-model-like * nits
This commit is contained in:
@@ -398,12 +398,14 @@ In dem speziellen Fall, dass Sie ein Modell hinzufügen, dessen Architektur gena
|
||||
Modells übereinstimmt, müssen Sie nur ein Konvertierungsskript hinzufügen, wie in [diesem Abschnitt](#write-a-conversion-script) beschrieben.
|
||||
In diesem Fall können Sie einfach die gesamte Modellarchitektur des bereits vorhandenen Modells wiederverwenden.
|
||||
|
||||
Andernfalls beginnen wir mit der Erstellung eines neuen Modells. Sie haben hier zwei Möglichkeiten:
|
||||
Andernfalls beginnen wir mit der Erstellung eines neuen Modells. Wir empfehlen die Verwendung des folgenden Skripts, um ein Modell hinzuzufügen
|
||||
ein bestehendes Modell:
|
||||
|
||||
- `transformers-cli add-new-model-like`, um ein neues Modell wie ein bestehendes hinzuzufügen
|
||||
- `transformers-cli add-new-model`, um ein neues Modell aus unserer Vorlage hinzuzufügen (sieht dann aus wie BERT oder Bart, je nachdem, welche Art von Modell Sie wählen)
|
||||
```bash
|
||||
transformers-cli add-new-model-like
|
||||
```
|
||||
|
||||
In beiden Fällen werden Sie mit einem Fragebogen aufgefordert, die grundlegenden Informationen zu Ihrem Modell auszufüllen. Für den zweiten Befehl müssen Sie `cookiecutter` installieren, weitere Informationen dazu finden Sie [hier](https://github.com/huggingface/transformers/tree/main/templates/adding_a_new_model).
|
||||
Sie werden mit einem Fragebogen aufgefordert, die grundlegenden Informationen Ihres Modells einzugeben.
|
||||
|
||||
**Eröffnen Sie einen Pull Request auf dem Haupt-Repositorium huggingface/transformers**
|
||||
|
||||
|
||||
@@ -98,7 +98,7 @@ Es werden ständig neue Modelle veröffentlicht. Wenn Sie ein neues Modell imple
|
||||
|
||||
Lassen Sie es uns wissen, wenn Sie bereit sind, das Modell selbst beizutragen. Dann können wir Ihnen helfen, es zu 🤗 Transformers hinzuzufügen!
|
||||
|
||||
Wir haben eine [detaillierte Anleitung und Vorlagen](https://github.com/huggingface/transformers/tree/main/templates) hinzugefügt, um Ihnen das Hinzufügen eines neuen Modells zu erleichtern, und wir haben auch einen technischen Leitfaden dazu, [wie man ein Modell zu 🤗 Transformers hinzufügt](https://huggingface.co/docs/transformers/add_new_model).
|
||||
Wir haben auch einen technischen Leitfaden dazu, [wie man ein Modell zu 🤗 Transformers hinzufügt](https://huggingface.co/docs/transformers/add_new_model).
|
||||
|
||||
## Möchten Sie die Dokumentation erweitern?
|
||||
|
||||
|
||||
@@ -398,12 +398,14 @@ In the special case that you are adding a model whose architecture exactly match
|
||||
existing model you only have to add a conversion script as described in [this section](#write-a-conversion-script).
|
||||
In this case, you can just re-use the whole model architecture of the already existing model.
|
||||
|
||||
Otherwise, let's start generating a new model. You have two choices here:
|
||||
Otherwise, let's start generating a new model. We recommend using the following script to add a model starting from
|
||||
an existing model:
|
||||
|
||||
- `transformers-cli add-new-model-like` to add a new model like an existing one
|
||||
- `transformers-cli add-new-model` to add a new model from our template (will look like BERT or Bart depending on the type of model you select)
|
||||
```bash
|
||||
transformers-cli add-new-model-like
|
||||
```
|
||||
|
||||
In both cases, you will be prompted with a questionnaire to fill in the basic information of your model. The second command requires to install `cookiecutter`, you can find more information on it [here](https://github.com/huggingface/transformers/tree/main/templates/adding_a_new_model).
|
||||
You will be prompted with a questionnaire to fill in the basic information of your model.
|
||||
|
||||
**Open a Pull Request on the main huggingface/transformers repo**
|
||||
|
||||
|
||||
@@ -351,13 +351,14 @@ Nel caso speciale in cui stiate aggiungendo un modello, la cui architettura sia
|
||||
dovrete solo aggiugnere uno script di conversione, come descritto [qui](#write-a-conversion-script).
|
||||
In questo caso, potete riutilizzare l'intera architettura del modello gia esistente.
|
||||
|
||||
Se questo non é il caso, cominciamo con il generare un nuovo modello. Avrete due opzioni:
|
||||
Se questo non é il caso, cominciamo con il generare un nuovo modello. Ti consigliamo di utilizzare il seguente script per aggiungere un modello a partire da
|
||||
un modello esistente:
|
||||
|
||||
- `transformers-cli add-new-model-like` per aggiungere un nuovo modello come uno che gia esiste
|
||||
- `transformers-cli add-new-model` per aggiungere un nuovo modello da un nostro template (questo assomigliera a BERT o Bart, in base al modello che selezionerete)
|
||||
```bash
|
||||
transformers-cli add-new-model-like
|
||||
```
|
||||
|
||||
In entrambi i casi, l'output vi darà un questionario da riempire con informazioni basi sul modello. Il secondo comando richiede di installare
|
||||
un `cookiecutter` - maggiori informazioni [qui](https://github.com/huggingface/transformers/tree/main/templates/adding_a_new_model).
|
||||
Ti verrà richiesto con un questionario di compilare le informazioni di base del tuo modello.
|
||||
|
||||
**Aprire una Pull Request in main huggingface/transformers repo**
|
||||
|
||||
|
||||
@@ -307,14 +307,15 @@ cd transformers
|
||||
[このセクション](#write-a-conversion-script)で説明されているように、変換スクリプトを追加するだけで済みます。
|
||||
この場合、既存のモデルの完全なモデルアーキテクチャを再利用できます。
|
||||
|
||||
それ以外の場合、新しいモデルの生成を開始します。ここで2つの選択肢があります:
|
||||
|
||||
- `transformers-cli add-new-model-like`を使用して既存のモデルのような新しいモデルを追加します
|
||||
- `transformers-cli add-new-model`を使用して、テンプレートから新しいモデルを追加します(モデルのタイプに応じてBERTまたはBartのように見えます)
|
||||
それ以外の場合は、新しいモデルの生成を開始しましょう。 次のスクリプトを使用して、以下から始まるモデルを追加することをお勧めします。
|
||||
既存のモデル:
|
||||
|
||||
どちらの場合でも、モデルの基本情報を入力するための質問事項が表示されます。
|
||||
2番目のコマンドを実行するには、`cookiecutter`をインストールする必要があります。
|
||||
詳細については[こちら](https://github.com/huggingface/transformers/tree/main/templates/adding_a_new_model)をご覧ください。
|
||||
```bash
|
||||
transformers-cli add-new-model-like
|
||||
```
|
||||
|
||||
モデルの基本情報を入力するためのアンケートが表示されます。
|
||||
|
||||
**主要な huggingface/transformers リポジトリでプルリクエストを開く**
|
||||
|
||||
|
||||
@@ -268,12 +268,14 @@ cd transformers
|
||||
|
||||
다음과 같이 이미 존재하는 모델의 모델 아키텍처와 정확히 일치하는 모델을 추가하는 특별한 경우에는 [이 섹션](#write-a-conversion-script)에 설명된대로 변환 스크립트만 추가하면 됩니다. 이 경우에는 이미 존재하는 모델의 전체 모델 아키텍처를 그대로 재사용할 수 있습니다.
|
||||
|
||||
그렇지 않으면 새로운 모델 생성을 시작합시다. 여기에서 두 가지 선택지가 있습니다:
|
||||
그렇지 않으면 새 모델 생성을 시작하겠습니다. 다음 스크립트를 사용하여 다음에서 시작하는 모델을 추가하는 것이 좋습니다.
|
||||
기존 모델:
|
||||
|
||||
- `transformers-cli add-new-model-like`를 사용하여 기존 모델과 유사한 새로운 모델 추가하기
|
||||
- `transformers-cli add-new-model`을 사용하여 템플릿을 기반으로 한 새로운 모델 추가하기 (선택한 모델 유형에 따라 BERT 또는 Bart와 유사한 모습일 것입니다)
|
||||
```bash
|
||||
transformers-cli add-new-model-like
|
||||
```
|
||||
|
||||
두 경우 모두, 모델의 기본 정보를 입력하는 설문조사가 제시됩니다. 두 번째 명령어는 `cookiecutter`를 설치해야 합니다. 자세한 정보는 [여기](https://github.com/huggingface/transformers/tree/main/templates/adding_a_new_model)에서 확인할 수 있습니다.
|
||||
모델의 기본 정보를 입력하는 설문지가 표시됩니다.
|
||||
|
||||
**huggingface/transformers 메인 저장소에 Pull Request 열기**
|
||||
|
||||
|
||||
@@ -99,7 +99,7 @@ python src/transformers/commands/transformers_cli.py env
|
||||
|
||||
만약 모델을 직접 기여하고 싶으시다면, 알려주세요. 🤗 Transformers에 추가할 수 있도록 도와드리겠습니다!
|
||||
|
||||
새로운 모델을 추가하는 방법에 대한 [상세 안내서와 템플릿](https://github.com/huggingface/transformers/tree/main/templates)을 제공하고 있으며, [🤗 Transformers에 새로운 모델을 추가하는 방법](https://huggingface.co/docs/transformers/add_new_model)에 대한 기술적인 안내서도 있습니다.
|
||||
[🤗 Transformers에 새로운 모델을 추가하는 방법](https://huggingface.co/docs/transformers/add_new_model)에 대한 기술적인 안내서도 있습니다.
|
||||
|
||||
## 문서를 추가하고 싶으신가요? [[do-you-want-to-add-documentation]]
|
||||
|
||||
|
||||
@@ -98,7 +98,7 @@ python src/transformers/commands/transformers_cli.py env
|
||||
|
||||
如果你想亲自贡献模型,请告诉我们。让我们帮你把它添加到 🤗 Transformers!
|
||||
|
||||
我们已经添加了[详细的指南和模板](https://github.com/huggingface/transformers/tree/main/templates)来帮助你添加新模型。我们还有一个更技术性的指南,告诉你[如何将模型添加到 🤗 Transformers](https://huggingface.co/docs/transformers/add_new_model)。
|
||||
我们还有一个更技术性的指南,告诉你[如何将模型添加到 🤗 Transformers](https://huggingface.co/docs/transformers/add_new_model)。
|
||||
|
||||
## 你想要添加文档吗?
|
||||
|
||||
|
||||
Reference in New Issue
Block a user