import{S as Sl,i as Ll,s as jl,e as s,k as f,w as d,t as n,M as xl,c as o,d as e,m as p,a as r,x as c,h as u,b as h,N as oe,G as a,g as i,y as v,L as Hl,q as m,o as y,B as _,v as Il}from"../chunks/vendor-hf-doc-builder.js";import{I as C}from"../chunks/IconCopyLink-hf-doc-builder.js";import{C as re}from"../chunks/CodeBlock-hf-doc-builder.js";function Nl(Xo){let k,Be,A,T,le,Z,ns,ie,us,Ke,O,hs,tt,fs,ps,Qe,U,ds,et,cs,vs,Xe,P,q,ne,at,ms,ue,ys,Ye,qt,_s,Ze,D,M,he,st,gs,fe,ws,ta,Mt,$s,ea,F,ot,Es,pe,bs,ks,As,de,Ps,aa,rt,ce,Yo,sa,S,G,ve,lt,Ds,me,Ss,oa,Ft,g,Ls,ye,js,xs,_e,Hs,Is,it,Ns,Cs,nt,Ts,Os,ra,ut,ge,Zo,la,ht,we,Us,ia,ft,$e,tr,na,pt,Ee,qs,ua,dt,be,er,ha,L,V,ke,ct,Ms,Ae,Fs,fa,Gt,Gs,pa,Vt,j,Vs,Pe,zs,Ws,De,Rs,Js,da,vt,Se,ar,ca,w,Le,mt,Bs,yt,Ks,Qs,Xs,je,_t,Ys,gt,Zs,to,eo,xe,He,ao,va,wt,Ie,sr,ma,z,so,$t,oo,ro,ya,x,W,Ne,Et,lo,Ce,io,_a,R,no,zt,uo,ho,ga,bt,wa,H,J,Te,kt,fo,Oe,po,$a,B,co,At,vo,mo,Ea,Wt,Ue,yo,ba,Pt,ka,Dt,qe,_o,Aa,St,Pa,Lt,jt,go,xt,Me,wo,$o,Da,Ht,Sa,$,Eo,Fe,bo,ko,Ge,Ao,Po,La,It,ja,I,K,Ve,Nt,Do,ze,So,xa,Rt,Lo,Ha,Q,jo,We,xo,Ho,Ia,Ct,Na,N,X,Re,Tt,Io,Je,No,Ca,Jt,Co,Ta,Bt,To,Oa,E,Ot,Oo,Kt,Uo,qo,Mo,Qt,Xt,Fo,Go,Vo,Yt,Zt,zo,Wo,Ua,Y,Ro,Ut,Jo,Bo,qa;return Z=new C({}),at=new C({}),st=new C({}),lt=new C({}),ct=new C({}),Et=new C({}),bt=new re({props:{code:`from datasets import load_dataset

dataset = load_dataset("stevhliu/demo")`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> datasets <span class="hljs-keyword">import</span> load_dataset

<span class="hljs-meta">&gt;&gt;&gt; </span>dataset = load_dataset(<span class="hljs-string">&quot;stevhliu/demo&quot;</span>)`}}),kt=new C({}),Pt=new re({props:{code:"pip install huggingface_hub",highlighted:"pip install huggingface_hub"}}),St=new re({props:{code:"huggingface-cli login",highlighted:"huggingface-cli login"}}),Ht=new re({props:{code:`from datasets import load_dataset

dataset = load_dataset("stevhliu/demo")
dataset.push_to_hub("stevhliu/processed_demo")`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> datasets <span class="hljs-keyword">import</span> load_dataset

<span class="hljs-meta">&gt;&gt;&gt; </span>dataset = load_dataset(<span class="hljs-string">&quot;stevhliu/demo&quot;</span>)
<span class="hljs-comment"># dataset = dataset.map(...)  # do all your processing here</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>dataset.push_to_hub(<span class="hljs-string">&quot;stevhliu/processed_demo&quot;</span>)`}}),It=new re({props:{code:'dataset.push_to_hub("stevhliu/private_processed_demo", private=True)',highlighted:'<span class="hljs-meta">&gt;&gt;&gt; </span>dataset.push_to_hub(<span class="hljs-string">&quot;stevhliu/private_processed_demo&quot;</span>, private=<span class="hljs-literal">True</span>)'}}),Nt=new C({}),Ct=new re({props:{code:`from datasets import load_dataset

dataset = load_dataset("stevhliu/demo", use_auth_token=True)

dataset = load_dataset("organization/dataset_name", use_auth_token=True)`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> datasets <span class="hljs-keyword">import</span> load_dataset

<span class="hljs-comment"># Load a private individual dataset</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>dataset = load_dataset(<span class="hljs-string">&quot;stevhliu/demo&quot;</span>, use_auth_token=<span class="hljs-literal">True</span>)

<span class="hljs-comment"># Load a private organization dataset</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>dataset = load_dataset(<span class="hljs-string">&quot;organization/dataset_name&quot;</span>, use_auth_token=<span class="hljs-literal">True</span>)`}}),Tt=new C({}),{c(){k=s("meta"),Be=f(),A=s("h1"),T=s("a"),le=s("span"),d(Z.$$.fragment),ns=f(),ie=s("span"),us=n("Share a dataset to the Hub"),Ke=f(),O=s("p"),hs=n("The "),tt=s("a"),fs=n("Hub"),ps=n(" is home to an extensive collection of community-curated and popular research datasets. We encourage you to share your dataset to the Hub to help grow the ML community and accelerate progress for everyone. All contributions are welcome; adding a dataset is just a drag and drop away!"),Qe=f(),U=s("p"),ds=n("Start by "),et=s("a"),cs=n("creating a Hugging Face Hub account"),vs=n(" if you don\u2019t have one yet."),Xe=f(),P=s("h2"),q=s("a"),ne=s("span"),d(at.$$.fragment),ms=f(),ue=s("span"),ys=n("Upload with the Hub UI"),Ye=f(),qt=s("p"),_s=n("The Hub\u2019s web-based interface allows users without any developer experience to upload a dataset."),Ze=f(),D=s("h3"),M=s("a"),he=s("span"),d(st.$$.fragment),gs=f(),fe=s("span"),ws=n("Create a repository"),ta=f(),Mt=s("p"),$s=n("A repository hosts all your dataset files, including the revision history, making storing more than one dataset version possible."),ea=f(),F=s("ol"),ot=s("li"),Es=n("Click on your profile and select "),pe=s("strong"),bs=n("New Dataset"),ks=n(" to create a new dataset repository."),As=f(),de=s("li"),Ps=n("Pick a name for your dataset, and choose whether it is a public or private dataset. A public dataset is visible to anyone, whereas a private dataset can only be viewed by you or members of your organization."),aa=f(),rt=s("div"),ce=s("img"),sa=f(),S=s("h3"),G=s("a"),ve=s("span"),d(lt.$$.fragment),Ds=f(),me=s("span"),Ss=n("Upload dataset"),oa=f(),Ft=s("ol"),g=s("li"),Ls=n("Once you\u2019ve created a repository, navigate to the "),ye=s("strong"),js=n("Files and versions"),xs=n(" tab to add a file. Select "),_e=s("strong"),Hs=n("Add file"),Is=n(" to upload your dataset files. We currently support the following data formats: CSV, JSON, JSON lines, text, and Parquet. For this tutorial, you can use the following sample CSV files: "),it=s("a"),Ns=n("train.csv"),Cs=n(", "),nt=s("a"),Ts=n("test.csv"),Os=n("."),ra=f(),ut=s("div"),ge=s("img"),la=f(),ht=s("ol"),we=s("li"),Us=n("Drag and drop your dataset files and add a brief descriptive commit message."),ia=f(),ft=s("div"),$e=s("img"),na=f(),pt=s("ol"),Ee=s("li"),qs=n("After uploading your dataset files, they are stored in your dataset repository."),ua=f(),dt=s("div"),be=s("img"),ha=f(),L=s("h3"),V=s("a"),ke=s("span"),d(ct.$$.fragment),Ms=f(),Ae=s("span"),Fs=n("Create a Dataset card"),fa=f(),Gt=s("p"),Gs=n("Adding a Dataset card is super valuable for helping users find your dataset and understand how to use it responsibly."),pa=f(),Vt=s("ol"),j=s("li"),Vs=n("Click on "),Pe=s("strong"),zs=n("Create Dataset Card"),Ws=n(" to create a Dataset card. This button creates a "),De=s("code"),Rs=n("README.md"),Js=n(" file in your repository."),da=f(),vt=s("div"),Se=s("img"),ca=f(),w=s("ol"),Le=s("li"),mt=s("p"),Bs=n("Feel free to copy this Dataset card "),yt=s("a"),Ks=n("template"),Qs=n(" to help you fill out all the relevant fields."),Xs=f(),je=s("li"),_t=s("p"),Ys=n("The Dataset card uses structured tags to help users discover your dataset on the Hub. Use the "),gt=s("a"),Zs=n("Dataset Tagger"),to=n(" to help you generate the appropriate tags."),eo=f(),xe=s("li"),He=s("p"),ao=n("Copy the generated tags, paste them at the top of your Dataset card, and then commit your changes."),va=f(),wt=s("div"),Ie=s("img"),ma=f(),z=s("p"),so=n("For a detailed example of what a good Dataset card should look like, take a look at the "),$t=s("a"),oo=n("CNN DailyMail Dataset card"),ro=n("."),ya=f(),x=s("h3"),W=s("a"),Ne=s("span"),d(Et.$$.fragment),lo=f(),Ce=s("span"),io=n("Load dataset"),_a=f(),R=s("p"),no=n("Once your dataset is stored on the Hub, anyone can load it with the "),zt=s("a"),uo=n("load_dataset()"),ho=n(" function:"),ga=f(),d(bt.$$.fragment),wa=f(),H=s("h2"),J=s("a"),Te=s("span"),d(kt.$$.fragment),fo=f(),Oe=s("span"),po=n("Upload with Python"),$a=f(),B=s("p"),co=n("Users who prefer to upload a dataset programmatically can use the "),At=s("a"),vo=n("huggingface_hub"),mo=n(" library. This library allows users to interact with the Hub from Python."),Ea=f(),Wt=s("ol"),Ue=s("li"),yo=n("Begin by installing the library:"),ba=f(),d(Pt.$$.fragment),ka=f(),Dt=s("ol"),qe=s("li"),_o=n("To upload a dataset on the Hub in Python, you need to log in to your Hugging Face account:"),Aa=f(),d(St.$$.fragment),Pa=f(),Lt=s("ol"),jt=s("li"),go=n("Use the "),xt=s("a"),Me=s("code"),wo=n("push_to_hub()"),$o=n(" function to help you add, commit, and push a file to your repository:"),Da=f(),d(Ht.$$.fragment),Sa=f(),$=s("p"),Eo=n("To set your dataset as private, set the "),Fe=s("code"),bo=n("private"),ko=n(" parameter to "),Ge=s("code"),Ao=n("True"),Po=n(". This parameter will only work if you are creating a repository for the first time."),La=f(),d(It.$$.fragment),ja=f(),I=s("h3"),K=s("a"),Ve=s("span"),d(Nt.$$.fragment),Do=f(),ze=s("span"),So=n("Privacy"),xa=f(),Rt=s("p"),Lo=n("A private dataset is only accessible by you. Similarly, if you share a dataset within your organization, then members of the organization can also access the dataset."),Ha=f(),Q=s("p"),jo=n("Load a private dataset by providing your authentication token to the "),We=s("code"),xo=n("use_auth_token"),Ho=n(" parameter:"),Ia=f(),d(Ct.$$.fragment),Na=f(),N=s("h2"),X=s("a"),Re=s("span"),d(Tt.$$.fragment),Io=f(),Je=s("span"),No=n("What's next?"),Ca=f(),Jt=s("p"),Co=n("Congratulations, you\u2019ve completed the tutorials! \u{1F973}"),Ta=f(),Bt=s("p"),To=n("From here, you can go on to:"),Oa=f(),E=s("ul"),Ot=s("li"),Oo=n("Learn more about how to use \u{1F917} Datasets other functions to "),Kt=s("a"),Uo=n("process your dataset"),qo=n("."),Mo=f(),Qt=s("li"),Xt=s("a"),Fo=n("Stream large datasets"),Go=n(" without downloading it locally."),Vo=f(),Yt=s("li"),Zt=s("a"),zo=n("Write a dataset loading script"),Wo=n(" and share your dataset with the community."),Ua=f(),Y=s("p"),Ro=n("If you have any questions about \u{1F917} Datasets, feel free to join and ask the community on our "),Ut=s("a"),Jo=n("forum"),Bo=n("."),this.h()},l(t){const l=xl('[data-svelte="svelte-1phssyn"]',document.head);k=o(l,"META",{name:!0,content:!0}),l.forEach(e),Be=p(t),A=o(t,"H1",{class:!0});var Ma=r(A);T=o(Ma,"A",{id:!0,class:!0,href:!0});var or=r(T);le=o(or,"SPAN",{});var rr=r(le);c(Z.$$.fragment,rr),rr.forEach(e),or.forEach(e),ns=p(Ma),ie=o(Ma,"SPAN",{});var lr=r(ie);us=u(lr,"Share a dataset to the Hub"),lr.forEach(e),Ma.forEach(e),Ke=p(t),O=o(t,"P",{});var Fa=r(O);hs=u(Fa,"The "),tt=o(Fa,"A",{href:!0,rel:!0});var ir=r(tt);fs=u(ir,"Hub"),ir.forEach(e),ps=u(Fa," is home to an extensive collection of community-curated and popular research datasets. We encourage you to share your dataset to the Hub to help grow the ML community and accelerate progress for everyone. All contributions are welcome; adding a dataset is just a drag and drop away!"),Fa.forEach(e),Qe=p(t),U=o(t,"P",{});var Ga=r(U);ds=u(Ga,"Start by "),et=o(Ga,"A",{href:!0,rel:!0});var nr=r(et);cs=u(nr,"creating a Hugging Face Hub account"),nr.forEach(e),vs=u(Ga," if you don\u2019t have one yet."),Ga.forEach(e),Xe=p(t),P=o(t,"H2",{class:!0});var Va=r(P);q=o(Va,"A",{id:!0,class:!0,href:!0});var ur=r(q);ne=o(ur,"SPAN",{});var hr=r(ne);c(at.$$.fragment,hr),hr.forEach(e),ur.forEach(e),ms=p(Va),ue=o(Va,"SPAN",{});var fr=r(ue);ys=u(fr,"Upload with the Hub UI"),fr.forEach(e),Va.forEach(e),Ye=p(t),qt=o(t,"P",{});var pr=r(qt);_s=u(pr,"The Hub\u2019s web-based interface allows users without any developer experience to upload a dataset."),pr.forEach(e),Ze=p(t),D=o(t,"H3",{class:!0});var za=r(D);M=o(za,"A",{id:!0,class:!0,href:!0});var dr=r(M);he=o(dr,"SPAN",{});var cr=r(he);c(st.$$.fragment,cr),cr.forEach(e),dr.forEach(e),gs=p(za),fe=o(za,"SPAN",{});var vr=r(fe);ws=u(vr,"Create a repository"),vr.forEach(e),za.forEach(e),ta=p(t),Mt=o(t,"P",{});var mr=r(Mt);$s=u(mr,"A repository hosts all your dataset files, including the revision history, making storing more than one dataset version possible."),mr.forEach(e),ea=p(t),F=o(t,"OL",{});var Wa=r(F);ot=o(Wa,"LI",{});var Ra=r(ot);Es=u(Ra,"Click on your profile and select "),pe=o(Ra,"STRONG",{});var yr=r(pe);bs=u(yr,"New Dataset"),yr.forEach(e),ks=u(Ra," to create a new dataset repository."),Ra.forEach(e),As=p(Wa),de=o(Wa,"LI",{});var _r=r(de);Ps=u(_r,"Pick a name for your dataset, and choose whether it is a public or private dataset. A public dataset is visible to anyone, whereas a private dataset can only be viewed by you or members of your organization."),_r.forEach(e),Wa.forEach(e),aa=p(t),rt=o(t,"DIV",{class:!0});var gr=r(rt);ce=o(gr,"IMG",{src:!0}),gr.forEach(e),sa=p(t),S=o(t,"H3",{class:!0});var Ja=r(S);G=o(Ja,"A",{id:!0,class:!0,href:!0});var wr=r(G);ve=o(wr,"SPAN",{});var $r=r(ve);c(lt.$$.fragment,$r),$r.forEach(e),wr.forEach(e),Ds=p(Ja),me=o(Ja,"SPAN",{});var Er=r(me);Ss=u(Er,"Upload dataset"),Er.forEach(e),Ja.forEach(e),oa=p(t),Ft=o(t,"OL",{});var br=r(Ft);g=o(br,"LI",{});var b=r(g);Ls=u(b,"Once you\u2019ve created a repository, navigate to the "),ye=o(b,"STRONG",{});var kr=r(ye);js=u(kr,"Files and versions"),kr.forEach(e),xs=u(b," tab to add a file. Select "),_e=o(b,"STRONG",{});var Ar=r(_e);Hs=u(Ar,"Add file"),Ar.forEach(e),Is=u(b," to upload your dataset files. We currently support the following data formats: CSV, JSON, JSON lines, text, and Parquet. For this tutorial, you can use the following sample CSV files: "),it=o(b,"A",{href:!0,download:!0});var Pr=r(it);Ns=u(Pr,"train.csv"),Pr.forEach(e),Cs=u(b,", "),nt=o(b,"A",{href:!0,download:!0});var Dr=r(nt);Ts=u(Dr,"test.csv"),Dr.forEach(e),Os=u(b,"."),b.forEach(e),br.forEach(e),ra=p(t),ut=o(t,"DIV",{class:!0});var Sr=r(ut);ge=o(Sr,"IMG",{src:!0}),Sr.forEach(e),la=p(t),ht=o(t,"OL",{start:!0});var Lr=r(ht);we=o(Lr,"LI",{});var jr=r(we);Us=u(jr,"Drag and drop your dataset files and add a brief descriptive commit message."),jr.forEach(e),Lr.forEach(e),ia=p(t),ft=o(t,"DIV",{class:!0});var xr=r(ft);$e=o(xr,"IMG",{src:!0}),xr.forEach(e),na=p(t),pt=o(t,"OL",{start:!0});var Hr=r(pt);Ee=o(Hr,"LI",{});var Ir=r(Ee);qs=u(Ir,"After uploading your dataset files, they are stored in your dataset repository."),Ir.forEach(e),Hr.forEach(e),ua=p(t),dt=o(t,"DIV",{class:!0});var Nr=r(dt);be=o(Nr,"IMG",{src:!0}),Nr.forEach(e),ha=p(t),L=o(t,"H3",{class:!0});var Ba=r(L);V=o(Ba,"A",{id:!0,class:!0,href:!0});var Cr=r(V);ke=o(Cr,"SPAN",{});var Tr=r(ke);c(ct.$$.fragment,Tr),Tr.forEach(e),Cr.forEach(e),Ms=p(Ba),Ae=o(Ba,"SPAN",{});var Or=r(Ae);Fs=u(Or,"Create a Dataset card"),Or.forEach(e),Ba.forEach(e),fa=p(t),Gt=o(t,"P",{});var Ur=r(Gt);Gs=u(Ur,"Adding a Dataset card is super valuable for helping users find your dataset and understand how to use it responsibly."),Ur.forEach(e),pa=p(t),Vt=o(t,"OL",{});var qr=r(Vt);j=o(qr,"LI",{});var te=r(j);Vs=u(te,"Click on "),Pe=o(te,"STRONG",{});var Mr=r(Pe);zs=u(Mr,"Create Dataset Card"),Mr.forEach(e),Ws=u(te," to create a Dataset card. This button creates a "),De=o(te,"CODE",{});var Fr=r(De);Rs=u(Fr,"README.md"),Fr.forEach(e),Js=u(te," file in your repository."),te.forEach(e),qr.forEach(e),da=p(t),vt=o(t,"DIV",{class:!0});var Gr=r(vt);Se=o(Gr,"IMG",{src:!0}),Gr.forEach(e),ca=p(t),w=o(t,"OL",{start:!0});var ee=r(w);Le=o(ee,"LI",{});var Vr=r(Le);mt=o(Vr,"P",{});var Ka=r(mt);Bs=u(Ka,"Feel free to copy this Dataset card "),yt=o(Ka,"A",{href:!0,rel:!0});var zr=r(yt);Ks=u(zr,"template"),zr.forEach(e),Qs=u(Ka," to help you fill out all the relevant fields."),Ka.forEach(e),Vr.forEach(e),Xs=p(ee),je=o(ee,"LI",{});var Wr=r(je);_t=o(Wr,"P",{});var Qa=r(_t);Ys=u(Qa,"The Dataset card uses structured tags to help users discover your dataset on the Hub. Use the "),gt=o(Qa,"A",{href:!0,rel:!0});var Rr=r(gt);Zs=u(Rr,"Dataset Tagger"),Rr.forEach(e),to=u(Qa," to help you generate the appropriate tags."),Qa.forEach(e),Wr.forEach(e),eo=p(ee),xe=o(ee,"LI",{});var Jr=r(xe);He=o(Jr,"P",{});var Br=r(He);ao=u(Br,"Copy the generated tags, paste them at the top of your Dataset card, and then commit your changes."),Br.forEach(e),Jr.forEach(e),ee.forEach(e),va=p(t),wt=o(t,"DIV",{class:!0});var Kr=r(wt);Ie=o(Kr,"IMG",{src:!0}),Kr.forEach(e),ma=p(t),z=o(t,"P",{});var Xa=r(z);so=u(Xa,"For a detailed example of what a good Dataset card should look like, take a look at the "),$t=o(Xa,"A",{href:!0,rel:!0});var Qr=r($t);oo=u(Qr,"CNN DailyMail Dataset card"),Qr.forEach(e),ro=u(Xa,"."),Xa.forEach(e),ya=p(t),x=o(t,"H3",{class:!0});var Ya=r(x);W=o(Ya,"A",{id:!0,class:!0,href:!0});var Xr=r(W);Ne=o(Xr,"SPAN",{});var Yr=r(Ne);c(Et.$$.fragment,Yr),Yr.forEach(e),Xr.forEach(e),lo=p(Ya),Ce=o(Ya,"SPAN",{});var Zr=r(Ce);io=u(Zr,"Load dataset"),Zr.forEach(e),Ya.forEach(e),_a=p(t),R=o(t,"P",{});var Za=r(R);no=u(Za,"Once your dataset is stored on the Hub, anyone can load it with the "),zt=o(Za,"A",{href:!0});var tl=r(zt);uo=u(tl,"load_dataset()"),tl.forEach(e),ho=u(Za," function:"),Za.forEach(e),ga=p(t),c(bt.$$.fragment,t),wa=p(t),H=o(t,"H2",{class:!0});var ts=r(H);J=o(ts,"A",{id:!0,class:!0,href:!0});var el=r(J);Te=o(el,"SPAN",{});var al=r(Te);c(kt.$$.fragment,al),al.forEach(e),el.forEach(e),fo=p(ts),Oe=o(ts,"SPAN",{});var sl=r(Oe);po=u(sl,"Upload with Python"),sl.forEach(e),ts.forEach(e),$a=p(t),B=o(t,"P",{});var es=r(B);co=u(es,"Users who prefer to upload a dataset programmatically can use the "),At=o(es,"A",{href:!0,rel:!0});var ol=r(At);vo=u(ol,"huggingface_hub"),ol.forEach(e),mo=u(es," library. This library allows users to interact with the Hub from Python."),es.forEach(e),Ea=p(t),Wt=o(t,"OL",{});var rl=r(Wt);Ue=o(rl,"LI",{});var ll=r(Ue);yo=u(ll,"Begin by installing the library:"),ll.forEach(e),rl.forEach(e),ba=p(t),c(Pt.$$.fragment,t),ka=p(t),Dt=o(t,"OL",{start:!0});var il=r(Dt);qe=o(il,"LI",{});var nl=r(qe);_o=u(nl,"To upload a dataset on the Hub in Python, you need to log in to your Hugging Face account:"),nl.forEach(e),il.forEach(e),Aa=p(t),c(St.$$.fragment,t),Pa=p(t),Lt=o(t,"OL",{start:!0});var ul=r(Lt);jt=o(ul,"LI",{});var as=r(jt);go=u(as,"Use the "),xt=o(as,"A",{href:!0,rel:!0});var hl=r(xt);Me=o(hl,"CODE",{});var fl=r(Me);wo=u(fl,"push_to_hub()"),fl.forEach(e),hl.forEach(e),$o=u(as," function to help you add, commit, and push a file to your repository:"),as.forEach(e),ul.forEach(e),Da=p(t),c(Ht.$$.fragment,t),Sa=p(t),$=o(t,"P",{});var ae=r($);Eo=u(ae,"To set your dataset as private, set the "),Fe=o(ae,"CODE",{});var pl=r(Fe);bo=u(pl,"private"),pl.forEach(e),ko=u(ae," parameter to "),Ge=o(ae,"CODE",{});var dl=r(Ge);Ao=u(dl,"True"),dl.forEach(e),Po=u(ae,". This parameter will only work if you are creating a repository for the first time."),ae.forEach(e),La=p(t),c(It.$$.fragment,t),ja=p(t),I=o(t,"H3",{class:!0});var ss=r(I);K=o(ss,"A",{id:!0,class:!0,href:!0});var cl=r(K);Ve=o(cl,"SPAN",{});var vl=r(Ve);c(Nt.$$.fragment,vl),vl.forEach(e),cl.forEach(e),Do=p(ss),ze=o(ss,"SPAN",{});var ml=r(ze);So=u(ml,"Privacy"),ml.forEach(e),ss.forEach(e),xa=p(t),Rt=o(t,"P",{});var yl=r(Rt);Lo=u(yl,"A private dataset is only accessible by you. Similarly, if you share a dataset within your organization, then members of the organization can also access the dataset."),yl.forEach(e),Ha=p(t),Q=o(t,"P",{});var os=r(Q);jo=u(os,"Load a private dataset by providing your authentication token to the "),We=o(os,"CODE",{});var _l=r(We);xo=u(_l,"use_auth_token"),_l.forEach(e),Ho=u(os," parameter:"),os.forEach(e),Ia=p(t),c(Ct.$$.fragment,t),Na=p(t),N=o(t,"H2",{class:!0});var rs=r(N);X=o(rs,"A",{id:!0,class:!0,href:!0});var gl=r(X);Re=o(gl,"SPAN",{});var wl=r(Re);c(Tt.$$.fragment,wl),wl.forEach(e),gl.forEach(e),Io=p(rs),Je=o(rs,"SPAN",{});var $l=r(Je);No=u($l,"What's next?"),$l.forEach(e),rs.forEach(e),Ca=p(t),Jt=o(t,"P",{});var El=r(Jt);Co=u(El,"Congratulations, you\u2019ve completed the tutorials! \u{1F973}"),El.forEach(e),Ta=p(t),Bt=o(t,"P",{});var bl=r(Bt);To=u(bl,"From here, you can go on to:"),bl.forEach(e),Oa=p(t),E=o(t,"UL",{});var se=r(E);Ot=o(se,"LI",{});var ls=r(Ot);Oo=u(ls,"Learn more about how to use \u{1F917} Datasets other functions to "),Kt=o(ls,"A",{href:!0});var kl=r(Kt);Uo=u(kl,"process your dataset"),kl.forEach(e),qo=u(ls,"."),ls.forEach(e),Mo=p(se),Qt=o(se,"LI",{});var Ko=r(Qt);Xt=o(Ko,"A",{href:!0});var Al=r(Xt);Fo=u(Al,"Stream large datasets"),Al.forEach(e),Go=u(Ko," without downloading it locally."),Ko.forEach(e),Vo=p(se),Yt=o(se,"LI",{});var Qo=r(Yt);Zt=o(Qo,"A",{href:!0});var Pl=r(Zt);zo=u(Pl,"Write a dataset loading script"),Pl.forEach(e),Wo=u(Qo," and share your dataset with the community."),Qo.forEach(e),se.forEach(e),Ua=p(t),Y=o(t,"P",{});var is=r(Y);Ro=u(is,"If you have any questions about \u{1F917} Datasets, feel free to join and ask the community on our "),Ut=o(is,"A",{href:!0,rel:!0});var Dl=r(Ut);Jo=u(Dl,"forum"),Dl.forEach(e),Bo=u(is,"."),is.forEach(e),this.h()},h(){h(k,"name","hf:doc:metadata"),h(k,"content",JSON.stringify(Cl)),h(T,"id","share-a-dataset-to-the-hub"),h(T,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),h(T,"href","#share-a-dataset-to-the-hub"),h(A,"class","relative group"),h(tt,"href","https://huggingface.co/datasets"),h(tt,"rel","nofollow"),h(et,"href","https://huggingface.co/join"),h(et,"rel","nofollow"),h(q,"id","upload-with-the-hub-ui"),h(q,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),h(q,"href","#upload-with-the-hub-ui"),h(P,"class","relative group"),h(M,"id","create-a-repository"),h(M,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),h(M,"href","#create-a-repository"),h(D,"class","relative group"),oe(ce.src,Yo="https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/datasets/create_repo.png")||h(ce,"src",Yo),h(rt,"class","flex justify-center"),h(G,"id","upload-dataset"),h(G,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),h(G,"href","#upload-dataset"),h(S,"class","relative group"),h(it,"href","https://huggingface.co/datasets/stevhliu/demo/raw/main/train.csv"),h(it,"download",""),h(nt,"href","https://huggingface.co/datasets/stevhliu/demo/raw/main/test.csv"),h(nt,"download",""),oe(ge.src,Zo="https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/datasets/upload_files.png")||h(ge,"src",Zo),h(ut,"class","flex justify-center"),h(ht,"start","2"),oe($e.src,tr="https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/datasets/commit_files.png")||h($e,"src",tr),h(ft,"class","flex justify-center"),h(pt,"start","3"),oe(be.src,er="https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/datasets/files_stored.png")||h(be,"src",er),h(dt,"class","flex justify-center"),h(V,"id","create-a-dataset-card"),h(V,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),h(V,"href","#create-a-dataset-card"),h(L,"class","relative group"),oe(Se.src,ar="https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/datasets/dataset_card.png")||h(Se,"src",ar),h(vt,"class","flex justify-center"),h(yt,"href","https://raw.githubusercontent.com/huggingface/datasets/main/templates/README.md"),h(yt,"rel","nofollow"),h(gt,"href","https://huggingface.co/spaces/huggingface/datasets-tagging"),h(gt,"rel","nofollow"),h(w,"start","2"),oe(Ie.src,sr="https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/datasets/card_tags.png")||h(Ie,"src",sr),h(wt,"class","flex justify-center"),h($t,"href","https://huggingface.co/datasets/cnn_dailymail"),h($t,"rel","nofollow"),h(W,"id","load-dataset"),h(W,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),h(W,"href","#load-dataset"),h(x,"class","relative group"),h(zt,"href","/docs/datasets/v2.8.0/en/package_reference/loading_methods#datasets.load_dataset"),h(J,"id","upload-with-python"),h(J,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),h(J,"href","#upload-with-python"),h(H,"class","relative group"),h(At,"href","https://huggingface.co/docs/huggingface_hub/index"),h(At,"rel","nofollow"),h(Dt,"start","2"),h(xt,"href","https://huggingface.co/docs/datasets/main/en/package_reference/main_classes#datasets.DatasetDict.push_to_hub"),h(xt,"rel","nofollow"),h(Lt,"start","3"),h(K,"id","privacy"),h(K,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),h(K,"href","#privacy"),h(I,"class","relative group"),h(X,"id","whats-next"),h(X,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),h(X,"href","#whats-next"),h(N,"class","relative group"),h(Kt,"href","process"),h(Xt,"href","stream"),h(Zt,"href","dataset_script"),h(Ut,"href","https://discuss.huggingface.co/c/datasets/10"),h(Ut,"rel","nofollow")},m(t,l){a(document.head,k),i(t,Be,l),i(t,A,l),a(A,T),a(T,le),v(Z,le,null),a(A,ns),a(A,ie),a(ie,us),i(t,Ke,l),i(t,O,l),a(O,hs),a(O,tt),a(tt,fs),a(O,ps),i(t,Qe,l),i(t,U,l),a(U,ds),a(U,et),a(et,cs),a(U,vs),i(t,Xe,l),i(t,P,l),a(P,q),a(q,ne),v(at,ne,null),a(P,ms),a(P,ue),a(ue,ys),i(t,Ye,l),i(t,qt,l),a(qt,_s),i(t,Ze,l),i(t,D,l),a(D,M),a(M,he),v(st,he,null),a(D,gs),a(D,fe),a(fe,ws),i(t,ta,l),i(t,Mt,l),a(Mt,$s),i(t,ea,l),i(t,F,l),a(F,ot),a(ot,Es),a(ot,pe),a(pe,bs),a(ot,ks),a(F,As),a(F,de),a(de,Ps),i(t,aa,l),i(t,rt,l),a(rt,ce),i(t,sa,l),i(t,S,l),a(S,G),a(G,ve),v(lt,ve,null),a(S,Ds),a(S,me),a(me,Ss),i(t,oa,l),i(t,Ft,l),a(Ft,g),a(g,Ls),a(g,ye),a(ye,js),a(g,xs),a(g,_e),a(_e,Hs),a(g,Is),a(g,it),a(it,Ns),a(g,Cs),a(g,nt),a(nt,Ts),a(g,Os),i(t,ra,l),i(t,ut,l),a(ut,ge),i(t,la,l),i(t,ht,l),a(ht,we),a(we,Us),i(t,ia,l),i(t,ft,l),a(ft,$e),i(t,na,l),i(t,pt,l),a(pt,Ee),a(Ee,qs),i(t,ua,l),i(t,dt,l),a(dt,be),i(t,ha,l),i(t,L,l),a(L,V),a(V,ke),v(ct,ke,null),a(L,Ms),a(L,Ae),a(Ae,Fs),i(t,fa,l),i(t,Gt,l),a(Gt,Gs),i(t,pa,l),i(t,Vt,l),a(Vt,j),a(j,Vs),a(j,Pe),a(Pe,zs),a(j,Ws),a(j,De),a(De,Rs),a(j,Js),i(t,da,l),i(t,vt,l),a(vt,Se),i(t,ca,l),i(t,w,l),a(w,Le),a(Le,mt),a(mt,Bs),a(mt,yt),a(yt,Ks),a(mt,Qs),a(w,Xs),a(w,je),a(je,_t),a(_t,Ys),a(_t,gt),a(gt,Zs),a(_t,to),a(w,eo),a(w,xe),a(xe,He),a(He,ao),i(t,va,l),i(t,wt,l),a(wt,Ie),i(t,ma,l),i(t,z,l),a(z,so),a(z,$t),a($t,oo),a(z,ro),i(t,ya,l),i(t,x,l),a(x,W),a(W,Ne),v(Et,Ne,null),a(x,lo),a(x,Ce),a(Ce,io),i(t,_a,l),i(t,R,l),a(R,no),a(R,zt),a(zt,uo),a(R,ho),i(t,ga,l),v(bt,t,l),i(t,wa,l),i(t,H,l),a(H,J),a(J,Te),v(kt,Te,null),a(H,fo),a(H,Oe),a(Oe,po),i(t,$a,l),i(t,B,l),a(B,co),a(B,At),a(At,vo),a(B,mo),i(t,Ea,l),i(t,Wt,l),a(Wt,Ue),a(Ue,yo),i(t,ba,l),v(Pt,t,l),i(t,ka,l),i(t,Dt,l),a(Dt,qe),a(qe,_o),i(t,Aa,l),v(St,t,l),i(t,Pa,l),i(t,Lt,l),a(Lt,jt),a(jt,go),a(jt,xt),a(xt,Me),a(Me,wo),a(jt,$o),i(t,Da,l),v(Ht,t,l),i(t,Sa,l),i(t,$,l),a($,Eo),a($,Fe),a(Fe,bo),a($,ko),a($,Ge),a(Ge,Ao),a($,Po),i(t,La,l),v(It,t,l),i(t,ja,l),i(t,I,l),a(I,K),a(K,Ve),v(Nt,Ve,null),a(I,Do),a(I,ze),a(ze,So),i(t,xa,l),i(t,Rt,l),a(Rt,Lo),i(t,Ha,l),i(t,Q,l),a(Q,jo),a(Q,We),a(We,xo),a(Q,Ho),i(t,Ia,l),v(Ct,t,l),i(t,Na,l),i(t,N,l),a(N,X),a(X,Re),v(Tt,Re,null),a(N,Io),a(N,Je),a(Je,No),i(t,Ca,l),i(t,Jt,l),a(Jt,Co),i(t,Ta,l),i(t,Bt,l),a(Bt,To),i(t,Oa,l),i(t,E,l),a(E,Ot),a(Ot,Oo),a(Ot,Kt),a(Kt,Uo),a(Ot,qo),a(E,Mo),a(E,Qt),a(Qt,Xt),a(Xt,Fo),a(Qt,Go),a(E,Vo),a(E,Yt),a(Yt,Zt),a(Zt,zo),a(Yt,Wo),i(t,Ua,l),i(t,Y,l),a(Y,Ro),a(Y,Ut),a(Ut,Jo),a(Y,Bo),qa=!0},p:Hl,i(t){qa||(m(Z.$$.fragment,t),m(at.$$.fragment,t),m(st.$$.fragment,t),m(lt.$$.fragment,t),m(ct.$$.fragment,t),m(Et.$$.fragment,t),m(bt.$$.fragment,t),m(kt.$$.fragment,t),m(Pt.$$.fragment,t),m(St.$$.fragment,t),m(Ht.$$.fragment,t),m(It.$$.fragment,t),m(Nt.$$.fragment,t),m(Ct.$$.fragment,t),m(Tt.$$.fragment,t),qa=!0)},o(t){y(Z.$$.fragment,t),y(at.$$.fragment,t),y(st.$$.fragment,t),y(lt.$$.fragment,t),y(ct.$$.fragment,t),y(Et.$$.fragment,t),y(bt.$$.fragment,t),y(kt.$$.fragment,t),y(Pt.$$.fragment,t),y(St.$$.fragment,t),y(Ht.$$.fragment,t),y(It.$$.fragment,t),y(Nt.$$.fragment,t),y(Ct.$$.fragment,t),y(Tt.$$.fragment,t),qa=!1},d(t){e(k),t&&e(Be),t&&e(A),_(Z),t&&e(Ke),t&&e(O),t&&e(Qe),t&&e(U),t&&e(Xe),t&&e(P),_(at),t&&e(Ye),t&&e(qt),t&&e(Ze),t&&e(D),_(st),t&&e(ta),t&&e(Mt),t&&e(ea),t&&e(F),t&&e(aa),t&&e(rt),t&&e(sa),t&&e(S),_(lt),t&&e(oa),t&&e(Ft),t&&e(ra),t&&e(ut),t&&e(la),t&&e(ht),t&&e(ia),t&&e(ft),t&&e(na),t&&e(pt),t&&e(ua),t&&e(dt),t&&e(ha),t&&e(L),_(ct),t&&e(fa),t&&e(Gt),t&&e(pa),t&&e(Vt),t&&e(da),t&&e(vt),t&&e(ca),t&&e(w),t&&e(va),t&&e(wt),t&&e(ma),t&&e(z),t&&e(ya),t&&e(x),_(Et),t&&e(_a),t&&e(R),t&&e(ga),_(bt,t),t&&e(wa),t&&e(H),_(kt),t&&e($a),t&&e(B),t&&e(Ea),t&&e(Wt),t&&e(ba),_(Pt,t),t&&e(ka),t&&e(Dt),t&&e(Aa),_(St,t),t&&e(Pa),t&&e(Lt),t&&e(Da),_(Ht,t),t&&e(Sa),t&&e($),t&&e(La),_(It,t),t&&e(ja),t&&e(I),_(Nt),t&&e(xa),t&&e(Rt),t&&e(Ha),t&&e(Q),t&&e(Ia),_(Ct,t),t&&e(Na),t&&e(N),_(Tt),t&&e(Ca),t&&e(Jt),t&&e(Ta),t&&e(Bt),t&&e(Oa),t&&e(E),t&&e(Ua),t&&e(Y)}}}const Cl={local:"share-a-dataset-to-the-hub",sections:[{local:"upload-with-the-hub-ui",sections:[{local:"create-a-repository",title:"Create a repository"},{local:"upload-dataset",title:"Upload dataset"},{local:"create-a-dataset-card",title:"Create a Dataset card"},{local:"load-dataset",title:"Load dataset"}],title:"Upload with the Hub UI"},{local:"upload-with-python",sections:[{local:"privacy",title:"Privacy"}],title:"Upload with Python"},{local:"whats-next",title:"What's next?"}],title:"Share a dataset to the Hub"};function Tl(Xo){return Il(()=>{new URLSearchParams(window.location.search).get("fw")}),[]}class Ml extends Sl{constructor(k){super();Ll(this,k,Tl,Nl,jl,{})}}export{Ml as default,Cl as metadata};
