Skip to content

Commit ca0413e

Browse files
SBrandeisjulien-cMichellehbn
authored
✨ Document new gated repository features (#705)
* ✨ Document new gated repository features * 👌 Suggestions from Julien Co-Authored-By: Julien <julien-c@users.noreply.github.com> * Apply suggestions from code review Co-authored-by: Michelle Habonneau <83347449+Michellehbn@users.noreply.github.com> --------- Co-authored-by: Julien <julien-c@users.noreply.github.com> Co-authored-by: Michelle Habonneau <83347449+Michellehbn@users.noreply.github.com>
1 parent 54a9567 commit ca0413e

File tree

2 files changed

+35
-2
lines changed

2 files changed

+35
-2
lines changed

docs/hub/datasets-gated.md

Lines changed: 18 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,10 @@
11
# Gated datasets
22

3-
To give dataset creators more control over how their datasets are used, the Hub allows users to enable **User Access requests** through a dataset's **Settings** tab. Enabling this setting requires users to agree to share their contact information in order to access the dataset. The contact information is stored in a database, and dataset owners are able to download a copy of the user access report.
3+
To give dataset creators more control over how their datasets are used, the Hub allows users to enable **User Access requests** through a dataset's **Settings** tab.
4+
Enabling this setting requires users to agree to share their contact information and accept the dataset authors' terms and conditions in order to access the dataset.
5+
The contact information is stored in a database, and dataset owners are able to download a copy of the user access report.
6+
7+
## Modifying the prompt
48

59
The User Access request dialog can be modified to include additional text and checkbox fields in the prompt. To do this, add a YAML section to the dataset's `README.md` file (create one if it does not already exist) and add an `extra_gated_fields` property. Within this property, you'll be able to add as many custom fields as you like and whether they are a `text` or `checkbox` field. An `extra_gated_prompt` property can also be included to add a customized text message.
610

@@ -21,6 +25,19 @@ extra_gated_fields:
2125

2226
The `README.md` file for a dataset is called a [Dataset Card](./datasets-cards). Visit the documentation to learn more about how to use it and to see the properties that you can configure.
2327

28+
## Manual approval
29+
30+
By default, requests to access the dataset are automatically accepted.
31+
Dataset authors can set the approval mode to "Manual reviews" from the dataset's **Settings** tab.
32+
Doing so enforces that each access request will be manually reviewed and approved by the dataset authors.
33+
Only users whose access requests have been approved will be able to access the dataset's content.
34+
35+
36+
<div class="flex justify-center">
37+
<img class="block dark:hidden" src="https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/hub/datasets-gated-manual-approval.png"/>
38+
<img class="hidden dark:block" src="https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/hub/datasets-gated-manual-approval-dark.png"/>
39+
</div>
40+
2441
## Additional Customization
2542

2643
In some cases, you might also want to modify the text in the heading of the gate as well as the text in the button. For those use cases you can modify `extra_gated_heading` and `extra_gated_button_content`.

docs/hub/models-gated.md

Lines changed: 17 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
# Gated models
22

3-
To give model creators more control over how their models are used, the Hub allows users to enable **User Access requests** through a model's **Settings** tab. Enabling this setting requires users to agree to share their contact information in order to access the model. The contact information is stored in a database, and model owners are able to download a copy of the user access report.
3+
To give model creators more control over how their models are used, the Hub allows users to enable **User Access requests** through a model's **Settings** tab.
4+
Enabling this setting requires users to agree to share their contact information and accept the model owners' terms and conditions in order to access the model.
5+
The contact information is stored in a database, and model owners are able to download a copy of the user access report.
46

57
Note that to download a gated model you'll need to be authenticated. You can log in by installing the [`huggingface_hub` client library](https://huggingface.co/docs/huggingface_hub/index) and running the following in your terminal:
68

@@ -40,6 +42,20 @@ extra_gated_fields:
4042

4143
The `README.md` file for a model is called a [model Card](./model-cards). Visit the documentation to learn more about how to use it and to see the properties that you can configure.
4244

45+
## Manual approval
46+
47+
By default, requests to access the model are automatically accepted.
48+
Model authors can set the approval mode to "Manual reviews" from the model's **Settings** tab.
49+
Doing so enforces that each access request will be manually reviewed and approved by the model authors.
50+
Only users whose access requests have been approved will be able to access the model's content.
51+
52+
<div class="flex justify-center">
53+
<img class="block dark:hidden" src="https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/hub/models-gated-manual-approval.png"/>
54+
<img class="hidden dark:block" src="https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/hub/models-gated-manual-approval-dark.png"/>
55+
</div>
56+
57+
58+
4359
## Additional Customization
4460

4561
In some cases, you might also want to modify the text in the heading of the gate as well as the text in the button. For those use cases you can modify `extra_gated_heading` and `extra_gated_button_content`.

0 commit comments

Comments
 (0)