import{s as al,o as nl,n as H}from"../chunks/scheduler.25b97de1.js";import{S as ll,i as rl,g,s as i,r as c,A as ol,h as y,f as n,c as p,j as Y,u as f,x as b,k as tl,y as J,a as l,v as d,d as u,t as h,w as $}from"../chunks/index.d9030fc9.js";import{T as is}from"../chunks/Tip.baa67368.js";import{Y as sl}from"../chunks/Youtube.eaf1a617.js";import{C as _}from"../chunks/CodeBlock.e6cd0d95.js";import{D as il}from"../chunks/DocNotebookDropdown.5ea6cb78.js";import{F as Qt,M as L}from"../chunks/Markdown.7217f838.js";import{H as q,E as pl}from"../chunks/EditOnGithub.91d95064.js";function ml(T){let s,o;return s=new _({props:{code:"cGlwJTIwaW5zdGFsbCUyMHRvcmNo",highlighted:"pip install torch",wrap:!1}}),{c(){c(s.$$.fragment)},l(t){f(s.$$.fragment,t)},m(t,r){d(s,t,r),o=!0},p:H,i(t){o||(u(s.$$.fragment,t),o=!0)},o(t){h(s.$$.fragment,t),o=!1},d(t){$(s,t)}}}function cl(T){let s,o;return s=new L({props:{$$slots:{default:[ml]},$$scope:{ctx:T}}}),{c(){c(s.$$.fragment)},l(t){f(s.$$.fragment,t)},m(t,r){d(s,t,r),o=!0},p(t,r){const M={};r&2&&(M.$$scope={dirty:r,ctx:t}),s.$set(M)},i(t){o||(u(s.$$.fragment,t),o=!0)},o(t){h(s.$$.fragment,t),o=!1},d(t){$(s,t)}}}function fl(T){let s,o;return s=new _({props:{code:"cGlwJTIwaW5zdGFsbCUyMHRlbnNvcmZsb3c=",highlighted:"pip install tensorflow",wrap:!1}}),{c(){c(s.$$.fragment)},l(t){f(s.$$.fragment,t)},m(t,r){d(s,t,r),o=!0},p:H,i(t){o||(u(s.$$.fragment,t),o=!0)},o(t){h(s.$$.fragment,t),o=!1},d(t){$(s,t)}}}function dl(T){let s,o;return s=new L({props:{$$slots:{default:[fl]},$$scope:{ctx:T}}}),{c(){c(s.$$.fragment)},l(t){f(s.$$.fragment,t)},m(t,r){d(s,t,r),o=!0},p(t,r){const M={};r&2&&(M.$$scope={dirty:r,ctx:t}),s.$set(M)},i(t){o||(u(s.$$.fragment,t),o=!0)},o(t){h(s.$$.fragment,t),o=!1},d(t){$(s,t)}}}function ul(T){let s,o='For a complete list of available tasks, check out the <a href="./main_classes/pipelines">pipeline API reference</a>.';return{c(){s=g("p"),s.innerHTML=o},l(t){s=y(t,"P",{"data-svelte-h":!0}),b(s)!=="svelte-yyszjd"&&(s.innerHTML=o)},m(t,r){l(t,s,r)},p:H,d(t){t&&n(s)}}}function hl(T){let s,o='Use <a href="/docs/transformers/main/en/model_doc/auto#transformers.AutoModelForSequenceClassification">AutoModelForSequenceClassification</a> and <a href="/docs/transformers/main/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a> to load the pretrained model and it’s associated tokenizer (more on an <code>AutoClass</code> in the next section):',t,r,M;return r=new _({props:{code:"ZnJvbSUyMHRyYW5zZm9ybWVycyUyMGltcG9ydCUyMEF1dG9Ub2tlbml6ZXIlMkMlMjBBdXRvTW9kZWxGb3JTZXF1ZW5jZUNsYXNzaWZpY2F0aW9uJTBBJTBBbW9kZWwlMjAlM0QlMjBBdXRvTW9kZWxGb3JTZXF1ZW5jZUNsYXNzaWZpY2F0aW9uLmZyb21fcHJldHJhaW5lZChtb2RlbF9uYW1lKSUwQXRva2VuaXplciUyMCUzRCUyMEF1dG9Ub2tlbml6ZXIuZnJvbV9wcmV0cmFpbmVkKG1vZGVsX25hbWUp",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, AutoModelForSequenceClassification

<span class="hljs-meta">&gt;&gt;&gt; </span>model = AutoModelForSequenceClassification.from_pretrained(model_name)
<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.from_pretrained(model_name)`,wrap:!1}}),{c(){s=g("p"),s.innerHTML=o,t=i(),c(r.$$.fragment)},l(m){s=y(m,"P",{"data-svelte-h":!0}),b(s)!=="svelte-1magt38"&&(s.innerHTML=o),t=p(m),f(r.$$.fragment,m)},m(m,U){l(m,s,U),l(m,t,U),d(r,m,U),M=!0},p:H,i(m){M||(u(r.$$.fragment,m),M=!0)},o(m){h(r.$$.fragment,m),M=!1},d(m){m&&(n(s),n(t)),$(r,m)}}}function $l(T){let s,o;return s=new L({props:{$$slots:{default:[hl]},$$scope:{ctx:T}}}),{c(){c(s.$$.fragment)},l(t){f(s.$$.fragment,t)},m(t,r){d(s,t,r),o=!0},p(t,r){const M={};r&2&&(M.$$scope={dirty:r,ctx:t}),s.$set(M)},i(t){o||(u(s.$$.fragment,t),o=!0)},o(t){h(s.$$.fragment,t),o=!1},d(t){$(s,t)}}}function gl(T){let s,o='Use <a href="/docs/transformers/main/en/model_doc/auto#transformers.TFAutoModelForSequenceClassification">TFAutoModelForSequenceClassification</a> and <a href="/docs/transformers/main/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a> to load the pretrained model and it’s associated tokenizer (more on an <code>TFAutoClass</code> in the next section):',t,r,M;return r=new _({props:{code:"ZnJvbSUyMHRyYW5zZm9ybWVycyUyMGltcG9ydCUyMEF1dG9Ub2tlbml6ZXIlMkMlMjBURkF1dG9Nb2RlbEZvclNlcXVlbmNlQ2xhc3NpZmljYXRpb24lMEElMEFtb2RlbCUyMCUzRCUyMFRGQXV0b01vZGVsRm9yU2VxdWVuY2VDbGFzc2lmaWNhdGlvbi5mcm9tX3ByZXRyYWluZWQobW9kZWxfbmFtZSklMEF0b2tlbml6ZXIlMjAlM0QlMjBBdXRvVG9rZW5pemVyLmZyb21fcHJldHJhaW5lZChtb2RlbF9uYW1lKQ==",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, TFAutoModelForSequenceClassification

<span class="hljs-meta">&gt;&gt;&gt; </span>model = TFAutoModelForSequenceClassification.from_pretrained(model_name)
<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.from_pretrained(model_name)`,wrap:!1}}),{c(){s=g("p"),s.innerHTML=o,t=i(),c(r.$$.fragment)},l(m){s=y(m,"P",{"data-svelte-h":!0}),b(s)!=="svelte-ucahb2"&&(s.innerHTML=o),t=p(m),f(r.$$.fragment,m)},m(m,U){l(m,s,U),l(m,t,U),d(r,m,U),M=!0},p:H,i(m){M||(u(r.$$.fragment,m),M=!0)},o(m){h(r.$$.fragment,m),M=!1},d(m){m&&(n(s),n(t)),$(r,m)}}}function yl(T){let s,o;return s=new L({props:{$$slots:{default:[gl]},$$scope:{ctx:T}}}),{c(){c(s.$$.fragment)},l(t){f(s.$$.fragment,t)},m(t,r){d(s,t,r),o=!0},p(t,r){const M={};r&2&&(M.$$scope={dirty:r,ctx:t}),s.$set(M)},i(t){o||(u(s.$$.fragment,t),o=!0)},o(t){h(s.$$.fragment,t),o=!1},d(t){$(s,t)}}}function Ml(T){let s,o;return s=new _({props:{code:"cHRfYmF0Y2glMjAlM0QlMjB0b2tlbml6ZXIoJTBBJTIwJTIwJTIwJTIwJTVCJTIyV2UlMjBhcmUlMjB2ZXJ5JTIwaGFwcHklMjB0byUyMHNob3clMjB5b3UlMjB0aGUlMjAlRjAlOUYlQTQlOTclMjBUcmFuc2Zvcm1lcnMlMjBsaWJyYXJ5LiUyMiUyQyUyMCUyMldlJTIwaG9wZSUyMHlvdSUyMGRvbid0JTIwaGF0ZSUyMGl0LiUyMiU1RCUyQyUwQSUyMCUyMCUyMCUyMHBhZGRpbmclM0RUcnVlJTJDJTBBJTIwJTIwJTIwJTIwdHJ1bmNhdGlvbiUzRFRydWUlMkMlMEElMjAlMjAlMjAlMjBtYXhfbGVuZ3RoJTNENTEyJTJDJTBBJTIwJTIwJTIwJTIwcmV0dXJuX3RlbnNvcnMlM0QlMjJwdCUyMiUyQyUwQSk=",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span>pt_batch = tokenizer(
<span class="hljs-meta">... </span>    [<span class="hljs-string">&quot;We are very happy to show you the 🤗 Transformers library.&quot;</span>, <span class="hljs-string">&quot;We hope you don&#x27;t hate it.&quot;</span>],
<span class="hljs-meta">... </span>    padding=<span class="hljs-literal">True</span>,
<span class="hljs-meta">... </span>    truncation=<span class="hljs-literal">True</span>,
<span class="hljs-meta">... </span>    max_length=<span class="hljs-number">512</span>,
<span class="hljs-meta">... </span>    return_tensors=<span class="hljs-string">&quot;pt&quot;</span>,
<span class="hljs-meta">... </span>)`,wrap:!1}}),{c(){c(s.$$.fragment)},l(t){f(s.$$.fragment,t)},m(t,r){d(s,t,r),o=!0},p:H,i(t){o||(u(s.$$.fragment,t),o=!0)},o(t){h(s.$$.fragment,t),o=!1},d(t){$(s,t)}}}function bl(T){let s,o;return s=new L({props:{$$slots:{default:[Ml]},$$scope:{ctx:T}}}),{c(){c(s.$$.fragment)},l(t){f(s.$$.fragment,t)},m(t,r){d(s,t,r),o=!0},p(t,r){const M={};r&2&&(M.$$scope={dirty:r,ctx:t}),s.$set(M)},i(t){o||(u(s.$$.fragment,t),o=!0)},o(t){h(s.$$.fragment,t),o=!1},d(t){$(s,t)}}}function wl(T){let s,o;return s=new _({props:{code:"dGZfYmF0Y2glMjAlM0QlMjB0b2tlbml6ZXIoJTBBJTIwJTIwJTIwJTIwJTVCJTIyV2UlMjBhcmUlMjB2ZXJ5JTIwaGFwcHklMjB0byUyMHNob3clMjB5b3UlMjB0aGUlMjAlRjAlOUYlQTQlOTclMjBUcmFuc2Zvcm1lcnMlMjBsaWJyYXJ5LiUyMiUyQyUyMCUyMldlJTIwaG9wZSUyMHlvdSUyMGRvbid0JTIwaGF0ZSUyMGl0LiUyMiU1RCUyQyUwQSUyMCUyMCUyMCUyMHBhZGRpbmclM0RUcnVlJTJDJTBBJTIwJTIwJTIwJTIwdHJ1bmNhdGlvbiUzRFRydWUlMkMlMEElMjAlMjAlMjAlMjBtYXhfbGVuZ3RoJTNENTEyJTJDJTBBJTIwJTIwJTIwJTIwcmV0dXJuX3RlbnNvcnMlM0QlMjJ0ZiUyMiUyQyUwQSk=",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span>tf_batch = tokenizer(
<span class="hljs-meta">... </span>    [<span class="hljs-string">&quot;We are very happy to show you the 🤗 Transformers library.&quot;</span>, <span class="hljs-string">&quot;We hope you don&#x27;t hate it.&quot;</span>],
<span class="hljs-meta">... </span>    padding=<span class="hljs-literal">True</span>,
<span class="hljs-meta">... </span>    truncation=<span class="hljs-literal">True</span>,
<span class="hljs-meta">... </span>    max_length=<span class="hljs-number">512</span>,
<span class="hljs-meta">... </span>    return_tensors=<span class="hljs-string">&quot;tf&quot;</span>,
<span class="hljs-meta">... </span>)`,wrap:!1}}),{c(){c(s.$$.fragment)},l(t){f(s.$$.fragment,t)},m(t,r){d(s,t,r),o=!0},p:H,i(t){o||(u(s.$$.fragment,t),o=!0)},o(t){h(s.$$.fragment,t),o=!1},d(t){$(s,t)}}}function Tl(T){let s,o;return s=new L({props:{$$slots:{default:[wl]},$$scope:{ctx:T}}}),{c(){c(s.$$.fragment)},l(t){f(s.$$.fragment,t)},m(t,r){d(s,t,r),o=!0},p(t,r){const M={};r&2&&(M.$$scope={dirty:r,ctx:t}),s.$set(M)},i(t){o||(u(s.$$.fragment,t),o=!0)},o(t){h(s.$$.fragment,t),o=!1},d(t){$(s,t)}}}function jl(T){let s,o='Check out the <a href="./preprocessing">preprocess</a> tutorial for more details about tokenization, and how to use an <a href="/docs/transformers/main/en/model_doc/auto#transformers.AutoImageProcessor">AutoImageProcessor</a>, <a href="/docs/transformers/main/en/model_doc/auto#transformers.AutoFeatureExtractor">AutoFeatureExtractor</a> and <a href="/docs/transformers/main/en/model_doc/auto#transformers.AutoProcessor">AutoProcessor</a> to preprocess image, audio, and multimodal inputs.';return{c(){s=g("p"),s.innerHTML=o},l(t){s=y(t,"P",{"data-svelte-h":!0}),b(s)!=="svelte-1xk5c2w"&&(s.innerHTML=o)},m(t,r){l(t,s,r)},p:H,d(t){t&&n(s)}}}function kl(T){let s,o='See the <a href="./task_summary">task summary</a> for tasks supported by an <a href="/docs/transformers/main/en/model_doc/auto#transformers.AutoModel">AutoModel</a> class.';return{c(){s=g("p"),s.innerHTML=o},l(t){s=y(t,"P",{"data-svelte-h":!0}),b(s)!=="svelte-11k4zea"&&(s.innerHTML=o)},m(t,r){l(t,s,r)},p:H,d(t){t&&n(s)}}}function _l(T){let s,o='🤗 Transformers provides a simple and unified way to load pretrained instances. This means you can load an <a href="/docs/transformers/main/en/model_doc/auto#transformers.AutoModel">AutoModel</a> like you would load an <a href="/docs/transformers/main/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. The only difference is selecting the correct <a href="/docs/transformers/main/en/model_doc/auto#transformers.AutoModel">AutoModel</a> for the task. For text (or sequence) classification, you should load <a href="/docs/transformers/main/en/model_doc/auto#transformers.AutoModelForSequenceClassification">AutoModelForSequenceClassification</a>.',t,r,M="By default, the weights are loaded in full precision (torch.float32) regardless of the actual data type the weights are stored in such as torch.float16. Set <code>torch_dtype=&quot;auto&quot;</code> to load the weights in the data type defined in a model’s <code>config.json</code> file to automatically load the most memory-optimal data type.",m,U,G,v,R,w,Z="Now pass your preprocessed batch of inputs directly to the model. You just have to unpack the dictionary by adding <code>**</code>:",z,X,x,I,N="The model outputs the final activations in the <code>logits</code> attribute. Apply the softmax function to the <code>logits</code> to retrieve the probabilities:",k,C,F;return U=new _({props:{code:"ZnJvbSUyMHRyYW5zZm9ybWVycyUyMGltcG9ydCUyMEF1dG9Nb2RlbEZvclNlcXVlbmNlQ2xhc3NpZmljYXRpb24lMEElMEFtb2RlbF9uYW1lJTIwJTNEJTIwJTIybmxwdG93biUyRmJlcnQtYmFzZS1tdWx0aWxpbmd1YWwtdW5jYXNlZC1zZW50aW1lbnQlMjIlMEFwdF9tb2RlbCUyMCUzRCUyMEF1dG9Nb2RlbEZvclNlcXVlbmNlQ2xhc3NpZmljYXRpb24uZnJvbV9wcmV0cmFpbmVkKG1vZGVsX25hbWUlMkMlMjB0b3JjaF9kdHlwZSUzRCUyMmF1dG8lMjIp",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoModelForSequenceClassification

<span class="hljs-meta">&gt;&gt;&gt; </span>model_name = <span class="hljs-string">&quot;nlptown/bert-base-multilingual-uncased-sentiment&quot;</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>pt_model = AutoModelForSequenceClassification.from_pretrained(model_name, torch_dtype=<span class="hljs-string">&quot;auto&quot;</span>)`,wrap:!1}}),v=new is({props:{$$slots:{default:[kl]},$$scope:{ctx:T}}}),X=new _({props:{code:"cHRfb3V0cHV0cyUyMCUzRCUyMHB0X21vZGVsKCoqcHRfYmF0Y2gp",highlighted:'<span class="hljs-meta">&gt;&gt;&gt; </span>pt_outputs = pt_model(**pt_batch)',wrap:!1}}),C=new _({props:{code:"ZnJvbSUyMHRvcmNoJTIwaW1wb3J0JTIwbm4lMEElMEFwdF9wcmVkaWN0aW9ucyUyMCUzRCUyMG5uLmZ1bmN0aW9uYWwuc29mdG1heChwdF9vdXRwdXRzLmxvZ2l0cyUyQyUyMGRpbSUzRC0xKSUwQXByaW50KHB0X3ByZWRpY3Rpb25zKQ==",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> torch <span class="hljs-keyword">import</span> nn

<span class="hljs-meta">&gt;&gt;&gt; </span>pt_predictions = nn.functional.softmax(pt_outputs.logits, dim=-<span class="hljs-number">1</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-built_in">print</span>(pt_predictions)
tensor([[<span class="hljs-number">0.0021</span>, <span class="hljs-number">0.0018</span>, <span class="hljs-number">0.0115</span>, <span class="hljs-number">0.2121</span>, <span class="hljs-number">0.7725</span>],
        [<span class="hljs-number">0.2084</span>, <span class="hljs-number">0.1826</span>, <span class="hljs-number">0.1969</span>, <span class="hljs-number">0.1755</span>, <span class="hljs-number">0.2365</span>]], grad_fn=&lt;SoftmaxBackward0&gt;)`,wrap:!1}}),{c(){s=g("p"),s.innerHTML=o,t=i(),r=g("p"),r.innerHTML=M,m=i(),c(U.$$.fragment),G=i(),c(v.$$.fragment),R=i(),w=g("p"),w.innerHTML=Z,z=i(),c(X.$$.fragment),x=i(),I=g("p"),I.innerHTML=N,k=i(),c(C.$$.fragment)},l(j){s=y(j,"P",{"data-svelte-h":!0}),b(s)!=="svelte-8qmati"&&(s.innerHTML=o),t=p(j),r=y(j,"P",{"data-svelte-h":!0}),b(r)!=="svelte-9fdmcv"&&(r.innerHTML=M),m=p(j),f(U.$$.fragment,j),G=p(j),f(v.$$.fragment,j),R=p(j),w=y(j,"P",{"data-svelte-h":!0}),b(w)!=="svelte-wsvj9w"&&(w.innerHTML=Z),z=p(j),f(X.$$.fragment,j),x=p(j),I=y(j,"P",{"data-svelte-h":!0}),b(I)!=="svelte-17tdpgw"&&(I.innerHTML=N),k=p(j),f(C.$$.fragment,j)},m(j,W){l(j,s,W),l(j,t,W),l(j,r,W),l(j,m,W),d(U,j,W),l(j,G,W),d(v,j,W),l(j,R,W),l(j,w,W),l(j,z,W),d(X,j,W),l(j,x,W),l(j,I,W),l(j,k,W),d(C,j,W),F=!0},p(j,W){const re={};W&2&&(re.$$scope={dirty:W,ctx:j}),v.$set(re)},i(j){F||(u(U.$$.fragment,j),u(v.$$.fragment,j),u(X.$$.fragment,j),u(C.$$.fragment,j),F=!0)},o(j){h(U.$$.fragment,j),h(v.$$.fragment,j),h(X.$$.fragment,j),h(C.$$.fragment,j),F=!1},d(j){j&&(n(s),n(t),n(r),n(m),n(G),n(R),n(w),n(z),n(x),n(I),n(k)),$(U,j),$(v,j),$(X,j),$(C,j)}}}function Jl(T){let s,o;return s=new L({props:{$$slots:{default:[_l]},$$scope:{ctx:T}}}),{c(){c(s.$$.fragment)},l(t){f(s.$$.fragment,t)},m(t,r){d(s,t,r),o=!0},p(t,r){const M={};r&2&&(M.$$scope={dirty:r,ctx:t}),s.$set(M)},i(t){o||(u(s.$$.fragment,t),o=!0)},o(t){h(s.$$.fragment,t),o=!1},d(t){$(s,t)}}}function Ul(T){let s,o='See the <a href="./task_summary">task summary</a> for tasks supported by an <a href="/docs/transformers/main/en/model_doc/auto#transformers.AutoModel">AutoModel</a> class.';return{c(){s=g("p"),s.innerHTML=o},l(t){s=y(t,"P",{"data-svelte-h":!0}),b(s)!=="svelte-11k4zea"&&(s.innerHTML=o)},m(t,r){l(t,s,r)},p:H,d(t){t&&n(s)}}}function vl(T){let s,o='🤗 Transformers provides a simple and unified way to load pretrained instances. This means you can load an <a href="/docs/transformers/main/en/model_doc/auto#transformers.TFAutoModel">TFAutoModel</a> like you would load an <a href="/docs/transformers/main/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. The only difference is selecting the correct <a href="/docs/transformers/main/en/model_doc/auto#transformers.TFAutoModel">TFAutoModel</a> for the task. For text (or sequence) classification, you should load <a href="/docs/transformers/main/en/model_doc/auto#transformers.TFAutoModelForSequenceClassification">TFAutoModelForSequenceClassification</a>:',t,r,M,m,U,G,v="Now pass your preprocessed batch of inputs directly to the model. You can pass the tensors as-is:",R,w,Z,z,X="The model outputs the final activations in the <code>logits</code> attribute. Apply the softmax function to the <code>logits</code> to retrieve the probabilities:",x,I,N;return r=new _({props:{code:"ZnJvbSUyMHRyYW5zZm9ybWVycyUyMGltcG9ydCUyMFRGQXV0b01vZGVsRm9yU2VxdWVuY2VDbGFzc2lmaWNhdGlvbiUwQSUwQW1vZGVsX25hbWUlMjAlM0QlMjAlMjJubHB0b3duJTJGYmVydC1iYXNlLW11bHRpbGluZ3VhbC11bmNhc2VkLXNlbnRpbWVudCUyMiUwQXRmX21vZGVsJTIwJTNEJTIwVEZBdXRvTW9kZWxGb3JTZXF1ZW5jZUNsYXNzaWZpY2F0aW9uLmZyb21fcHJldHJhaW5lZChtb2RlbF9uYW1lKQ==",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> TFAutoModelForSequenceClassification

<span class="hljs-meta">&gt;&gt;&gt; </span>model_name = <span class="hljs-string">&quot;nlptown/bert-base-multilingual-uncased-sentiment&quot;</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>tf_model = TFAutoModelForSequenceClassification.from_pretrained(model_name)`,wrap:!1}}),m=new is({props:{$$slots:{default:[Ul]},$$scope:{ctx:T}}}),w=new _({props:{code:"dGZfb3V0cHV0cyUyMCUzRCUyMHRmX21vZGVsKHRmX2JhdGNoKQ==",highlighted:'<span class="hljs-meta">&gt;&gt;&gt; </span>tf_outputs = tf_model(tf_batch)',wrap:!1}}),I=new _({props:{code:"aW1wb3J0JTIwdGVuc29yZmxvdyUyMGFzJTIwdGYlMEElMEF0Zl9wcmVkaWN0aW9ucyUyMCUzRCUyMHRmLm5uLnNvZnRtYXgodGZfb3V0cHV0cy5sb2dpdHMlMkMlMjBheGlzJTNELTEpJTBBdGZfcHJlZGljdGlvbnM=",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">import</span> tensorflow <span class="hljs-keyword">as</span> tf

<span class="hljs-meta">&gt;&gt;&gt; </span>tf_predictions = tf.nn.softmax(tf_outputs.logits, axis=-<span class="hljs-number">1</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>tf_predictions`,wrap:!1}}),{c(){s=g("p"),s.innerHTML=o,t=i(),c(r.$$.fragment),M=i(),c(m.$$.fragment),U=i(),G=g("p"),G.textContent=v,R=i(),c(w.$$.fragment),Z=i(),z=g("p"),z.innerHTML=X,x=i(),c(I.$$.fragment)},l(k){s=y(k,"P",{"data-svelte-h":!0}),b(s)!=="svelte-1cx03ie"&&(s.innerHTML=o),t=p(k),f(r.$$.fragment,k),M=p(k),f(m.$$.fragment,k),U=p(k),G=y(k,"P",{"data-svelte-h":!0}),b(G)!=="svelte-19ydqo0"&&(G.textContent=v),R=p(k),f(w.$$.fragment,k),Z=p(k),z=y(k,"P",{"data-svelte-h":!0}),b(z)!=="svelte-17tdpgw"&&(z.innerHTML=X),x=p(k),f(I.$$.fragment,k)},m(k,C){l(k,s,C),l(k,t,C),d(r,k,C),l(k,M,C),d(m,k,C),l(k,U,C),l(k,G,C),l(k,R,C),d(w,k,C),l(k,Z,C),l(k,z,C),l(k,x,C),d(I,k,C),N=!0},p(k,C){const F={};C&2&&(F.$$scope={dirty:C,ctx:k}),m.$set(F)},i(k){N||(u(r.$$.fragment,k),u(m.$$.fragment,k),u(w.$$.fragment,k),u(I.$$.fragment,k),N=!0)},o(k){h(r.$$.fragment,k),h(m.$$.fragment,k),h(w.$$.fragment,k),h(I.$$.fragment,k),N=!1},d(k){k&&(n(s),n(t),n(M),n(U),n(G),n(R),n(Z),n(z),n(x)),$(r,k),$(m,k),$(w,k),$(I,k)}}}function Zl(T){let s,o;return s=new L({props:{$$slots:{default:[vl]},$$scope:{ctx:T}}}),{c(){c(s.$$.fragment)},l(t){f(s.$$.fragment,t)},m(t,r){d(s,t,r),o=!0},p(t,r){const M={};r&2&&(M.$$scope={dirty:r,ctx:t}),s.$set(M)},i(t){o||(u(s.$$.fragment,t),o=!0)},o(t){h(s.$$.fragment,t),o=!1},d(t){$(s,t)}}}function Cl(T){let s,o=`All 🤗 Transformers models (PyTorch or TensorFlow) output the tensors <em>before</em> the final activation
function (like softmax) because the final activation function is often fused with the loss. Model outputs are special dataclasses so their attributes are autocompleted in an IDE. The model outputs behave like a tuple or a dictionary (you can index with an integer, a slice or a string) in which case, attributes that are None are ignored.`;return{c(){s=g("p"),s.innerHTML=o},l(t){s=y(t,"P",{"data-svelte-h":!0}),b(s)!=="svelte-3ji870"&&(s.innerHTML=o)},m(t,r){l(t,s,r)},p:H,d(t){t&&n(s)}}}function Gl(T){let s,o='Once your model is fine-tuned, you can save it with its tokenizer using <a href="/docs/transformers/main/en/main_classes/model#transformers.PreTrainedModel.save_pretrained">PreTrainedModel.save_pretrained()</a>:',t,r,M,m,U='When you are ready to use the model again, reload it with <a href="/docs/transformers/main/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">PreTrainedModel.from_pretrained()</a>:',G,v,R;return r=new _({props:{code:"cHRfc2F2ZV9kaXJlY3RvcnklMjAlM0QlMjAlMjIuJTJGcHRfc2F2ZV9wcmV0cmFpbmVkJTIyJTBBdG9rZW5pemVyLnNhdmVfcHJldHJhaW5lZChwdF9zYXZlX2RpcmVjdG9yeSklMEFwdF9tb2RlbC5zYXZlX3ByZXRyYWluZWQocHRfc2F2ZV9kaXJlY3Rvcnkp",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span>pt_save_directory = <span class="hljs-string">&quot;./pt_save_pretrained&quot;</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer.save_pretrained(pt_save_directory)
<span class="hljs-meta">&gt;&gt;&gt; </span>pt_model.save_pretrained(pt_save_directory)`,wrap:!1}}),v=new _({props:{code:"cHRfbW9kZWwlMjAlM0QlMjBBdXRvTW9kZWxGb3JTZXF1ZW5jZUNsYXNzaWZpY2F0aW9uLmZyb21fcHJldHJhaW5lZCglMjIuJTJGcHRfc2F2ZV9wcmV0cmFpbmVkJTIyKQ==",highlighted:'<span class="hljs-meta">&gt;&gt;&gt; </span>pt_model = AutoModelForSequenceClassification.from_pretrained(<span class="hljs-string">&quot;./pt_save_pretrained&quot;</span>)',wrap:!1}}),{c(){s=g("p"),s.innerHTML=o,t=i(),c(r.$$.fragment),M=i(),m=g("p"),m.innerHTML=U,G=i(),c(v.$$.fragment)},l(w){s=y(w,"P",{"data-svelte-h":!0}),b(s)!=="svelte-1dfj42p"&&(s.innerHTML=o),t=p(w),f(r.$$.fragment,w),M=p(w),m=y(w,"P",{"data-svelte-h":!0}),b(m)!=="svelte-1h7e1vx"&&(m.innerHTML=U),G=p(w),f(v.$$.fragment,w)},m(w,Z){l(w,s,Z),l(w,t,Z),d(r,w,Z),l(w,M,Z),l(w,m,Z),l(w,G,Z),d(v,w,Z),R=!0},p:H,i(w){R||(u(r.$$.fragment,w),u(v.$$.fragment,w),R=!0)},o(w){h(r.$$.fragment,w),h(v.$$.fragment,w),R=!1},d(w){w&&(n(s),n(t),n(M),n(m),n(G)),$(r,w),$(v,w)}}}function Wl(T){let s,o;return s=new L({props:{$$slots:{default:[Gl]},$$scope:{ctx:T}}}),{c(){c(s.$$.fragment)},l(t){f(s.$$.fragment,t)},m(t,r){d(s,t,r),o=!0},p(t,r){const M={};r&2&&(M.$$scope={dirty:r,ctx:t}),s.$set(M)},i(t){o||(u(s.$$.fragment,t),o=!0)},o(t){h(s.$$.fragment,t),o=!1},d(t){$(s,t)}}}function Rl(T){let s,o='Once your model is fine-tuned, you can save it with its tokenizer using <a href="/docs/transformers/main/en/main_classes/model#transformers.TFPreTrainedModel.save_pretrained">TFPreTrainedModel.save_pretrained()</a>:',t,r,M,m,U='When you are ready to use the model again, reload it with <a href="/docs/transformers/main/en/main_classes/model#transformers.TFPreTrainedModel.from_pretrained">TFPreTrainedModel.from_pretrained()</a>:',G,v,R;return r=new _({props:{code:"dGZfc2F2ZV9kaXJlY3RvcnklMjAlM0QlMjAlMjIuJTJGdGZfc2F2ZV9wcmV0cmFpbmVkJTIyJTBBdG9rZW5pemVyLnNhdmVfcHJldHJhaW5lZCh0Zl9zYXZlX2RpcmVjdG9yeSklMEF0Zl9tb2RlbC5zYXZlX3ByZXRyYWluZWQodGZfc2F2ZV9kaXJlY3Rvcnkp",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span>tf_save_directory = <span class="hljs-string">&quot;./tf_save_pretrained&quot;</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer.save_pretrained(tf_save_directory)
<span class="hljs-meta">&gt;&gt;&gt; </span>tf_model.save_pretrained(tf_save_directory)`,wrap:!1}}),v=new _({props:{code:"dGZfbW9kZWwlMjAlM0QlMjBURkF1dG9Nb2RlbEZvclNlcXVlbmNlQ2xhc3NpZmljYXRpb24uZnJvbV9wcmV0cmFpbmVkKCUyMi4lMkZ0Zl9zYXZlX3ByZXRyYWluZWQlMjIp",highlighted:'<span class="hljs-meta">&gt;&gt;&gt; </span>tf_model = TFAutoModelForSequenceClassification.from_pretrained(<span class="hljs-string">&quot;./tf_save_pretrained&quot;</span>)',wrap:!1}}),{c(){s=g("p"),s.innerHTML=o,t=i(),c(r.$$.fragment),M=i(),m=g("p"),m.innerHTML=U,G=i(),c(v.$$.fragment)},l(w){s=y(w,"P",{"data-svelte-h":!0}),b(s)!=="svelte-1hprd39"&&(s.innerHTML=o),t=p(w),f(r.$$.fragment,w),M=p(w),m=y(w,"P",{"data-svelte-h":!0}),b(m)!=="svelte-6vlxmh"&&(m.innerHTML=U),G=p(w),f(v.$$.fragment,w)},m(w,Z){l(w,s,Z),l(w,t,Z),d(r,w,Z),l(w,M,Z),l(w,m,Z),l(w,G,Z),d(v,w,Z),R=!0},p:H,i(w){R||(u(r.$$.fragment,w),u(v.$$.fragment,w),R=!0)},o(w){h(r.$$.fragment,w),h(v.$$.fragment,w),R=!1},d(w){w&&(n(s),n(t),n(M),n(m),n(G)),$(r,w),$(v,w)}}}function Il(T){let s,o;return s=new L({props:{$$slots:{default:[Rl]},$$scope:{ctx:T}}}),{c(){c(s.$$.fragment)},l(t){f(s.$$.fragment,t)},m(t,r){d(s,t,r),o=!0},p(t,r){const M={};r&2&&(M.$$scope={dirty:r,ctx:t}),s.$set(M)},i(t){o||(u(s.$$.fragment,t),o=!0)},o(t){h(s.$$.fragment,t),o=!1},d(t){$(s,t)}}}function Hl(T){let s,o;return s=new _({props:{code:"ZnJvbSUyMHRyYW5zZm9ybWVycyUyMGltcG9ydCUyMEF1dG9Nb2RlbCUwQSUwQXRva2VuaXplciUyMCUzRCUyMEF1dG9Ub2tlbml6ZXIuZnJvbV9wcmV0cmFpbmVkKHB0X3NhdmVfZGlyZWN0b3J5KSUwQXB0X21vZGVsJTIwJTNEJTIwQXV0b01vZGVsRm9yU2VxdWVuY2VDbGFzc2lmaWNhdGlvbi5mcm9tX3ByZXRyYWluZWQocHRfc2F2ZV9kaXJlY3RvcnklMkMlMjBmcm9tX3B0JTNEVHJ1ZSk=",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoModel

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.from_pretrained(pt_save_directory)
<span class="hljs-meta">&gt;&gt;&gt; </span>pt_model = AutoModelForSequenceClassification.from_pretrained(pt_save_directory, from_pt=<span class="hljs-literal">True</span>)`,wrap:!1}}),{c(){c(s.$$.fragment)},l(t){f(s.$$.fragment,t)},m(t,r){d(s,t,r),o=!0},p:H,i(t){o||(u(s.$$.fragment,t),o=!0)},o(t){h(s.$$.fragment,t),o=!1},d(t){$(s,t)}}}function xl(T){let s,o;return s=new L({props:{$$slots:{default:[Hl]},$$scope:{ctx:T}}}),{c(){c(s.$$.fragment)},l(t){f(s.$$.fragment,t)},m(t,r){d(s,t,r),o=!0},p(t,r){const M={};r&2&&(M.$$scope={dirty:r,ctx:t}),s.$set(M)},i(t){o||(u(s.$$.fragment,t),o=!0)},o(t){h(s.$$.fragment,t),o=!1},d(t){$(s,t)}}}function Fl(T){let s,o;return s=new _({props:{code:"ZnJvbSUyMHRyYW5zZm9ybWVycyUyMGltcG9ydCUyMFRGQXV0b01vZGVsJTBBJTBBdG9rZW5pemVyJTIwJTNEJTIwQXV0b1Rva2VuaXplci5mcm9tX3ByZXRyYWluZWQodGZfc2F2ZV9kaXJlY3RvcnkpJTBBdGZfbW9kZWwlMjAlM0QlMjBURkF1dG9Nb2RlbEZvclNlcXVlbmNlQ2xhc3NpZmljYXRpb24uZnJvbV9wcmV0cmFpbmVkKHRmX3NhdmVfZGlyZWN0b3J5JTJDJTIwZnJvbV90ZiUzRFRydWUp",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> TFAutoModel

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.from_pretrained(tf_save_directory)
<span class="hljs-meta">&gt;&gt;&gt; </span>tf_model = TFAutoModelForSequenceClassification.from_pretrained(tf_save_directory, from_tf=<span class="hljs-literal">True</span>)`,wrap:!1}}),{c(){c(s.$$.fragment)},l(t){f(s.$$.fragment,t)},m(t,r){d(s,t,r),o=!0},p:H,i(t){o||(u(s.$$.fragment,t),o=!0)},o(t){h(s.$$.fragment,t),o=!1},d(t){$(s,t)}}}function Vl(T){let s,o;return s=new L({props:{$$slots:{default:[Fl]},$$scope:{ctx:T}}}),{c(){c(s.$$.fragment)},l(t){f(s.$$.fragment,t)},m(t,r){d(s,t,r),o=!0},p(t,r){const M={};r&2&&(M.$$scope={dirty:r,ctx:t}),s.$set(M)},i(t){o||(u(s.$$.fragment,t),o=!0)},o(t){h(s.$$.fragment,t),o=!1},d(t){$(s,t)}}}function zl(T){let s,o='Create a model from your custom configuration with <a href="/docs/transformers/main/en/model_doc/auto#transformers.AutoModel.from_config">AutoModel.from_config()</a>:',t,r,M;return r=new _({props:{code:"ZnJvbSUyMHRyYW5zZm9ybWVycyUyMGltcG9ydCUyMEF1dG9Nb2RlbCUwQSUwQW15X21vZGVsJTIwJTNEJTIwQXV0b01vZGVsLmZyb21fY29uZmlnKG15X2NvbmZpZyk=",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoModel

<span class="hljs-meta">&gt;&gt;&gt; </span>my_model = AutoModel.from_config(my_config)`,wrap:!1}}),{c(){s=g("p"),s.innerHTML=o,t=i(),c(r.$$.fragment)},l(m){s=y(m,"P",{"data-svelte-h":!0}),b(s)!=="svelte-1m7z71f"&&(s.innerHTML=o),t=p(m),f(r.$$.fragment,m)},m(m,U){l(m,s,U),l(m,t,U),d(r,m,U),M=!0},p:H,i(m){M||(u(r.$$.fragment,m),M=!0)},o(m){h(r.$$.fragment,m),M=!1},d(m){m&&(n(s),n(t)),$(r,m)}}}function Xl(T){let s,o;return s=new L({props:{$$slots:{default:[zl]},$$scope:{ctx:T}}}),{c(){c(s.$$.fragment)},l(t){f(s.$$.fragment,t)},m(t,r){d(s,t,r),o=!0},p(t,r){const M={};r&2&&(M.$$scope={dirty:r,ctx:t}),s.$set(M)},i(t){o||(u(s.$$.fragment,t),o=!0)},o(t){h(s.$$.fragment,t),o=!1},d(t){$(s,t)}}}function Nl(T){let s,o='Create a model from your custom configuration with <a href="/docs/transformers/main/en/model_doc/auto#transformers.AutoModel.from_config">TFAutoModel.from_config()</a>:',t,r,M;return r=new _({props:{code:"ZnJvbSUyMHRyYW5zZm9ybWVycyUyMGltcG9ydCUyMFRGQXV0b01vZGVsJTBBJTBBbXlfbW9kZWwlMjAlM0QlMjBURkF1dG9Nb2RlbC5mcm9tX2NvbmZpZyhteV9jb25maWcp",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> TFAutoModel

<span class="hljs-meta">&gt;&gt;&gt; </span>my_model = TFAutoModel.from_config(my_config)`,wrap:!1}}),{c(){s=g("p"),s.innerHTML=o,t=i(),c(r.$$.fragment)},l(m){s=y(m,"P",{"data-svelte-h":!0}),b(s)!=="svelte-rdr3qh"&&(s.innerHTML=o),t=p(m),f(r.$$.fragment,m)},m(m,U){l(m,s,U),l(m,t,U),d(r,m,U),M=!0},p:H,i(m){M||(u(r.$$.fragment,m),M=!0)},o(m){h(r.$$.fragment,m),M=!1},d(m){m&&(n(s),n(t)),$(r,m)}}}function Al(T){let s,o;return s=new L({props:{$$slots:{default:[Nl]},$$scope:{ctx:T}}}),{c(){c(s.$$.fragment)},l(t){f(s.$$.fragment,t)},m(t,r){d(s,t,r),o=!0},p(t,r){const M={};r&2&&(M.$$scope={dirty:r,ctx:t}),s.$set(M)},i(t){o||(u(s.$$.fragment,t),o=!0)},o(t){h(s.$$.fragment,t),o=!1},d(t){$(s,t)}}}function Yl(T){let s,o='For tasks - like translation or summarization - that use a sequence-to-sequence model, use the <a href="/docs/transformers/main/en/main_classes/trainer#transformers.Seq2SeqTrainer">Seq2SeqTrainer</a> and <a href="/docs/transformers/main/en/main_classes/trainer#transformers.Seq2SeqTrainingArguments">Seq2SeqTrainingArguments</a> classes instead.';return{c(){s=g("p"),s.innerHTML=o},l(t){s=y(t,"P",{"data-svelte-h":!0}),b(s)!=="svelte-1q421e1"&&(s.innerHTML=o)},m(t,r){l(t,s,r)},p:H,d(t){t&&n(s)}}}function El(T){let s,o,t,r,M,m,U,G,v,R='Get up and running with 🤗 Transformers! Whether you’re a developer or an everyday user, this quick tour will help you get started and show you how to use the <a href="/docs/transformers/main/en/main_classes/pipelines#transformers.pipeline">pipeline()</a> for inference, load a pretrained model and preprocessor with an <a href="./model_doc/auto">AutoClass</a>, and quickly train a model with PyTorch or TensorFlow. If you’re a beginner, we recommend checking out our tutorials or <a href="https://huggingface.co/course/chapter1/1" rel="nofollow">course</a> next for more in-depth explanations of the concepts introduced here.',w,Z,z="Before you begin, make sure you have all the necessary libraries installed:",X,x,I,N,k="You’ll also need to install your preferred machine learning framework:",C,F,j,W,re,oe,ms,ie,ln='The <a href="/docs/transformers/main/en/main_classes/pipelines#transformers.pipeline">pipeline()</a> is the easiest and fastest way to use a pretrained model for inference. You can use the <a href="/docs/transformers/main/en/main_classes/pipelines#transformers.pipeline">pipeline()</a> out-of-the-box for many tasks across different modalities, some of which are shown in the table below:',cs,P,fs,pe,rn="<thead><tr><th><strong>Task</strong></th> <th><strong>Description</strong></th> <th><strong>Modality</strong></th> <th><strong>Pipeline identifier</strong></th></tr></thead> <tbody><tr><td>Text classification</td> <td>assign a label to a given sequence of text</td> <td>NLP</td> <td>pipeline(task=“sentiment-analysis”)</td></tr> <tr><td>Text generation</td> <td>generate text given a prompt</td> <td>NLP</td> <td>pipeline(task=“text-generation”)</td></tr> <tr><td>Summarization</td> <td>generate a summary of a sequence of text or document</td> <td>NLP</td> <td>pipeline(task=“summarization”)</td></tr> <tr><td>Image classification</td> <td>assign a label to an image</td> <td>Computer vision</td> <td>pipeline(task=“image-classification”)</td></tr> <tr><td>Image segmentation</td> <td>assign a label to each individual pixel of an image (supports semantic, panoptic, and instance segmentation)</td> <td>Computer vision</td> <td>pipeline(task=“image-segmentation”)</td></tr> <tr><td>Object detection</td> <td>predict the bounding boxes and classes of objects in an image</td> <td>Computer vision</td> <td>pipeline(task=“object-detection”)</td></tr> <tr><td>Audio classification</td> <td>assign a label to some audio data</td> <td>Audio</td> <td>pipeline(task=“audio-classification”)</td></tr> <tr><td>Automatic speech recognition</td> <td>transcribe speech into text</td> <td>Audio</td> <td>pipeline(task=“automatic-speech-recognition”)</td></tr> <tr><td>Visual question answering</td> <td>answer a question about the image, given an image and a question</td> <td>Multimodal</td> <td>pipeline(task=“vqa”)</td></tr> <tr><td>Document question answering</td> <td>answer a question about the document, given a document and a question</td> <td>Multimodal</td> <td>pipeline(task=“document-question-answering”)</td></tr> <tr><td>Image captioning</td> <td>generate a caption for a given image</td> <td>Multimodal</td> <td>pipeline(task=“image-to-text”)</td></tr></tbody>",ds,me,on='Start by creating an instance of <a href="/docs/transformers/main/en/main_classes/pipelines#transformers.pipeline">pipeline()</a> and specifying a task you want to use it for. In this guide, you’ll use the <a href="/docs/transformers/main/en/main_classes/pipelines#transformers.pipeline">pipeline()</a> for sentiment analysis as an example:',us,ce,hs,fe,pn='The <a href="/docs/transformers/main/en/main_classes/pipelines#transformers.pipeline">pipeline()</a> downloads and caches a default <a href="https://huggingface.co/distilbert/distilbert-base-uncased-finetuned-sst-2-english" rel="nofollow">pretrained model</a> and tokenizer for sentiment analysis. Now you can use the <code>classifier</code> on your target text:',$s,de,gs,ue,mn='If you have more than one input, pass your inputs as a list to the <a href="/docs/transformers/main/en/main_classes/pipelines#transformers.pipeline">pipeline()</a> to return a list of dictionaries:',ys,he,Ms,$e,cn='The <a href="/docs/transformers/main/en/main_classes/pipelines#transformers.pipeline">pipeline()</a> can also iterate over an entire dataset for any task you like. For this example, let’s choose automatic speech recognition as our task:',bs,ge,ws,ye,fn='Load an audio dataset (see the 🤗 Datasets <a href="https://huggingface.co/docs/datasets/quickstart#audio" rel="nofollow">Quick Start</a> for more details) you’d like to iterate over. For example, load the <a href="https://huggingface.co/datasets/PolyAI/minds14" rel="nofollow">MInDS-14</a> dataset:',Ts,Me,js,be,dn=`You need to make sure the sampling rate of the dataset matches the sampling
rate <a href="https://huggingface.co/facebook/wav2vec2-base-960h" rel="nofollow"><code>facebook/wav2vec2-base-960h</code></a> was trained on:`,ks,we,_s,Te,un=`The audio files are automatically loaded and resampled when calling the <code>&quot;audio&quot;</code> column.
Extract the raw waveform arrays from the first 4 samples and pass it as a list to the pipeline:`,Js,je,Us,ke,hn='For larger datasets where the inputs are big (like in speech or vision), you’ll want to pass a generator instead of a list to load all the inputs in memory. Take a look at the <a href="./main_classes/pipelines">pipeline API reference</a> for more information.',vs,_e,Zs,Je,$n='The <a href="/docs/transformers/main/en/main_classes/pipelines#transformers.pipeline">pipeline()</a> can accommodate any model from the <a href="https://huggingface.co/models" rel="nofollow">Hub</a>, making it easy to adapt the <a href="/docs/transformers/main/en/main_classes/pipelines#transformers.pipeline">pipeline()</a> for other use-cases. For example, if you’d like a model capable of handling French text, use the tags on the Hub to filter for an appropriate model. The top filtered result returns a multilingual <a href="https://huggingface.co/nlptown/bert-base-multilingual-uncased-sentiment" rel="nofollow">BERT model</a> finetuned for sentiment analysis you can use for French text:',Cs,Ue,Gs,O,Ws,ve,gn='Specify the model and tokenizer in the <a href="/docs/transformers/main/en/main_classes/pipelines#transformers.pipeline">pipeline()</a>, and now you can apply the <code>classifier</code> on French text:',Rs,Ze,Is,Ce,yn='If you can’t find a model for your use-case, you’ll need to finetune a pretrained model on your data. Take a look at our <a href="./training">finetuning tutorial</a> to learn how. Finally, after you’ve finetuned your pretrained model, please consider <a href="./model_sharing">sharing</a> the model with the community on the Hub to democratize machine learning for everyone! 🤗',Hs,Ge,xs,We,Fs,Re,Mn='Under the hood, the <a href="/docs/transformers/main/en/model_doc/auto#transformers.AutoModelForSequenceClassification">AutoModelForSequenceClassification</a> and <a href="/docs/transformers/main/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a> classes work together to power the <a href="/docs/transformers/main/en/main_classes/pipelines#transformers.pipeline">pipeline()</a> you used above. An <a href="./model_doc/auto">AutoClass</a> is a shortcut that automatically retrieves the architecture of a pretrained model from its name or path. You only need to select the appropriate <code>AutoClass</code> for your task and it’s associated preprocessing class.',Vs,Ie,bn='Let’s return to the example from the previous section and see how you can use the <code>AutoClass</code> to replicate the results of the <a href="/docs/transformers/main/en/main_classes/pipelines#transformers.pipeline">pipeline()</a>.',zs,He,Xs,xe,wn='A tokenizer is responsible for preprocessing text into an array of numbers as inputs to a model. There are multiple rules that govern the tokenization process, including how to split a word and at what level words should be split (learn more about tokenization in the <a href="./tokenizer_summary">tokenizer summary</a>). The most important thing to remember is you need to instantiate a tokenizer with the same model name to ensure you’re using the same tokenization rules a model was pretrained with.',Ns,Fe,Tn='Load a tokenizer with <a href="/docs/transformers/main/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>:',As,Ve,Ys,ze,jn="Pass your text to the tokenizer:",Es,Xe,Ls,Ne,kn="The tokenizer returns a dictionary containing:",Bs,Ae,_n='<li><a href="./glossary#input-ids">input_ids</a>: numerical representations of your tokens.</li> <li><a href="./glossary#attention-mask">attention_mask</a>: indicates which tokens should be attended to.</li>',qs,Ye,Jn="A tokenizer can also accept a list of inputs, and pad and truncate the text to return a batch with uniform length:",Ss,D,Qs,K,Ps,Ee,Os,ee,Ds,te,Ks,Le,ea,se,ta,Be,Un="One particularly cool 🤗 Transformers feature is the ability to save a model and reload it as either a PyTorch or TensorFlow model. The <code>from_pt</code> or <code>from_tf</code> parameter can convert the model from one framework to the other:",sa,ae,aa,qe,na,Se,vn="You can modify the model’s configuration class to change how a model is built. The configuration specifies a model’s attributes, such as the number of hidden layers or attention heads. You start from scratch when you initialize a model from a custom configuration class. The model attributes are randomly initialized, and you’ll need to train the model before you can use it to get meaningful results.",la,Qe,Zn='Start by importing <a href="/docs/transformers/main/en/model_doc/auto#transformers.AutoConfig">AutoConfig</a>, and then load the pretrained model you want to modify. Within <a href="/docs/transformers/main/en/model_doc/auto#transformers.AutoConfig.from_pretrained">AutoConfig.from_pretrained()</a>, you can specify the attribute you want to change, such as the number of attention heads:',ra,Pe,oa,ne,ia,Oe,Cn='Take a look at the <a href="./create_a_model">Create a custom architecture</a> guide for more information about building custom configurations.',pa,De,ma,Ke,Gn='All models are a standard <a href="https://pytorch.org/docs/stable/nn.html#torch.nn.Module" rel="nofollow"><code>torch.nn.Module</code></a> so you can use them in any typical training loop. While you can write your own training loop, 🤗 Transformers provides a <a href="/docs/transformers/main/en/main_classes/trainer#transformers.Trainer">Trainer</a> class for PyTorch, which contains the basic training loop and adds additional functionality for features like distributed training, mixed precision, and more.',ca,et,Wn='Depending on your task, you’ll typically pass the following parameters to <a href="/docs/transformers/main/en/main_classes/trainer#transformers.Trainer">Trainer</a>:',fa,V,tt,Pt,Rn='You’ll start with a <a href="/docs/transformers/main/en/main_classes/model#transformers.PreTrainedModel">PreTrainedModel</a> or a <a href="https://pytorch.org/docs/stable/nn.html#torch.nn.Module" rel="nofollow"><code>torch.nn.Module</code></a>. Set <code>torch_dtype=&quot;auto&quot;</code> to automatically load the most memory-efficient data type the weights are stored in.',Fa,st,Va,at,Ot,In='<a href="/docs/transformers/main/en/main_classes/trainer#transformers.TrainingArguments">TrainingArguments</a> contains the model hyperparameters you can change like learning rate, batch size, and the number of epochs to train for. The default values are used if you don’t specify any training arguments:',za,nt,Xa,lt,Dt,Hn="Load a preprocessing class like a tokenizer, image processor, feature extractor, or processor:",Na,rt,Aa,ot,Kt,xn="Load a dataset:",Ya,it,Ea,S,es,Fn="Create a function to tokenize the dataset:",La,pt,Ba,ts,Vn='Then apply it over the entire dataset with <a href="https://huggingface.co/docs/datasets/main/en/package_reference/main_classes#datasets.Dataset.map" rel="nofollow">map</a>:',qa,mt,Sa,ct,ss,zn='A <a href="/docs/transformers/main/en/main_classes/data_collator#transformers.DataCollatorWithPadding">DataCollatorWithPadding</a> to create a batch of examples from your dataset:',Qa,ft,da,dt,Xn='Now gather all these classes in <a href="/docs/transformers/main/en/main_classes/trainer#transformers.Trainer">Trainer</a>:',ua,ut,ha,ht,Nn='When you’re ready, call <a href="/docs/transformers/main/en/main_classes/trainer#transformers.Trainer.train">train()</a> to start training:',$a,$t,ga,le,ya,gt,An='You can customize the training loop behavior by subclassing the methods inside <a href="/docs/transformers/main/en/main_classes/trainer#transformers.Trainer">Trainer</a>. This allows you to customize features such as the loss function, optimizer, and scheduler. Take a look at the <a href="/docs/transformers/main/en/main_classes/trainer#transformers.Trainer">Trainer</a> reference for which methods can be subclassed.',Ma,yt,Yn='The other way to customize the training loop is by using <a href="./main_classes/callback">Callbacks</a>. You can use callbacks to integrate with other libraries and inspect the training loop to report on progress or stop the training early. Callbacks do not modify anything in the training loop itself. To customize something like the loss function, you need to subclass the <a href="/docs/transformers/main/en/main_classes/trainer#transformers.Trainer">Trainer</a> instead.',ba,Mt,wa,bt,En='All models are a standard <a href="https://www.tensorflow.org/api_docs/python/tf/keras/Model" rel="nofollow"><code>tf.keras.Model</code></a> so they can be trained in TensorFlow with the <a href="https://keras.io/" rel="nofollow">Keras</a> API. 🤗 Transformers provides the <a href="/docs/transformers/main/en/main_classes/model#transformers.TFPreTrainedModel.prepare_tf_dataset">prepare_tf_dataset()</a> method to easily load your dataset as a <code>tf.data.Dataset</code> so you can start training right away with Keras’ <a href="https://keras.io/api/models/model_training_apis/#compile-method" rel="nofollow"><code>compile</code></a> and <a href="https://keras.io/api/models/model_training_apis/#fit-method" rel="nofollow"><code>fit</code></a> methods.',Ta,E,wt,as,Ln='You’ll start with a <a href="/docs/transformers/main/en/main_classes/model#transformers.TFPreTrainedModel">TFPreTrainedModel</a> or a <a href="https://www.tensorflow.org/api_docs/python/tf/keras/Model" rel="nofollow"><code>tf.keras.Model</code></a>:',Pa,Tt,Oa,jt,ns,Bn="Load a preprocessing class like a tokenizer, image processor, feature extractor, or processor:",Da,kt,Ka,_t,ls,qn="Create a function to tokenize the dataset:",en,Jt,tn,Ut,rs,Sn='Apply the tokenizer over the entire dataset with <a href="https://huggingface.co/docs/datasets/main/en/package_reference/main_classes#datasets.Dataset.map" rel="nofollow">map</a> and then pass the dataset and tokenizer to <a href="/docs/transformers/main/en/main_classes/model#transformers.TFPreTrainedModel.prepare_tf_dataset">prepare_tf_dataset()</a>. You can also change the batch size and shuffle the dataset here if you’d like:',sn,vt,an,Zt,os,Qn="When you’re ready, you can call <code>compile</code> and <code>fit</code> to start training. Note that Transformers models all have a default task-relevant loss function, so you don’t need to specify one unless you want to:",nn,Ct,ja,Gt,ka,Wt,Pn=`If you’re working with a model that generates text as an output, you can also engage in a multi-turn conversation with
it through the <code>transformers-cli chat</code> command. This is the fastest way to interact with a model, e.g. for a
qualitative assessment (aka vibe check).`,_a,Rt,On=`This CLI is implemented on top of our <code>AutoClass</code> abstraction, leveraging our <a href="llm_tutorial.md">text generation</a> and
<a href="chat_templating.md">chat</a> tooling, and thus will be compatible with any 🤗 Transformers model. If you have the library
<a href="installation.md">installed</a>, you can launch the chat session on your terminal with`,Ja,It,Ua,Ht,Dn="For a full list of options to launch the chat, type",va,xt,Za,Ft,Kn=`After the chat is launched, you will enter an interactive session with the model. There are special commands for this
session as well, such as <code>clear</code> to reset the conversation. Type <code>help</code> at any moment to display all special chat
commands, and <code>exit</code> to terminate the session.`,Ca,Vt,Ga,zt,el="Now that you’ve completed the 🤗 Transformers quick tour, check out our guides and learn how to do more specific things like writing a custom model, fine-tuning a model for a task, and how to train a model with a script. If you’re interested in learning more about 🤗 Transformers core concepts, grab a cup of coffee and take a look at our Conceptual Guides!",Wa,Xt,Ra,ps,Ia;return M=new q({props:{title:"Quick tour",local:"quick-tour",headingTag:"h1"}}),U=new il({props:{classNames:"absolute z-10 right-0 top-0",options:[{label:"Mixed",value:"https://colab.research.google.com/github/huggingface/notebooks/blob/main/transformers_doc/en/quicktour.ipynb"},{label:"PyTorch",value:"https://colab.research.google.com/github/huggingface/notebooks/blob/main/transformers_doc/en/pytorch/quicktour.ipynb"},{label:"TensorFlow",value:"https://colab.research.google.com/github/huggingface/notebooks/blob/main/transformers_doc/en/tensorflow/quicktour.ipynb"},{label:"Mixed",value:"https://studiolab.sagemaker.aws/import/github/huggingface/notebooks/blob/main/transformers_doc/en/quicktour.ipynb"},{label:"PyTorch",value:"https://studiolab.sagemaker.aws/import/github/huggingface/notebooks/blob/main/transformers_doc/en/pytorch/quicktour.ipynb"},{label:"TensorFlow",value:"https://studiolab.sagemaker.aws/import/github/huggingface/notebooks/blob/main/transformers_doc/en/tensorflow/quicktour.ipynb"}]}}),x=new _({props:{code:"IXBpcCUyMGluc3RhbGwlMjB0cmFuc2Zvcm1lcnMlMjBkYXRhc2V0cyUyMGV2YWx1YXRlJTIwYWNjZWxlcmF0ZQ==",highlighted:"!pip install transformers datasets evaluate accelerate",wrap:!1}}),F=new Qt({props:{pytorch:!0,tensorflow:!0,jax:!1,$$slots:{tensorflow:[dl],pytorch:[cl]},$$scope:{ctx:T}}}),W=new q({props:{title:"Pipeline",local:"pipeline",headingTag:"h2"}}),oe=new sl({props:{id:"tiZFewofSLM"}}),P=new is({props:{$$slots:{default:[ul]},$$scope:{ctx:T}}}),ce=new _({props:{code:"ZnJvbSUyMHRyYW5zZm9ybWVycyUyMGltcG9ydCUyMHBpcGVsaW5lJTBBJTBBY2xhc3NpZmllciUyMCUzRCUyMHBpcGVsaW5lKCUyMnNlbnRpbWVudC1hbmFseXNpcyUyMik=",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> pipeline

<span class="hljs-meta">&gt;&gt;&gt; </span>classifier = pipeline(<span class="hljs-string">&quot;sentiment-analysis&quot;</span>)`,wrap:!1}}),de=new _({props:{code:"Y2xhc3NpZmllciglMjJXZSUyMGFyZSUyMHZlcnklMjBoYXBweSUyMHRvJTIwc2hvdyUyMHlvdSUyMHRoZSUyMCVGMCU5RiVBNCU5NyUyMFRyYW5zZm9ybWVycyUyMGxpYnJhcnkuJTIyKQ==",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span>classifier(<span class="hljs-string">&quot;We are very happy to show you the 🤗 Transformers library.&quot;</span>)
[{<span class="hljs-string">&#x27;label&#x27;</span>: <span class="hljs-string">&#x27;POSITIVE&#x27;</span>, <span class="hljs-string">&#x27;score&#x27;</span>: <span class="hljs-number">0.9998</span>}]`,wrap:!1}}),he=new _({props:{code:"cmVzdWx0cyUyMCUzRCUyMGNsYXNzaWZpZXIoJTVCJTIyV2UlMjBhcmUlMjB2ZXJ5JTIwaGFwcHklMjB0byUyMHNob3clMjB5b3UlMjB0aGUlMjAlRjAlOUYlQTQlOTclMjBUcmFuc2Zvcm1lcnMlMjBsaWJyYXJ5LiUyMiUyQyUyMCUyMldlJTIwaG9wZSUyMHlvdSUyMGRvbid0JTIwaGF0ZSUyMGl0LiUyMiU1RCklMEFmb3IlMjByZXN1bHQlMjBpbiUyMHJlc3VsdHMlM0ElMEElMjAlMjAlMjAlMjBwcmludChmJTIybGFiZWwlM0ElMjAlN0JyZXN1bHQlNUInbGFiZWwnJTVEJTdEJTJDJTIwd2l0aCUyMHNjb3JlJTNBJTIwJTdCcm91bmQocmVzdWx0JTVCJ3Njb3JlJyU1RCUyQyUyMDQpJTdEJTIyKQ==",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span>results = classifier([<span class="hljs-string">&quot;We are very happy to show you the 🤗 Transformers library.&quot;</span>, <span class="hljs-string">&quot;We hope you don&#x27;t hate it.&quot;</span>])
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">for</span> result <span class="hljs-keyword">in</span> results:
<span class="hljs-meta">... </span>    <span class="hljs-built_in">print</span>(<span class="hljs-string">f&quot;label: <span class="hljs-subst">{result[<span class="hljs-string">&#x27;label&#x27;</span>]}</span>, with score: <span class="hljs-subst">{<span class="hljs-built_in">round</span>(result[<span class="hljs-string">&#x27;score&#x27;</span>], <span class="hljs-number">4</span>)}</span>&quot;</span>)
label: POSITIVE, <span class="hljs-keyword">with</span> score: <span class="hljs-number">0.9998</span>
label: NEGATIVE, <span class="hljs-keyword">with</span> score: <span class="hljs-number">0.5309</span>`,wrap:!1}}),ge=new _({props:{code:"aW1wb3J0JTIwdG9yY2glMEFmcm9tJTIwdHJhbnNmb3JtZXJzJTIwaW1wb3J0JTIwcGlwZWxpbmUlMEElMEFzcGVlY2hfcmVjb2duaXplciUyMCUzRCUyMHBpcGVsaW5lKCUyMmF1dG9tYXRpYy1zcGVlY2gtcmVjb2duaXRpb24lMjIlMkMlMjBtb2RlbCUzRCUyMmZhY2Vib29rJTJGd2F2MnZlYzItYmFzZS05NjBoJTIyKQ==",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">import</span> torch
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> pipeline

<span class="hljs-meta">&gt;&gt;&gt; </span>speech_recognizer = pipeline(<span class="hljs-string">&quot;automatic-speech-recognition&quot;</span>, model=<span class="hljs-string">&quot;facebook/wav2vec2-base-960h&quot;</span>)`,wrap:!1}}),Me=new _({props:{code:"ZnJvbSUyMGRhdGFzZXRzJTIwaW1wb3J0JTIwbG9hZF9kYXRhc2V0JTJDJTIwQXVkaW8lMEElMEFkYXRhc2V0JTIwJTNEJTIwbG9hZF9kYXRhc2V0KCUyMlBvbHlBSSUyRm1pbmRzMTQlMjIlMkMlMjBuYW1lJTNEJTIyZW4tVVMlMjIlMkMlMjBzcGxpdCUzRCUyMnRyYWluJTIyKQ==",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> datasets <span class="hljs-keyword">import</span> load_dataset, Audio

<span class="hljs-meta">&gt;&gt;&gt; </span>dataset = load_dataset(<span class="hljs-string">&quot;PolyAI/minds14&quot;</span>, name=<span class="hljs-string">&quot;en-US&quot;</span>, split=<span class="hljs-string">&quot;train&quot;</span>)`,wrap:!1}}),we=new _({props:{code:"ZGF0YXNldCUyMCUzRCUyMGRhdGFzZXQuY2FzdF9jb2x1bW4oJTIyYXVkaW8lMjIlMkMlMjBBdWRpbyhzYW1wbGluZ19yYXRlJTNEc3BlZWNoX3JlY29nbml6ZXIuZmVhdHVyZV9leHRyYWN0b3Iuc2FtcGxpbmdfcmF0ZSkp",highlighted:'<span class="hljs-meta">&gt;&gt;&gt; </span>dataset = dataset.cast_column(<span class="hljs-string">&quot;audio&quot;</span>, Audio(sampling_rate=speech_recognizer.feature_extractor.sampling_rate))',wrap:!1}}),je=new _({props:{code:"cmVzdWx0JTIwJTNEJTIwc3BlZWNoX3JlY29nbml6ZXIoZGF0YXNldCU1QiUzQTQlNUQlNUIlMjJhdWRpbyUyMiU1RCklMEFwcmludCglNUJkJTVCJTIydGV4dCUyMiU1RCUyMGZvciUyMGQlMjBpbiUyMHJlc3VsdCU1RCk=",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span>result = speech_recognizer(dataset[:<span class="hljs-number">4</span>][<span class="hljs-string">&quot;audio&quot;</span>])
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-built_in">print</span>([d[<span class="hljs-string">&quot;text&quot;</span>] <span class="hljs-keyword">for</span> d <span class="hljs-keyword">in</span> result])
[<span class="hljs-string">&#x27;I WOULD LIKE TO SET UP A JOINT ACCOUNT WITH MY PARTNER HOW DO I PROCEED WITH DOING THAT&#x27;</span>, <span class="hljs-string">&quot;FONDERING HOW I&#x27;D SET UP A JOIN TO HELL T WITH MY WIFE AND WHERE THE AP MIGHT BE&quot;</span>, <span class="hljs-string">&quot;I I&#x27;D LIKE TOY SET UP A JOINT ACCOUNT WITH MY PARTNER I&#x27;M NOT SEEING THE OPTION TO DO IT ON THE APSO I CALLED IN TO GET SOME HELP CAN I JUST DO IT OVER THE PHONE WITH YOU AND GIVE YOU THE INFORMATION OR SHOULD I DO IT IN THE AP AN I&#x27;M MISSING SOMETHING UQUETTE HAD PREFERRED TO JUST DO IT OVER THE PHONE OF POSSIBLE THINGS&quot;</span>, <span class="hljs-string">&#x27;HOW DO I FURN A JOINA COUT&#x27;</span>]`,wrap:!1}}),_e=new q({props:{title:"Use another model and tokenizer in the pipeline",local:"use-another-model-and-tokenizer-in-the-pipeline",headingTag:"h3"}}),Ue=new _({props:{code:"bW9kZWxfbmFtZSUyMCUzRCUyMCUyMm5scHRvd24lMkZiZXJ0LWJhc2UtbXVsdGlsaW5ndWFsLXVuY2FzZWQtc2VudGltZW50JTIy",highlighted:'<span class="hljs-meta">&gt;&gt;&gt; </span>model_name = <span class="hljs-string">&quot;nlptown/bert-base-multilingual-uncased-sentiment&quot;</span>',wrap:!1}}),O=new Qt({props:{pytorch:!0,tensorflow:!0,jax:!1,$$slots:{tensorflow:[yl],pytorch:[$l]},$$scope:{ctx:T}}}),Ze=new _({props:{code:"Y2xhc3NpZmllciUyMCUzRCUyMHBpcGVsaW5lKCUyMnNlbnRpbWVudC1hbmFseXNpcyUyMiUyQyUyMG1vZGVsJTNEbW9kZWwlMkMlMjB0b2tlbml6ZXIlM0R0b2tlbml6ZXIpJTBBY2xhc3NpZmllciglMjJOb3VzJTIwc29tbWVzJTIwdHIlQzMlQThzJTIwaGV1cmV1eCUyMGRlJTIwdm91cyUyMHByJUMzJUE5c2VudGVyJTIwbGElMjBiaWJsaW90aCVDMyVBOHF1ZSUyMCVGMCU5RiVBNCU5NyUyMFRyYW5zZm9ybWVycy4lMjIp",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span>classifier = pipeline(<span class="hljs-string">&quot;sentiment-analysis&quot;</span>, model=model, tokenizer=tokenizer)
<span class="hljs-meta">&gt;&gt;&gt; </span>classifier(<span class="hljs-string">&quot;Nous sommes très heureux de vous présenter la bibliothèque 🤗 Transformers.&quot;</span>)
[{<span class="hljs-string">&#x27;label&#x27;</span>: <span class="hljs-string">&#x27;5 stars&#x27;</span>, <span class="hljs-string">&#x27;score&#x27;</span>: <span class="hljs-number">0.7273</span>}]`,wrap:!1}}),Ge=new q({props:{title:"AutoClass",local:"autoclass",headingTag:"h2"}}),We=new sl({props:{id:"AhChOFRegn4"}}),He=new q({props:{title:"AutoTokenizer",local:"autotokenizer",headingTag:"h3"}}),Ve=new _({props:{code:"ZnJvbSUyMHRyYW5zZm9ybWVycyUyMGltcG9ydCUyMEF1dG9Ub2tlbml6ZXIlMEElMEFtb2RlbF9uYW1lJTIwJTNEJTIwJTIybmxwdG93biUyRmJlcnQtYmFzZS1tdWx0aWxpbmd1YWwtdW5jYXNlZC1zZW50aW1lbnQlMjIlMEF0b2tlbml6ZXIlMjAlM0QlMjBBdXRvVG9rZW5pemVyLmZyb21fcHJldHJhaW5lZChtb2RlbF9uYW1lKQ==",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer

<span class="hljs-meta">&gt;&gt;&gt; </span>model_name = <span class="hljs-string">&quot;nlptown/bert-base-multilingual-uncased-sentiment&quot;</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.from_pretrained(model_name)`,wrap:!1}}),Xe=new _({props:{code:"ZW5jb2RpbmclMjAlM0QlMjB0b2tlbml6ZXIoJTIyV2UlMjBhcmUlMjB2ZXJ5JTIwaGFwcHklMjB0byUyMHNob3clMjB5b3UlMjB0aGUlMjAlRjAlOUYlQTQlOTclMjBUcmFuc2Zvcm1lcnMlMjBsaWJyYXJ5LiUyMiklMEFwcmludChlbmNvZGluZyk=",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span>encoding = tokenizer(<span class="hljs-string">&quot;We are very happy to show you the 🤗 Transformers library.&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-built_in">print</span>(encoding)
{<span class="hljs-string">&#x27;input_ids&#x27;</span>: [<span class="hljs-number">101</span>, <span class="hljs-number">11312</span>, <span class="hljs-number">10320</span>, <span class="hljs-number">12495</span>, <span class="hljs-number">19308</span>, <span class="hljs-number">10114</span>, <span class="hljs-number">11391</span>, <span class="hljs-number">10855</span>, <span class="hljs-number">10103</span>, <span class="hljs-number">100</span>, <span class="hljs-number">58263</span>, <span class="hljs-number">13299</span>, <span class="hljs-number">119</span>, <span class="hljs-number">102</span>],
 <span class="hljs-string">&#x27;token_type_ids&#x27;</span>: [<span class="hljs-number">0</span>, <span class="hljs-number">0</span>, <span class="hljs-number">0</span>, <span class="hljs-number">0</span>, <span class="hljs-number">0</span>, <span class="hljs-number">0</span>, <span class="hljs-number">0</span>, <span class="hljs-number">0</span>, <span class="hljs-number">0</span>, <span class="hljs-number">0</span>, <span class="hljs-number">0</span>, <span class="hljs-number">0</span>, <span class="hljs-number">0</span>, <span class="hljs-number">0</span>],
 <span class="hljs-string">&#x27;attention_mask&#x27;</span>: [<span class="hljs-number">1</span>, <span class="hljs-number">1</span>, <span class="hljs-number">1</span>, <span class="hljs-number">1</span>, <span class="hljs-number">1</span>, <span class="hljs-number">1</span>, <span class="hljs-number">1</span>, <span class="hljs-number">1</span>, <span class="hljs-number">1</span>, <span class="hljs-number">1</span>, <span class="hljs-number">1</span>, <span class="hljs-number">1</span>, <span class="hljs-number">1</span>, <span class="hljs-number">1</span>]}`,wrap:!1}}),D=new Qt({props:{pytorch:!0,tensorflow:!0,jax:!1,$$slots:{tensorflow:[Tl],pytorch:[bl]},$$scope:{ctx:T}}}),K=new is({props:{$$slots:{default:[jl]},$$scope:{ctx:T}}}),Ee=new q({props:{title:"AutoModel",local:"automodel",headingTag:"h3"}}),ee=new Qt({props:{pytorch:!0,tensorflow:!0,jax:!1,$$slots:{tensorflow:[Zl],pytorch:[Jl]},$$scope:{ctx:T}}}),te=new is({props:{$$slots:{default:[Cl]},$$scope:{ctx:T}}}),Le=new q({props:{title:"Save a model",local:"save-a-model",headingTag:"h3"}}),se=new Qt({props:{pytorch:!0,tensorflow:!0,jax:!1,$$slots:{tensorflow:[Il],pytorch:[Wl]},$$scope:{ctx:T}}}),ae=new Qt({props:{pytorch:!0,tensorflow:!0,jax:!1,$$slots:{tensorflow:[Vl],pytorch:[xl]},$$scope:{ctx:T}}}),qe=new q({props:{title:"Custom model builds",local:"custom-model-builds",headingTag:"h2"}}),Pe=new _({props:{code:"ZnJvbSUyMHRyYW5zZm9ybWVycyUyMGltcG9ydCUyMEF1dG9Db25maWclMEElMEFteV9jb25maWclMjAlM0QlMjBBdXRvQ29uZmlnLmZyb21fcHJldHJhaW5lZCglMjJkaXN0aWxiZXJ0JTJGZGlzdGlsYmVydC1iYXNlLXVuY2FzZWQlMjIlMkMlMjBuX2hlYWRzJTNEMTIp",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoConfig

<span class="hljs-meta">&gt;&gt;&gt; </span>my_config = AutoConfig.from_pretrained(<span class="hljs-string">&quot;distilbert/distilbert-base-uncased&quot;</span>, n_heads=<span class="hljs-number">12</span>)`,wrap:!1}}),ne=new Qt({props:{pytorch:!0,tensorflow:!0,jax:!1,$$slots:{tensorflow:[Al],pytorch:[Xl]},$$scope:{ctx:T}}}),De=new q({props:{title:"Trainer - a PyTorch optimized training loop",local:"trainer---a-pytorch-optimized-training-loop",headingTag:"h2"}}),st=new _({props:{code:"ZnJvbSUyMHRyYW5zZm9ybWVycyUyMGltcG9ydCUyMEF1dG9Nb2RlbEZvclNlcXVlbmNlQ2xhc3NpZmljYXRpb24lMEElMEFtb2RlbCUyMCUzRCUyMEF1dG9Nb2RlbEZvclNlcXVlbmNlQ2xhc3NpZmljYXRpb24uZnJvbV9wcmV0cmFpbmVkKCUyMmRpc3RpbGJlcnQlMkZkaXN0aWxiZXJ0LWJhc2UtdW5jYXNlZCUyMiUyQyUyMHRvcmNoX2R0eXBlJTNEJTIyYXV0byUyMik=",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoModelForSequenceClassification

<span class="hljs-meta">&gt;&gt;&gt; </span>model = AutoModelForSequenceClassification.from_pretrained(<span class="hljs-string">&quot;distilbert/distilbert-base-uncased&quot;</span>, torch_dtype=<span class="hljs-string">&quot;auto&quot;</span>)`,wrap:!1}}),nt=new _({props:{code:"ZnJvbSUyMHRyYW5zZm9ybWVycyUyMGltcG9ydCUyMFRyYWluaW5nQXJndW1lbnRzJTBBJTBBdHJhaW5pbmdfYXJncyUyMCUzRCUyMFRyYWluaW5nQXJndW1lbnRzKCUwQSUyMCUyMCUyMCUyMG91dHB1dF9kaXIlM0QlMjJwYXRoJTJGdG8lMkZzYXZlJTJGZm9sZGVyJTJGJTIyJTJDJTBBJTIwJTIwJTIwJTIwbGVhcm5pbmdfcmF0ZSUzRDJlLTUlMkMlMEElMjAlMjAlMjAlMjBwZXJfZGV2aWNlX3RyYWluX2JhdGNoX3NpemUlM0Q4JTJDJTBBJTIwJTIwJTIwJTIwcGVyX2RldmljZV9ldmFsX2JhdGNoX3NpemUlM0Q4JTJDJTBBJTIwJTIwJTIwJTIwbnVtX3RyYWluX2Vwb2NocyUzRDIlMkMlMEEp",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> TrainingArguments

<span class="hljs-meta">&gt;&gt;&gt; </span>training_args = TrainingArguments(
<span class="hljs-meta">... </span>    output_dir=<span class="hljs-string">&quot;path/to/save/folder/&quot;</span>,
<span class="hljs-meta">... </span>    learning_rate=<span class="hljs-number">2e-5</span>,
<span class="hljs-meta">... </span>    per_device_train_batch_size=<span class="hljs-number">8</span>,
<span class="hljs-meta">... </span>    per_device_eval_batch_size=<span class="hljs-number">8</span>,
<span class="hljs-meta">... </span>    num_train_epochs=<span class="hljs-number">2</span>,
<span class="hljs-meta">... </span>)`,wrap:!1}}),rt=new _({props:{code:"ZnJvbSUyMHRyYW5zZm9ybWVycyUyMGltcG9ydCUyMEF1dG9Ub2tlbml6ZXIlMEElMEF0b2tlbml6ZXIlMjAlM0QlMjBBdXRvVG9rZW5pemVyLmZyb21fcHJldHJhaW5lZCglMjJkaXN0aWxiZXJ0JTJGZGlzdGlsYmVydC1iYXNlLXVuY2FzZWQlMjIp",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.from_pretrained(<span class="hljs-string">&quot;distilbert/distilbert-base-uncased&quot;</span>)`,wrap:!1}}),it=new _({props:{code:"ZnJvbSUyMGRhdGFzZXRzJTIwaW1wb3J0JTIwbG9hZF9kYXRhc2V0JTBBJTBBZGF0YXNldCUyMCUzRCUyMGxvYWRfZGF0YXNldCglMjJyb3R0ZW5fdG9tYXRvZXMlMjIpJTIwJTIwJTIzJTIwZG9jdGVzdCUzQSUyMCUyQklHTk9SRV9SRVNVTFQ=",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;rotten_tomatoes&quot;</span>)  <span class="hljs-comment"># doctest: +IGNORE_RESULT</span>`,wrap:!1}}),pt=new _({props:{code:"ZGVmJTIwdG9rZW5pemVfZGF0YXNldChkYXRhc2V0KSUzQSUwQSUyMCUyMCUyMCUyMHJldHVybiUyMHRva2VuaXplcihkYXRhc2V0JTVCJTIydGV4dCUyMiU1RCk=",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">def</span> <span class="hljs-title function_">tokenize_dataset</span>(<span class="hljs-params">dataset</span>):
<span class="hljs-meta">... </span>    <span class="hljs-keyword">return</span> tokenizer(dataset[<span class="hljs-string">&quot;text&quot;</span>])`,wrap:!1}}),mt=new _({props:{code:"ZGF0YXNldCUyMCUzRCUyMGRhdGFzZXQubWFwKHRva2VuaXplX2RhdGFzZXQlMkMlMjBiYXRjaGVkJTNEVHJ1ZSk=",highlighted:'<span class="hljs-meta">&gt;&gt;&gt; </span>dataset = dataset.<span class="hljs-built_in">map</span>(tokenize_dataset, batched=<span class="hljs-literal">True</span>)',wrap:!1}}),ft=new _({props:{code:"ZnJvbSUyMHRyYW5zZm9ybWVycyUyMGltcG9ydCUyMERhdGFDb2xsYXRvcldpdGhQYWRkaW5nJTBBJTBBZGF0YV9jb2xsYXRvciUyMCUzRCUyMERhdGFDb2xsYXRvcldpdGhQYWRkaW5nKHRva2VuaXplciUzRHRva2VuaXplcik=",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> DataCollatorWithPadding

<span class="hljs-meta">&gt;&gt;&gt; </span>data_collator = DataCollatorWithPadding(tokenizer=tokenizer)`,wrap:!1}}),ut=new _({props:{code:"ZnJvbSUyMHRyYW5zZm9ybWVycyUyMGltcG9ydCUyMFRyYWluZXIlMEElMEF0cmFpbmVyJTIwJTNEJTIwVHJhaW5lciglMEElMjAlMjAlMjAlMjBtb2RlbCUzRG1vZGVsJTJDJTBBJTIwJTIwJTIwJTIwYXJncyUzRHRyYWluaW5nX2FyZ3MlMkMlMEElMjAlMjAlMjAlMjB0cmFpbl9kYXRhc2V0JTNEZGF0YXNldCU1QiUyMnRyYWluJTIyJTVEJTJDJTBBJTIwJTIwJTIwJTIwZXZhbF9kYXRhc2V0JTNEZGF0YXNldCU1QiUyMnRlc3QlMjIlNUQlMkMlMEElMjAlMjAlMjAlMjBwcm9jZXNzaW5nX2NsYXNzJTNEdG9rZW5pemVyJTJDJTBBJTIwJTIwJTIwJTIwZGF0YV9jb2xsYXRvciUzRGRhdGFfY29sbGF0b3IlMkMlMEEpJTIwJTIwJTIzJTIwZG9jdGVzdCUzQSUyMCUyQlNLSVA=",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> Trainer

<span class="hljs-meta">&gt;&gt;&gt; </span>trainer = Trainer(
<span class="hljs-meta">... </span>    model=model,
<span class="hljs-meta">... </span>    args=training_args,
<span class="hljs-meta">... </span>    train_dataset=dataset[<span class="hljs-string">&quot;train&quot;</span>],
<span class="hljs-meta">... </span>    eval_dataset=dataset[<span class="hljs-string">&quot;test&quot;</span>],
<span class="hljs-meta">... </span>    processing_class=tokenizer,
<span class="hljs-meta">... </span>    data_collator=data_collator,
<span class="hljs-meta">... </span>)  <span class="hljs-comment"># doctest: +SKIP</span>`,wrap:!1}}),$t=new _({props:{code:"dHJhaW5lci50cmFpbigp",highlighted:'<span class="hljs-meta">&gt;&gt;&gt; </span>trainer.train()',wrap:!1}}),le=new is({props:{$$slots:{default:[Yl]},$$scope:{ctx:T}}}),Mt=new q({props:{title:"Train with TensorFlow",local:"train-with-tensorflow",headingTag:"h2"}}),Tt=new _({props:{code:"ZnJvbSUyMHRyYW5zZm9ybWVycyUyMGltcG9ydCUyMFRGQXV0b01vZGVsRm9yU2VxdWVuY2VDbGFzc2lmaWNhdGlvbiUwQSUwQW1vZGVsJTIwJTNEJTIwVEZBdXRvTW9kZWxGb3JTZXF1ZW5jZUNsYXNzaWZpY2F0aW9uLmZyb21fcHJldHJhaW5lZCglMjJkaXN0aWxiZXJ0JTJGZGlzdGlsYmVydC1iYXNlLXVuY2FzZWQlMjIp",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> TFAutoModelForSequenceClassification

<span class="hljs-meta">&gt;&gt;&gt; </span>model = TFAutoModelForSequenceClassification.from_pretrained(<span class="hljs-string">&quot;distilbert/distilbert-base-uncased&quot;</span>)`,wrap:!1}}),kt=new _({props:{code:"ZnJvbSUyMHRyYW5zZm9ybWVycyUyMGltcG9ydCUyMEF1dG9Ub2tlbml6ZXIlMEElMEF0b2tlbml6ZXIlMjAlM0QlMjBBdXRvVG9rZW5pemVyLmZyb21fcHJldHJhaW5lZCglMjJkaXN0aWxiZXJ0JTJGZGlzdGlsYmVydC1iYXNlLXVuY2FzZWQlMjIp",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.from_pretrained(<span class="hljs-string">&quot;distilbert/distilbert-base-uncased&quot;</span>)`,wrap:!1}}),Jt=new _({props:{code:"ZGVmJTIwdG9rZW5pemVfZGF0YXNldChkYXRhc2V0KSUzQSUwQSUyMCUyMCUyMCUyMHJldHVybiUyMHRva2VuaXplcihkYXRhc2V0JTVCJTIydGV4dCUyMiU1RCklMjAlMjAlMjMlMjBkb2N0ZXN0JTNBJTIwJTJCU0tJUA==",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">def</span> <span class="hljs-title function_">tokenize_dataset</span>(<span class="hljs-params">dataset</span>):
<span class="hljs-meta">... </span>    <span class="hljs-keyword">return</span> tokenizer(dataset[<span class="hljs-string">&quot;text&quot;</span>])  <span class="hljs-comment"># doctest: +SKIP</span>`,wrap:!1}}),vt=new _({props:{code:"ZGF0YXNldCUyMCUzRCUyMGRhdGFzZXQubWFwKHRva2VuaXplX2RhdGFzZXQpJTIwJTIwJTIzJTIwZG9jdGVzdCUzQSUyMCUyQlNLSVAlMEF0Zl9kYXRhc2V0JTIwJTNEJTIwbW9kZWwucHJlcGFyZV90Zl9kYXRhc2V0KCUwQSUyMCUyMCUyMCUyMGRhdGFzZXQlNUIlMjJ0cmFpbiUyMiU1RCUyQyUyMGJhdGNoX3NpemUlM0QxNiUyQyUyMHNodWZmbGUlM0RUcnVlJTJDJTIwdG9rZW5pemVyJTNEdG9rZW5pemVyJTBBKSUyMCUyMCUyMyUyMGRvY3Rlc3QlM0ElMjAlMkJTS0lQ",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span>dataset = dataset.<span class="hljs-built_in">map</span>(tokenize_dataset)  <span class="hljs-comment"># doctest: +SKIP</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>tf_dataset = model.prepare_tf_dataset(
<span class="hljs-meta">... </span>    dataset[<span class="hljs-string">&quot;train&quot;</span>], batch_size=<span class="hljs-number">16</span>, shuffle=<span class="hljs-literal">True</span>, tokenizer=tokenizer
<span class="hljs-meta">... </span>)  <span class="hljs-comment"># doctest: +SKIP</span>`,wrap:!1}}),Ct=new _({props:{code:"ZnJvbSUyMHRlbnNvcmZsb3cua2VyYXMub3B0aW1pemVycyUyMGltcG9ydCUyMEFkYW0lMEElMEFtb2RlbC5jb21waWxlKG9wdGltaXplciUzRCdhZGFtJyklMjAlMjAlMjMlMjBObyUyMGxvc3MlMjBhcmd1bWVudCElMEFtb2RlbC5maXQodGZfZGF0YXNldCklMjAlMjAlMjMlMjBkb2N0ZXN0JTNBJTIwJTJCU0tJUA==",highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> tensorflow.keras.optimizers <span class="hljs-keyword">import</span> Adam

<span class="hljs-meta">&gt;&gt;&gt; </span>model.<span class="hljs-built_in">compile</span>(optimizer=<span class="hljs-string">&#x27;adam&#x27;</span>)  <span class="hljs-comment"># No loss argument!</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>model.fit(tf_dataset)  <span class="hljs-comment"># doctest: +SKIP</span>`,wrap:!1}}),Gt=new q({props:{title:"Chat with text generation models",local:"chat-with-text-generation-models",headingTag:"h2"}}),It=new _({props:{code:"dHJhbnNmb3JtZXJzLWNsaSUyMGNoYXQlMjAtLW1vZGVsX25hbWVfb3JfcGF0aCUyMFF3ZW4lMkZRd2VuMi41LTAuNUItSW5zdHJ1Y3Q=",highlighted:"transformers-cli chat --model_name_or_path Qwen/Qwen2.5-0.5B-Instruct",wrap:!1}}),xt=new _({props:{code:"dHJhbnNmb3JtZXJzLWNsaSUyMGNoYXQlMjAtaA==",highlighted:"transformers-cli chat -h",wrap:!1}}),Vt=new q({props:{title:"What’s next?",local:"whats-next",headingTag:"h2"}}),Xt=new pl({props:{source:"https://github.com/huggingface/transformers/blob/main/docs/source/en/quicktour.md"}}),{c(){s=g("meta"),o=i(),t=g("p"),r=i(),c(M.$$.fragment),m=i(),c(U.$$.fragment),G=i(),v=g("p"),v.innerHTML=R,w=i(),Z=g("p"),Z.textContent=z,X=i(),c(x.$$.fragment),I=i(),N=g("p"),N.textContent=k,C=i(),c(F.$$.fragment),j=i(),c(W.$$.fragment),re=i(),c(oe.$$.fragment),ms=i(),ie=g("p"),ie.innerHTML=ln,cs=i(),c(P.$$.fragment),fs=i(),pe=g("table"),pe.innerHTML=rn,ds=i(),me=g("p"),me.innerHTML=on,us=i(),c(ce.$$.fragment),hs=i(),fe=g("p"),fe.innerHTML=pn,$s=i(),c(de.$$.fragment),gs=i(),ue=g("p"),ue.innerHTML=mn,ys=i(),c(he.$$.fragment),Ms=i(),$e=g("p"),$e.innerHTML=cn,bs=i(),c(ge.$$.fragment),ws=i(),ye=g("p"),ye.innerHTML=fn,Ts=i(),c(Me.$$.fragment),js=i(),be=g("p"),be.innerHTML=dn,ks=i(),c(we.$$.fragment),_s=i(),Te=g("p"),Te.innerHTML=un,Js=i(),c(je.$$.fragment),Us=i(),ke=g("p"),ke.innerHTML=hn,vs=i(),c(_e.$$.fragment),Zs=i(),Je=g("p"),Je.innerHTML=$n,Cs=i(),c(Ue.$$.fragment),Gs=i(),c(O.$$.fragment),Ws=i(),ve=g("p"),ve.innerHTML=gn,Rs=i(),c(Ze.$$.fragment),Is=i(),Ce=g("p"),Ce.innerHTML=yn,Hs=i(),c(Ge.$$.fragment),xs=i(),c(We.$$.fragment),Fs=i(),Re=g("p"),Re.innerHTML=Mn,Vs=i(),Ie=g("p"),Ie.innerHTML=bn,zs=i(),c(He.$$.fragment),Xs=i(),xe=g("p"),xe.innerHTML=wn,Ns=i(),Fe=g("p"),Fe.innerHTML=Tn,As=i(),c(Ve.$$.fragment),Ys=i(),ze=g("p"),ze.textContent=jn,Es=i(),c(Xe.$$.fragment),Ls=i(),Ne=g("p"),Ne.textContent=kn,Bs=i(),Ae=g("ul"),Ae.innerHTML=_n,qs=i(),Ye=g("p"),Ye.textContent=Jn,Ss=i(),c(D.$$.fragment),Qs=i(),c(K.$$.fragment),Ps=i(),c(Ee.$$.fragment),Os=i(),c(ee.$$.fragment),Ds=i(),c(te.$$.fragment),Ks=i(),c(Le.$$.fragment),ea=i(),c(se.$$.fragment),ta=i(),Be=g("p"),Be.innerHTML=Un,sa=i(),c(ae.$$.fragment),aa=i(),c(qe.$$.fragment),na=i(),Se=g("p"),Se.textContent=vn,la=i(),Qe=g("p"),Qe.innerHTML=Zn,ra=i(),c(Pe.$$.fragment),oa=i(),c(ne.$$.fragment),ia=i(),Oe=g("p"),Oe.innerHTML=Cn,pa=i(),c(De.$$.fragment),ma=i(),Ke=g("p"),Ke.innerHTML=Gn,ca=i(),et=g("p"),et.innerHTML=Wn,fa=i(),V=g("ol"),tt=g("li"),Pt=g("p"),Pt.innerHTML=Rn,Fa=i(),c(st.$$.fragment),Va=i(),at=g("li"),Ot=g("p"),Ot.innerHTML=In,za=i(),c(nt.$$.fragment),Xa=i(),lt=g("li"),Dt=g("p"),Dt.textContent=Hn,Na=i(),c(rt.$$.fragment),Aa=i(),ot=g("li"),Kt=g("p"),Kt.textContent=xn,Ya=i(),c(it.$$.fragment),Ea=i(),S=g("li"),es=g("p"),es.textContent=Fn,La=i(),c(pt.$$.fragment),Ba=i(),ts=g("p"),ts.innerHTML=Vn,qa=i(),c(mt.$$.fragment),Sa=i(),ct=g("li"),ss=g("p"),ss.innerHTML=zn,Qa=i(),c(ft.$$.fragment),da=i(),dt=g("p"),dt.innerHTML=Xn,ua=i(),c(ut.$$.fragment),ha=i(),ht=g("p"),ht.innerHTML=Nn,$a=i(),c($t.$$.fragment),ga=i(),c(le.$$.fragment),ya=i(),gt=g("p"),gt.innerHTML=An,Ma=i(),yt=g("p"),yt.innerHTML=Yn,ba=i(),c(Mt.$$.fragment),wa=i(),bt=g("p"),bt.innerHTML=En,Ta=i(),E=g("ol"),wt=g("li"),as=g("p"),as.innerHTML=Ln,Pa=i(),c(Tt.$$.fragment),Oa=i(),jt=g("li"),ns=g("p"),ns.textContent=Bn,Da=i(),c(kt.$$.fragment),Ka=i(),_t=g("li"),ls=g("p"),ls.textContent=qn,en=i(),c(Jt.$$.fragment),tn=i(),Ut=g("li"),rs=g("p"),rs.innerHTML=Sn,sn=i(),c(vt.$$.fragment),an=i(),Zt=g("li"),os=g("p"),os.innerHTML=Qn,nn=i(),c(Ct.$$.fragment),ja=i(),c(Gt.$$.fragment),ka=i(),Wt=g("p"),Wt.innerHTML=Pn,_a=i(),Rt=g("p"),Rt.innerHTML=On,Ja=i(),c(It.$$.fragment),Ua=i(),Ht=g("p"),Ht.textContent=Dn,va=i(),c(xt.$$.fragment),Za=i(),Ft=g("p"),Ft.innerHTML=Kn,Ca=i(),c(Vt.$$.fragment),Ga=i(),zt=g("p"),zt.textContent=el,Wa=i(),c(Xt.$$.fragment),Ra=i(),ps=g("p"),this.h()},l(e){const a=ol("svelte-u9bgzb",document.head);s=y(a,"META",{name:!0,content:!0}),a.forEach(n),o=p(e),t=y(e,"P",{}),Y(t).forEach(n),r=p(e),f(M.$$.fragment,e),m=p(e),f(U.$$.fragment,e),G=p(e),v=y(e,"P",{"data-svelte-h":!0}),b(v)!=="svelte-qu8i7k"&&(v.innerHTML=R),w=p(e),Z=y(e,"P",{"data-svelte-h":!0}),b(Z)!=="svelte-1c9nexd"&&(Z.textContent=z),X=p(e),f(x.$$.fragment,e),I=p(e),N=y(e,"P",{"data-svelte-h":!0}),b(N)!=="svelte-1nw764u"&&(N.textContent=k),C=p(e),f(F.$$.fragment,e),j=p(e),f(W.$$.fragment,e),re=p(e),f(oe.$$.fragment,e),ms=p(e),ie=y(e,"P",{"data-svelte-h":!0}),b(ie)!=="svelte-1dtnm1c"&&(ie.innerHTML=ln),cs=p(e),f(P.$$.fragment,e),fs=p(e),pe=y(e,"TABLE",{"data-svelte-h":!0}),b(pe)!=="svelte-x282na"&&(pe.innerHTML=rn),ds=p(e),me=y(e,"P",{"data-svelte-h":!0}),b(me)!=="svelte-1s3aj34"&&(me.innerHTML=on),us=p(e),f(ce.$$.fragment,e),hs=p(e),fe=y(e,"P",{"data-svelte-h":!0}),b(fe)!=="svelte-kx5i7j"&&(fe.innerHTML=pn),$s=p(e),f(de.$$.fragment,e),gs=p(e),ue=y(e,"P",{"data-svelte-h":!0}),b(ue)!=="svelte-144so8s"&&(ue.innerHTML=mn),ys=p(e),f(he.$$.fragment,e),Ms=p(e),$e=y(e,"P",{"data-svelte-h":!0}),b($e)!=="svelte-9fh64d"&&($e.innerHTML=cn),bs=p(e),f(ge.$$.fragment,e),ws=p(e),ye=y(e,"P",{"data-svelte-h":!0}),b(ye)!=="svelte-1gp521x"&&(ye.innerHTML=fn),Ts=p(e),f(Me.$$.fragment,e),js=p(e),be=y(e,"P",{"data-svelte-h":!0}),b(be)!=="svelte-8z5qlz"&&(be.innerHTML=dn),ks=p(e),f(we.$$.fragment,e),_s=p(e),Te=y(e,"P",{"data-svelte-h":!0}),b(Te)!=="svelte-ue0ub3"&&(Te.innerHTML=un),Js=p(e),f(je.$$.fragment,e),Us=p(e),ke=y(e,"P",{"data-svelte-h":!0}),b(ke)!=="svelte-1q1ewi4"&&(ke.innerHTML=hn),vs=p(e),f(_e.$$.fragment,e),Zs=p(e),Je=y(e,"P",{"data-svelte-h":!0}),b(Je)!=="svelte-11eqp1z"&&(Je.innerHTML=$n),Cs=p(e),f(Ue.$$.fragment,e),Gs=p(e),f(O.$$.fragment,e),Ws=p(e),ve=y(e,"P",{"data-svelte-h":!0}),b(ve)!=="svelte-z8qwnn"&&(ve.innerHTML=gn),Rs=p(e),f(Ze.$$.fragment,e),Is=p(e),Ce=y(e,"P",{"data-svelte-h":!0}),b(Ce)!=="svelte-1tkpcvw"&&(Ce.innerHTML=yn),Hs=p(e),f(Ge.$$.fragment,e),xs=p(e),f(We.$$.fragment,e),Fs=p(e),Re=y(e,"P",{"data-svelte-h":!0}),b(Re)!=="svelte-abc8f8"&&(Re.innerHTML=Mn),Vs=p(e),Ie=y(e,"P",{"data-svelte-h":!0}),b(Ie)!=="svelte-vgd6up"&&(Ie.innerHTML=bn),zs=p(e),f(He.$$.fragment,e),Xs=p(e),xe=y(e,"P",{"data-svelte-h":!0}),b(xe)!=="svelte-1s6s1n"&&(xe.innerHTML=wn),Ns=p(e),Fe=y(e,"P",{"data-svelte-h":!0}),b(Fe)!=="svelte-1ce7t4m"&&(Fe.innerHTML=Tn),As=p(e),f(Ve.$$.fragment,e),Ys=p(e),ze=y(e,"P",{"data-svelte-h":!0}),b(ze)!=="svelte-1c0z2pg"&&(ze.textContent=jn),Es=p(e),f(Xe.$$.fragment,e),Ls=p(e),Ne=y(e,"P",{"data-svelte-h":!0}),b(Ne)!=="svelte-19i2zcw"&&(Ne.textContent=kn),Bs=p(e),Ae=y(e,"UL",{"data-svelte-h":!0}),b(Ae)!=="svelte-1q7h0a7"&&(Ae.innerHTML=_n),qs=p(e),Ye=y(e,"P",{"data-svelte-h":!0}),b(Ye)!=="svelte-3sx4bx"&&(Ye.textContent=Jn),Ss=p(e),f(D.$$.fragment,e),Qs=p(e),f(K.$$.fragment,e),Ps=p(e),f(Ee.$$.fragment,e),Os=p(e),f(ee.$$.fragment,e),Ds=p(e),f(te.$$.fragment,e),Ks=p(e),f(Le.$$.fragment,e),ea=p(e),f(se.$$.fragment,e),ta=p(e),Be=y(e,"P",{"data-svelte-h":!0}),b(Be)!=="svelte-10grpgy"&&(Be.innerHTML=Un),sa=p(e),f(ae.$$.fragment,e),aa=p(e),f(qe.$$.fragment,e),na=p(e),Se=y(e,"P",{"data-svelte-h":!0}),b(Se)!=="svelte-8iah3b"&&(Se.textContent=vn),la=p(e),Qe=y(e,"P",{"data-svelte-h":!0}),b(Qe)!=="svelte-1c0rueq"&&(Qe.innerHTML=Zn),ra=p(e),f(Pe.$$.fragment,e),oa=p(e),f(ne.$$.fragment,e),ia=p(e),Oe=y(e,"P",{"data-svelte-h":!0}),b(Oe)!=="svelte-1ld89qp"&&(Oe.innerHTML=Cn),pa=p(e),f(De.$$.fragment,e),ma=p(e),Ke=y(e,"P",{"data-svelte-h":!0}),b(Ke)!=="svelte-urakba"&&(Ke.innerHTML=Gn),ca=p(e),et=y(e,"P",{"data-svelte-h":!0}),b(et)!=="svelte-1b7ydqw"&&(et.innerHTML=Wn),fa=p(e),V=y(e,"OL",{});var A=Y(V);tt=y(A,"LI",{});var Nt=Y(tt);Pt=y(Nt,"P",{"data-svelte-h":!0}),b(Pt)!=="svelte-jld2kp"&&(Pt.innerHTML=Rn),Fa=p(Nt),f(st.$$.fragment,Nt),Nt.forEach(n),Va=p(A),at=y(A,"LI",{});var At=Y(at);Ot=y(At,"P",{"data-svelte-h":!0}),b(Ot)!=="svelte-18xr32e"&&(Ot.innerHTML=In),za=p(At),f(nt.$$.fragment,At),At.forEach(n),Xa=p(A),lt=y(A,"LI",{});var Yt=Y(lt);Dt=y(Yt,"P",{"data-svelte-h":!0}),b(Dt)!=="svelte-1ov2exk"&&(Dt.textContent=Hn),Na=p(Yt),f(rt.$$.fragment,Yt),Yt.forEach(n),Aa=p(A),ot=y(A,"LI",{});var Et=Y(ot);Kt=y(Et,"P",{"data-svelte-h":!0}),b(Kt)!=="svelte-1u8gaxj"&&(Kt.textContent=xn),Ya=p(Et),f(it.$$.fragment,Et),Et.forEach(n),Ea=p(A),S=y(A,"LI",{});var Q=Y(S);es=y(Q,"P",{"data-svelte-h":!0}),b(es)!=="svelte-1u6z95a"&&(es.textContent=Fn),La=p(Q),f(pt.$$.fragment,Q),Ba=p(Q),ts=y(Q,"P",{"data-svelte-h":!0}),b(ts)!=="svelte-1fz1ica"&&(ts.innerHTML=Vn),qa=p(Q),f(mt.$$.fragment,Q),Q.forEach(n),Sa=p(A),ct=y(A,"LI",{});var Lt=Y(ct);ss=y(Lt,"P",{"data-svelte-h":!0}),b(ss)!=="svelte-uat4v0"&&(ss.innerHTML=zn),Qa=p(Lt),f(ft.$$.fragment,Lt),Lt.forEach(n),A.forEach(n),da=p(e),dt=y(e,"P",{"data-svelte-h":!0}),b(dt)!=="svelte-1a9nun4"&&(dt.innerHTML=Xn),ua=p(e),f(ut.$$.fragment,e),ha=p(e),ht=y(e,"P",{"data-svelte-h":!0}),b(ht)!=="svelte-1rn5goj"&&(ht.innerHTML=Nn),$a=p(e),f($t.$$.fragment,e),ga=p(e),f(le.$$.fragment,e),ya=p(e),gt=y(e,"P",{"data-svelte-h":!0}),b(gt)!=="svelte-27dpu5"&&(gt.innerHTML=An),Ma=p(e),yt=y(e,"P",{"data-svelte-h":!0}),b(yt)!=="svelte-1s7pvya"&&(yt.innerHTML=Yn),ba=p(e),f(Mt.$$.fragment,e),wa=p(e),bt=y(e,"P",{"data-svelte-h":!0}),b(bt)!=="svelte-gae27c"&&(bt.innerHTML=En),Ta=p(e),E=y(e,"OL",{});var B=Y(E);wt=y(B,"LI",{});var Bt=Y(wt);as=y(Bt,"P",{"data-svelte-h":!0}),b(as)!=="svelte-137rzzn"&&(as.innerHTML=Ln),Pa=p(Bt),f(Tt.$$.fragment,Bt),Bt.forEach(n),Oa=p(B),jt=y(B,"LI",{});var qt=Y(jt);ns=y(qt,"P",{"data-svelte-h":!0}),b(ns)!=="svelte-1ov2exk"&&(ns.textContent=Bn),Da=p(qt),f(kt.$$.fragment,qt),qt.forEach(n),Ka=p(B),_t=y(B,"LI",{});var St=Y(_t);ls=y(St,"P",{"data-svelte-h":!0}),b(ls)!=="svelte-1u6z95a"&&(ls.textContent=qn),en=p(St),f(Jt.$$.fragment,St),St.forEach(n),tn=p(B),Ut=y(B,"LI",{});var Ha=Y(Ut);rs=y(Ha,"P",{"data-svelte-h":!0}),b(rs)!=="svelte-11qq3xg"&&(rs.innerHTML=Sn),sn=p(Ha),f(vt.$$.fragment,Ha),Ha.forEach(n),an=p(B),Zt=y(B,"LI",{});var xa=Y(Zt);os=y(xa,"P",{"data-svelte-h":!0}),b(os)!=="svelte-1map0wi"&&(os.innerHTML=Qn),nn=p(xa),f(Ct.$$.fragment,xa),xa.forEach(n),B.forEach(n),ja=p(e),f(Gt.$$.fragment,e),ka=p(e),Wt=y(e,"P",{"data-svelte-h":!0}),b(Wt)!=="svelte-1drszvq"&&(Wt.innerHTML=Pn),_a=p(e),Rt=y(e,"P",{"data-svelte-h":!0}),b(Rt)!=="svelte-1qqsyey"&&(Rt.innerHTML=On),Ja=p(e),f(It.$$.fragment,e),Ua=p(e),Ht=y(e,"P",{"data-svelte-h":!0}),b(Ht)!=="svelte-mbdsi5"&&(Ht.textContent=Dn),va=p(e),f(xt.$$.fragment,e),Za=p(e),Ft=y(e,"P",{"data-svelte-h":!0}),b(Ft)!=="svelte-15ly5jz"&&(Ft.innerHTML=Kn),Ca=p(e),f(Vt.$$.fragment,e),Ga=p(e),zt=y(e,"P",{"data-svelte-h":!0}),b(zt)!=="svelte-gn9in9"&&(zt.textContent=el),Wa=p(e),f(Xt.$$.fragment,e),Ra=p(e),ps=y(e,"P",{}),Y(ps).forEach(n),this.h()},h(){tl(s,"name","hf:doc:metadata"),tl(s,"content",Ll)},m(e,a){J(document.head,s),l(e,o,a),l(e,t,a),l(e,r,a),d(M,e,a),l(e,m,a),d(U,e,a),l(e,G,a),l(e,v,a),l(e,w,a),l(e,Z,a),l(e,X,a),d(x,e,a),l(e,I,a),l(e,N,a),l(e,C,a),d(F,e,a),l(e,j,a),d(W,e,a),l(e,re,a),d(oe,e,a),l(e,ms,a),l(e,ie,a),l(e,cs,a),d(P,e,a),l(e,fs,a),l(e,pe,a),l(e,ds,a),l(e,me,a),l(e,us,a),d(ce,e,a),l(e,hs,a),l(e,fe,a),l(e,$s,a),d(de,e,a),l(e,gs,a),l(e,ue,a),l(e,ys,a),d(he,e,a),l(e,Ms,a),l(e,$e,a),l(e,bs,a),d(ge,e,a),l(e,ws,a),l(e,ye,a),l(e,Ts,a),d(Me,e,a),l(e,js,a),l(e,be,a),l(e,ks,a),d(we,e,a),l(e,_s,a),l(e,Te,a),l(e,Js,a),d(je,e,a),l(e,Us,a),l(e,ke,a),l(e,vs,a),d(_e,e,a),l(e,Zs,a),l(e,Je,a),l(e,Cs,a),d(Ue,e,a),l(e,Gs,a),d(O,e,a),l(e,Ws,a),l(e,ve,a),l(e,Rs,a),d(Ze,e,a),l(e,Is,a),l(e,Ce,a),l(e,Hs,a),d(Ge,e,a),l(e,xs,a),d(We,e,a),l(e,Fs,a),l(e,Re,a),l(e,Vs,a),l(e,Ie,a),l(e,zs,a),d(He,e,a),l(e,Xs,a),l(e,xe,a),l(e,Ns,a),l(e,Fe,a),l(e,As,a),d(Ve,e,a),l(e,Ys,a),l(e,ze,a),l(e,Es,a),d(Xe,e,a),l(e,Ls,a),l(e,Ne,a),l(e,Bs,a),l(e,Ae,a),l(e,qs,a),l(e,Ye,a),l(e,Ss,a),d(D,e,a),l(e,Qs,a),d(K,e,a),l(e,Ps,a),d(Ee,e,a),l(e,Os,a),d(ee,e,a),l(e,Ds,a),d(te,e,a),l(e,Ks,a),d(Le,e,a),l(e,ea,a),d(se,e,a),l(e,ta,a),l(e,Be,a),l(e,sa,a),d(ae,e,a),l(e,aa,a),d(qe,e,a),l(e,na,a),l(e,Se,a),l(e,la,a),l(e,Qe,a),l(e,ra,a),d(Pe,e,a),l(e,oa,a),d(ne,e,a),l(e,ia,a),l(e,Oe,a),l(e,pa,a),d(De,e,a),l(e,ma,a),l(e,Ke,a),l(e,ca,a),l(e,et,a),l(e,fa,a),l(e,V,a),J(V,tt),J(tt,Pt),J(tt,Fa),d(st,tt,null),J(V,Va),J(V,at),J(at,Ot),J(at,za),d(nt,at,null),J(V,Xa),J(V,lt),J(lt,Dt),J(lt,Na),d(rt,lt,null),J(V,Aa),J(V,ot),J(ot,Kt),J(ot,Ya),d(it,ot,null),J(V,Ea),J(V,S),J(S,es),J(S,La),d(pt,S,null),J(S,Ba),J(S,ts),J(S,qa),d(mt,S,null),J(V,Sa),J(V,ct),J(ct,ss),J(ct,Qa),d(ft,ct,null),l(e,da,a),l(e,dt,a),l(e,ua,a),d(ut,e,a),l(e,ha,a),l(e,ht,a),l(e,$a,a),d($t,e,a),l(e,ga,a),d(le,e,a),l(e,ya,a),l(e,gt,a),l(e,Ma,a),l(e,yt,a),l(e,ba,a),d(Mt,e,a),l(e,wa,a),l(e,bt,a),l(e,Ta,a),l(e,E,a),J(E,wt),J(wt,as),J(wt,Pa),d(Tt,wt,null),J(E,Oa),J(E,jt),J(jt,ns),J(jt,Da),d(kt,jt,null),J(E,Ka),J(E,_t),J(_t,ls),J(_t,en),d(Jt,_t,null),J(E,tn),J(E,Ut),J(Ut,rs),J(Ut,sn),d(vt,Ut,null),J(E,an),J(E,Zt),J(Zt,os),J(Zt,nn),d(Ct,Zt,null),l(e,ja,a),d(Gt,e,a),l(e,ka,a),l(e,Wt,a),l(e,_a,a),l(e,Rt,a),l(e,Ja,a),d(It,e,a),l(e,Ua,a),l(e,Ht,a),l(e,va,a),d(xt,e,a),l(e,Za,a),l(e,Ft,a),l(e,Ca,a),d(Vt,e,a),l(e,Ga,a),l(e,zt,a),l(e,Wa,a),d(Xt,e,a),l(e,Ra,a),l(e,ps,a),Ia=!0},p(e,[a]){const A={};a&2&&(A.$$scope={dirty:a,ctx:e}),F.$set(A);const Nt={};a&2&&(Nt.$$scope={dirty:a,ctx:e}),P.$set(Nt);const At={};a&2&&(At.$$scope={dirty:a,ctx:e}),O.$set(At);const Yt={};a&2&&(Yt.$$scope={dirty:a,ctx:e}),D.$set(Yt);const Et={};a&2&&(Et.$$scope={dirty:a,ctx:e}),K.$set(Et);const Q={};a&2&&(Q.$$scope={dirty:a,ctx:e}),ee.$set(Q);const Lt={};a&2&&(Lt.$$scope={dirty:a,ctx:e}),te.$set(Lt);const B={};a&2&&(B.$$scope={dirty:a,ctx:e}),se.$set(B);const Bt={};a&2&&(Bt.$$scope={dirty:a,ctx:e}),ae.$set(Bt);const qt={};a&2&&(qt.$$scope={dirty:a,ctx:e}),ne.$set(qt);const St={};a&2&&(St.$$scope={dirty:a,ctx:e}),le.$set(St)},i(e){Ia||(u(M.$$.fragment,e),u(U.$$.fragment,e),u(x.$$.fragment,e),u(F.$$.fragment,e),u(W.$$.fragment,e),u(oe.$$.fragment,e),u(P.$$.fragment,e),u(ce.$$.fragment,e),u(de.$$.fragment,e),u(he.$$.fragment,e),u(ge.$$.fragment,e),u(Me.$$.fragment,e),u(we.$$.fragment,e),u(je.$$.fragment,e),u(_e.$$.fragment,e),u(Ue.$$.fragment,e),u(O.$$.fragment,e),u(Ze.$$.fragment,e),u(Ge.$$.fragment,e),u(We.$$.fragment,e),u(He.$$.fragment,e),u(Ve.$$.fragment,e),u(Xe.$$.fragment,e),u(D.$$.fragment,e),u(K.$$.fragment,e),u(Ee.$$.fragment,e),u(ee.$$.fragment,e),u(te.$$.fragment,e),u(Le.$$.fragment,e),u(se.$$.fragment,e),u(ae.$$.fragment,e),u(qe.$$.fragment,e),u(Pe.$$.fragment,e),u(ne.$$.fragment,e),u(De.$$.fragment,e),u(st.$$.fragment,e),u(nt.$$.fragment,e),u(rt.$$.fragment,e),u(it.$$.fragment,e),u(pt.$$.fragment,e),u(mt.$$.fragment,e),u(ft.$$.fragment,e),u(ut.$$.fragment,e),u($t.$$.fragment,e),u(le.$$.fragment,e),u(Mt.$$.fragment,e),u(Tt.$$.fragment,e),u(kt.$$.fragment,e),u(Jt.$$.fragment,e),u(vt.$$.fragment,e),u(Ct.$$.fragment,e),u(Gt.$$.fragment,e),u(It.$$.fragment,e),u(xt.$$.fragment,e),u(Vt.$$.fragment,e),u(Xt.$$.fragment,e),Ia=!0)},o(e){h(M.$$.fragment,e),h(U.$$.fragment,e),h(x.$$.fragment,e),h(F.$$.fragment,e),h(W.$$.fragment,e),h(oe.$$.fragment,e),h(P.$$.fragment,e),h(ce.$$.fragment,e),h(de.$$.fragment,e),h(he.$$.fragment,e),h(ge.$$.fragment,e),h(Me.$$.fragment,e),h(we.$$.fragment,e),h(je.$$.fragment,e),h(_e.$$.fragment,e),h(Ue.$$.fragment,e),h(O.$$.fragment,e),h(Ze.$$.fragment,e),h(Ge.$$.fragment,e),h(We.$$.fragment,e),h(He.$$.fragment,e),h(Ve.$$.fragment,e),h(Xe.$$.fragment,e),h(D.$$.fragment,e),h(K.$$.fragment,e),h(Ee.$$.fragment,e),h(ee.$$.fragment,e),h(te.$$.fragment,e),h(Le.$$.fragment,e),h(se.$$.fragment,e),h(ae.$$.fragment,e),h(qe.$$.fragment,e),h(Pe.$$.fragment,e),h(ne.$$.fragment,e),h(De.$$.fragment,e),h(st.$$.fragment,e),h(nt.$$.fragment,e),h(rt.$$.fragment,e),h(it.$$.fragment,e),h(pt.$$.fragment,e),h(mt.$$.fragment,e),h(ft.$$.fragment,e),h(ut.$$.fragment,e),h($t.$$.fragment,e),h(le.$$.fragment,e),h(Mt.$$.fragment,e),h(Tt.$$.fragment,e),h(kt.$$.fragment,e),h(Jt.$$.fragment,e),h(vt.$$.fragment,e),h(Ct.$$.fragment,e),h(Gt.$$.fragment,e),h(It.$$.fragment,e),h(xt.$$.fragment,e),h(Vt.$$.fragment,e),h(Xt.$$.fragment,e),Ia=!1},d(e){e&&(n(o),n(t),n(r),n(m),n(G),n(v),n(w),n(Z),n(X),n(I),n(N),n(C),n(j),n(re),n(ms),n(ie),n(cs),n(fs),n(pe),n(ds),n(me),n(us),n(hs),n(fe),n($s),n(gs),n(ue),n(ys),n(Ms),n($e),n(bs),n(ws),n(ye),n(Ts),n(js),n(be),n(ks),n(_s),n(Te),n(Js),n(Us),n(ke),n(vs),n(Zs),n(Je),n(Cs),n(Gs),n(Ws),n(ve),n(Rs),n(Is),n(Ce),n(Hs),n(xs),n(Fs),n(Re),n(Vs),n(Ie),n(zs),n(Xs),n(xe),n(Ns),n(Fe),n(As),n(Ys),n(ze),n(Es),n(Ls),n(Ne),n(Bs),n(Ae),n(qs),n(Ye),n(Ss),n(Qs),n(Ps),n(Os),n(Ds),n(Ks),n(ea),n(ta),n(Be),n(sa),n(aa),n(na),n(Se),n(la),n(Qe),n(ra),n(oa),n(ia),n(Oe),n(pa),n(ma),n(Ke),n(ca),n(et),n(fa),n(V),n(da),n(dt),n(ua),n(ha),n(ht),n($a),n(ga),n(ya),n(gt),n(Ma),n(yt),n(ba),n(wa),n(bt),n(Ta),n(E),n(ja),n(ka),n(Wt),n(_a),n(Rt),n(Ja),n(Ua),n(Ht),n(va),n(Za),n(Ft),n(Ca),n(Ga),n(zt),n(Wa),n(Ra),n(ps)),n(s),$(M,e),$(U,e),$(x,e),$(F,e),$(W,e),$(oe,e),$(P,e),$(ce,e),$(de,e),$(he,e),$(ge,e),$(Me,e),$(we,e),$(je,e),$(_e,e),$(Ue,e),$(O,e),$(Ze,e),$(Ge,e),$(We,e),$(He,e),$(Ve,e),$(Xe,e),$(D,e),$(K,e),$(Ee,e),$(ee,e),$(te,e),$(Le,e),$(se,e),$(ae,e),$(qe,e),$(Pe,e),$(ne,e),$(De,e),$(st),$(nt),$(rt),$(it),$(pt),$(mt),$(ft),$(ut,e),$($t,e),$(le,e),$(Mt,e),$(Tt),$(kt),$(Jt),$(vt),$(Ct),$(Gt,e),$(It,e),$(xt,e),$(Vt,e),$(Xt,e)}}}const Ll='{"title":"Quick tour","local":"quick-tour","sections":[{"title":"Pipeline","local":"pipeline","sections":[{"title":"Use another model and tokenizer in the pipeline","local":"use-another-model-and-tokenizer-in-the-pipeline","sections":[],"depth":3}],"depth":2},{"title":"AutoClass","local":"autoclass","sections":[{"title":"AutoTokenizer","local":"autotokenizer","sections":[],"depth":3},{"title":"AutoModel","local":"automodel","sections":[],"depth":3},{"title":"Save a model","local":"save-a-model","sections":[],"depth":3}],"depth":2},{"title":"Custom model builds","local":"custom-model-builds","sections":[],"depth":2},{"title":"Trainer - a PyTorch optimized training loop","local":"trainer---a-pytorch-optimized-training-loop","sections":[],"depth":2},{"title":"Train with TensorFlow","local":"train-with-tensorflow","sections":[],"depth":2},{"title":"Chat with text generation models","local":"chat-with-text-generation-models","sections":[],"depth":2},{"title":"What’s next?","local":"whats-next","sections":[],"depth":2}],"depth":1}';function Bl(T){return nl(()=>{new URLSearchParams(window.location.search).get("fw")}),[]}class tr extends ll{constructor(s){super(),rl(this,s,Bl,El,al,{})}}export{tr as component};
