maom commited on
Commit
82e7490
·
verified ·
1 Parent(s): 6e640e8

Create 06_add_curation_version_info.md

Browse files
sections/06_add_curation_version_info.md ADDED
@@ -0,0 +1,17 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ## **6 Tag the version of the curation**
2
+
3
+ Once you have made a dataset public, create a tagged branch using the [`create_tag`](https://huggingface.co/docs/huggingface_hub/main/en/package_reference/hf_api#huggingface_hub.HfApi.create_tag) function that allows for including the dataset in reproducible workflows. Versions typically follow standard [semantic versioning guidelines](https://semver.org/) of `<major>.<minor>.<patch>`.
4
+
5
+ import huggingface\_hub
6
+ huggingface\_hub.create\_tag(
7
+ repo\_id \= "\<org\_name\>/\<dataset\_name\>",
8
+ tag \= "\<version\>",
9
+ tag\_message \= "\<message\>",
10
+ repo\_type \= "dataset")
11
+
12
+ To access the tagged branch from the web-interface, go to the dataset → Files and version → select from the drop-down menu the tagged version:
13
+ ![][image1]
14
+ To download a specific tagged branch for a dataset, add the `revision="<version>"` argument to `load_dataset()`:
15
+
16
+ import datasets
17
+ dataset \= datasets.load\_dataset("\<org\_name\>/\<dataset\_name\>", `revision="1.0"`)