Buckets:

HuggingFaceDocBuilder's picture
download
raw
22.4 kB
import{s as Ct,o as xt,n as at}from"../chunks/scheduler.31fdf58d.js";import{S as Tt,i as Mt,e as l,s as a,c as u,h as yt,a as p,d as n,b as o,f as I,j as f,g as _,k as q,l as s,m,n as g,t as h,o as k,p as $}from"../chunks/index.2f76fdf0.js";import{T as Lt}from"../chunks/Tip.8d349121.js";import{C as zt}from"../chunks/CopyLLMTxtMenu.53b607bf.js";import{D as S}from"../chunks/Docstring.7acc6835.js";import{C as wt}from"../chunks/CodeBlock.e52df5d6.js";import{E as bt}from"../chunks/ExampleCodeBlock.f9704f52.js";import{H as He,E as It}from"../chunks/MermaidChart.svelte_svelte_type_style_lang.08750ec0.js";function qt(P){let r,C=`CPM’s architecture is the same as GPT-2, except for tokenization method. Refer to <a href="gpt2">GPT-2 documentation</a> for
API reference information.`;return{c(){r=l("p"),r.innerHTML=C},l(d){r=p(d,"P",{"data-svelte-h":!0}),f(r)!=="svelte-1vcdcb"&&(r.innerHTML=C)},m(d,c){m(d,r,c)},p:at,d(d){d&&n(r)}}}function Dt(P){let r,C="sequence pair mask has the following format:",d,c,v;return c=new wt({props:{code:"MCUyMDAlMjAwJTIwMCUyMDAlMjAwJTIwMCUyMDAlMjAwJTIwMCUyMDAlMjAxJTIwMSUyMDElMjAxJTIwMSUyMDElMjAxJTIwMSUyMDElMEElN0MlMjBmaXJzdCUyMHNlcXVlbmNlJTIwJTIwJTIwJTIwJTdDJTIwc2Vjb25kJTIwc2VxdWVuY2UlMjAlN0M=",highlighted:`0<span class="hljs-number"> 0 </span>0<span class="hljs-number"> 0 </span>0<span class="hljs-number"> 0 </span>0<span class="hljs-number"> 0 </span>0<span class="hljs-number"> 0 </span>0<span class="hljs-number"> 1 </span>1<span class="hljs-number"> 1 </span>1<span class="hljs-number"> 1 </span>1<span class="hljs-number"> 1 </span>1 1
| first sequence | second sequence |`,lang:"",wrap:!1}}),{c(){r=l("p"),r.textContent=C,d=a(),u(c.$$.fragment)},l(i){r=p(i,"P",{"data-svelte-h":!0}),f(r)!=="svelte-16klr56"&&(r.textContent=C),d=o(i),_(c.$$.fragment,i)},m(i,T){m(i,r,T),m(i,d,T),g(c,i,T),v=!0},p:at,i(i){v||(h(c.$$.fragment,i),v=!0)},o(i){k(c.$$.fragment,i),v=!1},d(i){i&&(n(r),n(d)),$(c,i)}}}function Pt(P){let r,C="sequence pair mask has the following format:",d,c,v;return c=new wt({props:{code:"MCUyMDAlMjAwJTIwMCUyMDAlMjAwJTIwMCUyMDAlMjAwJTIwMCUyMDAlMjAxJTIwMSUyMDElMjAxJTIwMSUyMDElMjAxJTIwMSUyMDElMEElN0MlMjBmaXJzdCUyMHNlcXVlbmNlJTIwJTIwJTIwJTIwJTdDJTIwc2Vjb25kJTIwc2VxdWVuY2UlMjAlN0M=",highlighted:`0<span class="hljs-number"> 0 </span>0<span class="hljs-number"> 0 </span>0<span class="hljs-number"> 0 </span>0<span class="hljs-number"> 0 </span>0<span class="hljs-number"> 0 </span>0<span class="hljs-number"> 1 </span>1<span class="hljs-number"> 1 </span>1<span class="hljs-number"> 1 </span>1<span class="hljs-number"> 1 </span>1 1
| first sequence | second sequence |`,lang:"",wrap:!1}}),{c(){r=l("p"),r.textContent=C,d=a(),u(c.$$.fragment)},l(i){r=p(i,"P",{"data-svelte-h":!0}),f(r)!=="svelte-16klr56"&&(r.textContent=C),d=o(i),_(c.$$.fragment,i)},m(i,T){m(i,r,T),m(i,d,T),g(c,i,T),v=!0},p:at,i(i){v||(h(c.$$.fragment,i),v=!0)},o(i){k(c.$$.fragment,i),v=!1},d(i){i&&(n(r),n(d)),$(c,i)}}}function jt(P){let r,C,d,c,v,i="<em>This model was published in HF papers on 2020-12-01 and contributed to Hugging Face Transformers on 2021-04-10.</em>",T,V,we,G,Ce,X,xe,B,ot=`The CPM model was proposed in <a href="https://huggingface.co/papers/2012.00413" rel="nofollow">CPM: A Large-scale Generative Chinese Pre-trained Language Model</a> by Zhengyan Zhang, Xu Han, Hao Zhou, Pei Ke, Yuxian Gu, Deming Ye, Yujia Qin,
Yusheng Su, Haozhe Ji, Jian Guan, Fanchao Qi, Xiaozhi Wang, Yanan Zheng, Guoyang Zeng, Huanqi Cao, Shengqi Chen,
Daixuan Li, Zhenbo Sun, Zhiyuan Liu, Minlie Huang, Wentao Han, Jie Tang, Juanzi Li, Xiaoyan Zhu, Maosong Sun.`,Te,O,rt="The abstract from the paper is the following:",Me,R,it=`<em>Pre-trained Language Models (PLMs) have proven to be beneficial for various downstream NLP tasks. Recently, GPT-3,
with 175 billion parameters and 570GB training data, drew a lot of attention due to the capacity of few-shot (even
zero-shot) learning. However, applying GPT-3 to address Chinese NLP tasks is still challenging, as the training corpus
of GPT-3 is primarily English, and the parameters are not publicly available. In this technical report, we release the
Chinese Pre-trained Language Model (CPM) with generative pre-training on large-scale Chinese training data. To the best
of our knowledge, CPM, with 2.6 billion parameters and 100GB Chinese training data, is the largest Chinese pre-trained
language model, which could facilitate several downstream Chinese NLP tasks, such as conversation, essay generation,
cloze test, and language understanding. Extensive experiments demonstrate that CPM achieves strong performance on many
NLP tasks in the settings of few-shot (even zero-shot) learning.</em>`,ye,Z,lt=`This model was contributed by <a href="https://huggingface.co/canwenxu" rel="nofollow">canwenxu</a>. The original implementation can be found
here: <a href="https://github.com/TsinghuaAI/CPM-Generate" rel="nofollow">https://github.com/TsinghuaAI/CPM-Generate</a>`,Le,j,ze,Y,Ie,b,W,Ne,le,pt="Runs pre-tokenization with Jieba-RS segmentation tool. It is used in CPM models.",Ee,L,Q,Fe,pe,mt=`Build model inputs from a sequence or a pair of sequence for sequence classification tasks by concatenating and
adding special tokens. An XLNet sequence has the following format:`,Ue,me,ct="<li>single sequence: <code>X &lt;sep&gt; &lt;cls&gt;</code></li> <li>pair of sequences: <code>A &lt;sep&gt; B &lt;sep&gt; &lt;cls&gt;</code></li>",Se,A,K,Ve,ce,dt="Converts a sequence of tokens (strings for sub-words) in a single string.",Ge,M,ee,Xe,de,ft="Create a mask from the two sequences passed to be used in a sequence-pair classification task. An XLNet",Be,J,Oe,fe,ut="If <code>token_ids_1</code> is <code>None</code>, this method only returns the first portion of the mask (0s).",Re,H,te,Ze,ue,_t=`Retrieve sequence ids from a token list that has no special tokens added. This method is called when adding
special tokens using the tokenizer <code>prepare_for_model</code> method.`,qe,ne,De,x,se,Ye,_e,gt="Runs pre-tokenization with Jieba-RS segmentation tool. It is used in CPM models.",We,z,ae,Qe,ge,ht=`Build model inputs from a sequence or a pair of sequence for sequence classification tasks by concatenating and
adding special tokens. An XLNet sequence has the following format:`,Ke,he,kt="<li>single sequence: <code>X &lt;sep&gt; &lt;cls&gt;</code></li> <li>pair of sequences: <code>A &lt;sep&gt; B &lt;sep&gt; &lt;cls&gt;</code></li>",et,y,oe,tt,ke,$t="Create a mask from the two sequences passed to be used in a sequence-pair classification task. An XLNet",nt,N,st,$e,vt="If <code>token_ids_1</code> is <code>None</code>, this method only returns the first portion of the mask (0s).",Pe,re,je,be,Ae;return V=new zt({props:{containerStyle:"float: right; margin-left: 10px; display: inline-flex; position: relative; z-index: 10;"}}),G=new He({props:{title:"CPM",local:"cpm",headingTag:"h1"}}),X=new He({props:{title:"Overview",local:"overview",headingTag:"h2"}}),j=new Lt({props:{$$slots:{default:[qt]},$$scope:{ctx:P}}}),Y=new He({props:{title:"CpmTokenizer",local:"transformers.CpmTokenizer",headingTag:"h2"}}),W=new S({props:{name:"class transformers.CpmTokenizer",anchor:"transformers.CpmTokenizer",parameters:[{name:"vocab_file",val:""},{name:"do_lower_case",val:" = False"},{name:"remove_space",val:" = True"},{name:"keep_accents",val:" = False"},{name:"bos_token",val:" = '<s>'"},{name:"eos_token",val:" = '</s>'"},{name:"unk_token",val:" = '<unk>'"},{name:"sep_token",val:" = '<sep>'"},{name:"pad_token",val:" = '<pad>'"},{name:"cls_token",val:" = '<cls>'"},{name:"mask_token",val:" = '<mask>'"},{name:"additional_special_tokens",val:" = ['<eop>', '<eod>']"},{name:"sp_model_kwargs",val:": dict[str, typing.Any] | None = None"},{name:"**kwargs",val:""}],source:"https://github.com/huggingface/transformers/blob/vr_43265/src/transformers/models/cpm/tokenization_cpm.py#L34"}}),Q=new S({props:{name:"build_inputs_with_special_tokens",anchor:"transformers.CpmTokenizer.build_inputs_with_special_tokens",parameters:[{name:"token_ids_0",val:": list"},{name:"token_ids_1",val:": list[int] | None = None"}],parametersDescription:[{anchor:"transformers.CpmTokenizer.build_inputs_with_special_tokens.token_ids_0",description:`<strong>token_ids_0</strong> (<code>list[int]</code>) &#x2014;
List of IDs to which the special tokens will be added.`,name:"token_ids_0"},{anchor:"transformers.CpmTokenizer.build_inputs_with_special_tokens.token_ids_1",description:`<strong>token_ids_1</strong> (<code>list[int]</code>, <em>optional</em>) &#x2014;
Optional second list of IDs for sequence pairs.`,name:"token_ids_1"}],source:"https://github.com/huggingface/transformers/blob/vr_43265/src/transformers/models/cpm/tokenization_cpm.py#L230",returnDescription:`<script context="module">export const metadata = 'undefined';<\/script>
<p>List of <a href="../glossary#input-ids">input IDs</a> with the appropriate special tokens.</p>
`,returnType:`<script context="module">export const metadata = 'undefined';<\/script>
<p><code>list[int]</code></p>
`}}),K=new S({props:{name:"convert_tokens_to_string",anchor:"transformers.CpmTokenizer.convert_tokens_to_string",parameters:[{name:"tokens",val:""}],source:"https://github.com/huggingface/transformers/blob/vr_43265/src/transformers/models/cpm/tokenization_cpm.py#L225"}}),ee=new S({props:{name:"create_token_type_ids_from_sequences",anchor:"transformers.CpmTokenizer.create_token_type_ids_from_sequences",parameters:[{name:"token_ids_0",val:": list"},{name:"token_ids_1",val:": list[int] | None = None"}],parametersDescription:[{anchor:"transformers.CpmTokenizer.create_token_type_ids_from_sequences.token_ids_0",description:`<strong>token_ids_0</strong> (<code>list[int]</code>) &#x2014;
List of IDs.`,name:"token_ids_0"},{anchor:"transformers.CpmTokenizer.create_token_type_ids_from_sequences.token_ids_1",description:`<strong>token_ids_1</strong> (<code>list[int]</code>, <em>optional</em>) &#x2014;
Optional second list of IDs for sequence pairs.`,name:"token_ids_1"}],source:"https://github.com/huggingface/transformers/blob/vr_43265/src/transformers/models/cpm/tokenization_cpm.py#L283",returnDescription:`<script context="module">export const metadata = 'undefined';<\/script>
<p>List of <a href="../glossary#token-type-ids">token type IDs</a> according to the given sequence(s).</p>
`,returnType:`<script context="module">export const metadata = 'undefined';<\/script>
<p><code>list[int]</code></p>
`}}),J=new bt({props:{anchor:"transformers.CpmTokenizer.create_token_type_ids_from_sequences.example",$$slots:{default:[Dt]},$$scope:{ctx:P}}}),te=new S({props:{name:"get_special_tokens_mask",anchor:"transformers.CpmTokenizer.get_special_tokens_mask",parameters:[{name:"token_ids_0",val:": list"},{name:"token_ids_1",val:": list[int] | None = None"},{name:"already_has_special_tokens",val:": bool = False"}],parametersDescription:[{anchor:"transformers.CpmTokenizer.get_special_tokens_mask.token_ids_0",description:`<strong>token_ids_0</strong> (<code>list[int]</code>) &#x2014;
List of IDs.`,name:"token_ids_0"},{anchor:"transformers.CpmTokenizer.get_special_tokens_mask.token_ids_1",description:`<strong>token_ids_1</strong> (<code>list[int]</code>, <em>optional</em>) &#x2014;
Optional second list of IDs for sequence pairs.`,name:"token_ids_1"},{anchor:"transformers.CpmTokenizer.get_special_tokens_mask.already_has_special_tokens",description:`<strong>already_has_special_tokens</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>False</code>) &#x2014;
Whether or not the token list is already formatted with special tokens for the model.`,name:"already_has_special_tokens"}],source:"https://github.com/huggingface/transformers/blob/vr_43265/src/transformers/models/cpm/tokenization_cpm.py#L255",returnDescription:`<script context="module">export const metadata = 'undefined';<\/script>
<p>A list of integers in the range [0, 1]: 1 for a special token, 0 for a sequence token.</p>
`,returnType:`<script context="module">export const metadata = 'undefined';<\/script>
<p><code>list[int]</code></p>
`}}),ne=new He({props:{title:"CpmTokenizerFast",local:"transformers.CpmTokenizerFast",headingTag:"h2"}}),se=new S({props:{name:"class transformers.CpmTokenizerFast",anchor:"transformers.CpmTokenizerFast",parameters:[{name:"vocab_file",val:" = None"},{name:"tokenizer_file",val:" = None"},{name:"do_lower_case",val:" = False"},{name:"remove_space",val:" = True"},{name:"keep_accents",val:" = False"},{name:"bos_token",val:" = '<s>'"},{name:"eos_token",val:" = '</s>'"},{name:"unk_token",val:" = '<unk>'"},{name:"sep_token",val:" = '<sep>'"},{name:"pad_token",val:" = '<pad>'"},{name:"cls_token",val:" = '<cls>'"},{name:"mask_token",val:" = '<mask>'"},{name:"additional_special_tokens",val:" = ['<eop>', '<eod>']"},{name:"**kwargs",val:""}],source:"https://github.com/huggingface/transformers/blob/vr_43265/src/transformers/models/cpm/tokenization_cpm_fast.py#L28"}}),ae=new S({props:{name:"build_inputs_with_special_tokens",anchor:"transformers.CpmTokenizerFast.build_inputs_with_special_tokens",parameters:[{name:"token_ids_0",val:": list"},{name:"token_ids_1",val:": list[int] | None = None"}],parametersDescription:[{anchor:"transformers.CpmTokenizerFast.build_inputs_with_special_tokens.token_ids_0",description:`<strong>token_ids_0</strong> (<code>list[int]</code>) &#x2014;
List of IDs to which the special tokens will be added.`,name:"token_ids_0"},{anchor:"transformers.CpmTokenizerFast.build_inputs_with_special_tokens.token_ids_1",description:`<strong>token_ids_1</strong> (<code>list[int]</code>, <em>optional</em>) &#x2014;
Optional second list of IDs for sequence pairs.`,name:"token_ids_1"}],source:"https://github.com/huggingface/transformers/blob/vr_43265/src/transformers/models/cpm/tokenization_cpm_fast.py#L145",returnDescription:`<script context="module">export const metadata = 'undefined';<\/script>
<p>List of <a href="../glossary#input-ids">input IDs</a> with the appropriate special tokens.</p>
`,returnType:`<script context="module">export const metadata = 'undefined';<\/script>
<p><code>list[int]</code></p>
`}}),oe=new S({props:{name:"create_token_type_ids_from_sequences",anchor:"transformers.CpmTokenizerFast.create_token_type_ids_from_sequences",parameters:[{name:"token_ids_0",val:": list"},{name:"token_ids_1",val:": list[int] | None = None"}],parametersDescription:[{anchor:"transformers.CpmTokenizerFast.create_token_type_ids_from_sequences.token_ids_0",description:`<strong>token_ids_0</strong> (<code>list[int]</code>) &#x2014;
List of IDs.`,name:"token_ids_0"},{anchor:"transformers.CpmTokenizerFast.create_token_type_ids_from_sequences.token_ids_1",description:`<strong>token_ids_1</strong> (<code>list[int]</code>, <em>optional</em>) &#x2014;
Optional second list of IDs for sequence pairs.`,name:"token_ids_1"}],source:"https://github.com/huggingface/transformers/blob/vr_43265/src/transformers/models/cpm/tokenization_cpm_fast.py#L170",returnDescription:`<script context="module">export const metadata = 'undefined';<\/script>
<p>List of <a href="../glossary#token-type-ids">token type IDs</a> according to the given sequence(s).</p>
`,returnType:`<script context="module">export const metadata = 'undefined';<\/script>
<p><code>list[int]</code></p>
`}}),N=new bt({props:{anchor:"transformers.CpmTokenizerFast.create_token_type_ids_from_sequences.example",$$slots:{default:[Pt]},$$scope:{ctx:P}}}),re=new It({props:{source:"https://github.com/huggingface/transformers/blob/main/docs/source/en/model_doc/cpm.md"}}),{c(){r=l("meta"),C=a(),d=l("p"),c=a(),v=l("p"),v.innerHTML=i,T=a(),u(V.$$.fragment),we=a(),u(G.$$.fragment),Ce=a(),u(X.$$.fragment),xe=a(),B=l("p"),B.innerHTML=ot,Te=a(),O=l("p"),O.textContent=rt,Me=a(),R=l("p"),R.innerHTML=it,ye=a(),Z=l("p"),Z.innerHTML=lt,Le=a(),u(j.$$.fragment),ze=a(),u(Y.$$.fragment),Ie=a(),b=l("div"),u(W.$$.fragment),Ne=a(),le=l("p"),le.textContent=pt,Ee=a(),L=l("div"),u(Q.$$.fragment),Fe=a(),pe=l("p"),pe.textContent=mt,Ue=a(),me=l("ul"),me.innerHTML=ct,Se=a(),A=l("div"),u(K.$$.fragment),Ve=a(),ce=l("p"),ce.textContent=dt,Ge=a(),M=l("div"),u(ee.$$.fragment),Xe=a(),de=l("p"),de.textContent=ft,Be=a(),u(J.$$.fragment),Oe=a(),fe=l("p"),fe.innerHTML=ut,Re=a(),H=l("div"),u(te.$$.fragment),Ze=a(),ue=l("p"),ue.innerHTML=_t,qe=a(),u(ne.$$.fragment),De=a(),x=l("div"),u(se.$$.fragment),Ye=a(),_e=l("p"),_e.textContent=gt,We=a(),z=l("div"),u(ae.$$.fragment),Qe=a(),ge=l("p"),ge.textContent=ht,Ke=a(),he=l("ul"),he.innerHTML=kt,et=a(),y=l("div"),u(oe.$$.fragment),tt=a(),ke=l("p"),ke.textContent=$t,nt=a(),u(N.$$.fragment),st=a(),$e=l("p"),$e.innerHTML=vt,Pe=a(),u(re.$$.fragment),je=a(),be=l("p"),this.h()},l(e){const t=yt("svelte-u9bgzb",document.head);r=p(t,"META",{name:!0,content:!0}),t.forEach(n),C=o(e),d=p(e,"P",{}),I(d).forEach(n),c=o(e),v=p(e,"P",{"data-svelte-h":!0}),f(v)!=="svelte-nicx4q"&&(v.innerHTML=i),T=o(e),_(V.$$.fragment,e),we=o(e),_(G.$$.fragment,e),Ce=o(e),_(X.$$.fragment,e),xe=o(e),B=p(e,"P",{"data-svelte-h":!0}),f(B)!=="svelte-nzi2dc"&&(B.innerHTML=ot),Te=o(e),O=p(e,"P",{"data-svelte-h":!0}),f(O)!=="svelte-vfdo9a"&&(O.textContent=rt),Me=o(e),R=p(e,"P",{"data-svelte-h":!0}),f(R)!=="svelte-2grs0w"&&(R.innerHTML=it),ye=o(e),Z=p(e,"P",{"data-svelte-h":!0}),f(Z)!=="svelte-deid5f"&&(Z.innerHTML=lt),Le=o(e),_(j.$$.fragment,e),ze=o(e),_(Y.$$.fragment,e),Ie=o(e),b=p(e,"DIV",{class:!0});var w=I(b);_(W.$$.fragment,w),Ne=o(w),le=p(w,"P",{"data-svelte-h":!0}),f(le)!=="svelte-1r9usbn"&&(le.textContent=pt),Ee=o(w),L=p(w,"DIV",{class:!0});var D=I(L);_(Q.$$.fragment,D),Fe=o(D),pe=p(D,"P",{"data-svelte-h":!0}),f(pe)!=="svelte-1dgk30w"&&(pe.textContent=mt),Ue=o(D),me=p(D,"UL",{"data-svelte-h":!0}),f(me)!=="svelte-zi1mnq"&&(me.innerHTML=ct),D.forEach(n),Se=o(w),A=p(w,"DIV",{class:!0});var ie=I(A);_(K.$$.fragment,ie),Ve=o(ie),ce=p(ie,"P",{"data-svelte-h":!0}),f(ce)!=="svelte-1ne8awa"&&(ce.textContent=dt),ie.forEach(n),Ge=o(w),M=p(w,"DIV",{class:!0});var E=I(M);_(ee.$$.fragment,E),Xe=o(E),de=p(E,"P",{"data-svelte-h":!0}),f(de)!=="svelte-1nwvqaq"&&(de.textContent=ft),Be=o(E),_(J.$$.fragment,E),Oe=o(E),fe=p(E,"P",{"data-svelte-h":!0}),f(fe)!=="svelte-owoxgn"&&(fe.innerHTML=ut),E.forEach(n),Re=o(w),H=p(w,"DIV",{class:!0});var Je=I(H);_(te.$$.fragment,Je),Ze=o(Je),ue=p(Je,"P",{"data-svelte-h":!0}),f(ue)!=="svelte-1f4f5kp"&&(ue.innerHTML=_t),Je.forEach(n),w.forEach(n),qe=o(e),_(ne.$$.fragment,e),De=o(e),x=p(e,"DIV",{class:!0});var F=I(x);_(se.$$.fragment,F),Ye=o(F),_e=p(F,"P",{"data-svelte-h":!0}),f(_e)!=="svelte-1r9usbn"&&(_e.textContent=gt),We=o(F),z=p(F,"DIV",{class:!0});var ve=I(z);_(ae.$$.fragment,ve),Qe=o(ve),ge=p(ve,"P",{"data-svelte-h":!0}),f(ge)!=="svelte-1dgk30w"&&(ge.textContent=ht),Ke=o(ve),he=p(ve,"UL",{"data-svelte-h":!0}),f(he)!=="svelte-zi1mnq"&&(he.innerHTML=kt),ve.forEach(n),et=o(F),y=p(F,"DIV",{class:!0});var U=I(y);_(oe.$$.fragment,U),tt=o(U),ke=p(U,"P",{"data-svelte-h":!0}),f(ke)!=="svelte-1nwvqaq"&&(ke.textContent=$t),nt=o(U),_(N.$$.fragment,U),st=o(U),$e=p(U,"P",{"data-svelte-h":!0}),f($e)!=="svelte-owoxgn"&&($e.innerHTML=vt),U.forEach(n),F.forEach(n),Pe=o(e),_(re.$$.fragment,e),je=o(e),be=p(e,"P",{}),I(be).forEach(n),this.h()},h(){q(r,"name","hf:doc:metadata"),q(r,"content",At),q(L,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),q(A,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),q(M,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),q(H,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),q(b,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),q(z,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),q(y,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),q(x,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8")},m(e,t){s(document.head,r),m(e,C,t),m(e,d,t),m(e,c,t),m(e,v,t),m(e,T,t),g(V,e,t),m(e,we,t),g(G,e,t),m(e,Ce,t),g(X,e,t),m(e,xe,t),m(e,B,t),m(e,Te,t),m(e,O,t),m(e,Me,t),m(e,R,t),m(e,ye,t),m(e,Z,t),m(e,Le,t),g(j,e,t),m(e,ze,t),g(Y,e,t),m(e,Ie,t),m(e,b,t),g(W,b,null),s(b,Ne),s(b,le),s(b,Ee),s(b,L),g(Q,L,null),s(L,Fe),s(L,pe),s(L,Ue),s(L,me),s(b,Se),s(b,A),g(K,A,null),s(A,Ve),s(A,ce),s(b,Ge),s(b,M),g(ee,M,null),s(M,Xe),s(M,de),s(M,Be),g(J,M,null),s(M,Oe),s(M,fe),s(b,Re),s(b,H),g(te,H,null),s(H,Ze),s(H,ue),m(e,qe,t),g(ne,e,t),m(e,De,t),m(e,x,t),g(se,x,null),s(x,Ye),s(x,_e),s(x,We),s(x,z),g(ae,z,null),s(z,Qe),s(z,ge),s(z,Ke),s(z,he),s(x,et),s(x,y),g(oe,y,null),s(y,tt),s(y,ke),s(y,nt),g(N,y,null),s(y,st),s(y,$e),m(e,Pe,t),g(re,e,t),m(e,je,t),m(e,be,t),Ae=!0},p(e,[t]){const w={};t&2&&(w.$$scope={dirty:t,ctx:e}),j.$set(w);const D={};t&2&&(D.$$scope={dirty:t,ctx:e}),J.$set(D);const ie={};t&2&&(ie.$$scope={dirty:t,ctx:e}),N.$set(ie)},i(e){Ae||(h(V.$$.fragment,e),h(G.$$.fragment,e),h(X.$$.fragment,e),h(j.$$.fragment,e),h(Y.$$.fragment,e),h(W.$$.fragment,e),h(Q.$$.fragment,e),h(K.$$.fragment,e),h(ee.$$.fragment,e),h(J.$$.fragment,e),h(te.$$.fragment,e),h(ne.$$.fragment,e),h(se.$$.fragment,e),h(ae.$$.fragment,e),h(oe.$$.fragment,e),h(N.$$.fragment,e),h(re.$$.fragment,e),Ae=!0)},o(e){k(V.$$.fragment,e),k(G.$$.fragment,e),k(X.$$.fragment,e),k(j.$$.fragment,e),k(Y.$$.fragment,e),k(W.$$.fragment,e),k(Q.$$.fragment,e),k(K.$$.fragment,e),k(ee.$$.fragment,e),k(J.$$.fragment,e),k(te.$$.fragment,e),k(ne.$$.fragment,e),k(se.$$.fragment,e),k(ae.$$.fragment,e),k(oe.$$.fragment,e),k(N.$$.fragment,e),k(re.$$.fragment,e),Ae=!1},d(e){e&&(n(C),n(d),n(c),n(v),n(T),n(we),n(Ce),n(xe),n(B),n(Te),n(O),n(Me),n(R),n(ye),n(Z),n(Le),n(ze),n(Ie),n(b),n(qe),n(De),n(x),n(Pe),n(je),n(be)),n(r),$(V,e),$(G,e),$(X,e),$(j,e),$(Y,e),$(W),$(Q),$(K),$(ee),$(J),$(te),$(ne,e),$(se),$(ae),$(oe),$(N),$(re,e)}}}const At='{"title":"CPM","local":"cpm","sections":[{"title":"Overview","local":"overview","sections":[],"depth":2},{"title":"CpmTokenizer","local":"transformers.CpmTokenizer","sections":[],"depth":2},{"title":"CpmTokenizerFast","local":"transformers.CpmTokenizerFast","sections":[],"depth":2}],"depth":1}';function Jt(P){return xt(()=>{new URLSearchParams(window.location.search).get("fw")}),[]}class Xt extends Tt{constructor(r){super(),Mt(this,r,Jt,jt,Ct,{})}}export{Xt as component};

Xet Storage Details

Size:
22.4 kB
·
Xet hash:
b4acc5654b8f166c7789300eb56c234a9835286fc951ccd0c5342dd00bf25772

Xet efficiently stores files, intelligently splitting them into unique chunks and accelerating uploads and downloads. More info.