import{s as Q,n as I,o as K}from"../chunks/scheduler.37c15a92.js";import{S as V,i as W,g as r,s as n,r as A,A as X,h as i,f as l,c as s,j as J,u as H,x as C,k as O,y as Z,a,v as q,d as N,t as S,w as U}from"../chunks/index.2bf4358c.js";import{Y as tt}from"../chunks/Youtube.1e50a667.js";import{C as et}from"../chunks/CourseFloatingBanner.06521e8b.js";import{H as lt,E as at}from"../chunks/EditOnGithub.8916dc7c.js";function nt(j){let o,w,d,b,m,v,f,E,p,P,u,k="“编码器”模型指仅使用编码器的Transformer模型。在每个阶段，注意力层都可以获取初始句子中的所有单词。这些模型通常具有“双向”注意力，被称为自编码模型。",T,c,Y="这些模型的预训练通常围绕着以某种方式破坏给定的句子（例如：通过随机遮盖其中的单词），并让模型寻找或重建给定的句子。",R,h,D="“编码器”模型最适合于需要理解完整句子的任务，例如：句子分类、命名实体识别（以及更普遍的单词分类）和阅读理解后回答问题。",y,$,F="该系列模型的典型代表有：",L,g,G='<li><a href="https://huggingface.co/transformers/model_doc/albert.html" rel="nofollow">ALBERT</a></li> <li><a href="https://huggingface.co/transformers/model_doc/bert.html" rel="nofollow">BERT</a></li> <li><a href="https://huggingface.co/transformers/model_doc/distilbert.html" rel="nofollow">DistilBERT</a></li> <li><a href="https://huggingface.co/transformers/model_doc/electra.html" rel="nofollow">ELECTRA</a></li> <li><a href="https://huggingface.co/transformers/model_doc/roberta.html" rel="nofollow">RoBERTa</a></li>',z,_,B,x,M;return m=new lt({props:{title:"“编码器”模型",local:"“编码器”模型",headingTag:"h1"}}),f=new et({props:{chapter:1,classNames:"absolute z-10 right-0 top-0"}}),p=new tt({props:{id:"MUqNwgPjJvQ"}}),_=new at({props:{source:"https://github.com/huggingface/course/blob/main/chapters/zh-CN/chapter1/5.mdx"}}),{c(){o=r("meta"),w=n(),d=r("p"),b=n(),A(m.$$.fragment),v=n(),A(f.$$.fragment),E=n(),A(p.$$.fragment),P=n(),u=r("p"),u.textContent=k,T=n(),c=r("p"),c.textContent=Y,R=n(),h=r("p"),h.textContent=D,y=n(),$=r("p"),$.textContent=F,L=n(),g=r("ul"),g.innerHTML=G,z=n(),A(_.$$.fragment),B=n(),x=r("p"),this.h()},l(t){const e=X("svelte-u9bgzb",document.head);o=i(e,"META",{name:!0,content:!0}),e.forEach(l),w=s(t),d=i(t,"P",{}),J(d).forEach(l),b=s(t),H(m.$$.fragment,t),v=s(t),H(f.$$.fragment,t),E=s(t),H(p.$$.fragment,t),P=s(t),u=i(t,"P",{"data-svelte-h":!0}),C(u)!=="svelte-19lexn2"&&(u.textContent=k),T=s(t),c=i(t,"P",{"data-svelte-h":!0}),C(c)!=="svelte-17pl5uc"&&(c.textContent=Y),R=s(t),h=i(t,"P",{"data-svelte-h":!0}),C(h)!=="svelte-i2ws9u"&&(h.textContent=D),y=s(t),$=i(t,"P",{"data-svelte-h":!0}),C($)!=="svelte-rgo3yq"&&($.textContent=F),L=s(t),g=i(t,"UL",{"data-svelte-h":!0}),C(g)!=="svelte-18kzzol"&&(g.innerHTML=G),z=s(t),H(_.$$.fragment,t),B=s(t),x=i(t,"P",{}),J(x).forEach(l),this.h()},h(){O(o,"name","hf:doc:metadata"),O(o,"content",st)},m(t,e){Z(document.head,o),a(t,w,e),a(t,d,e),a(t,b,e),q(m,t,e),a(t,v,e),q(f,t,e),a(t,E,e),q(p,t,e),a(t,P,e),a(t,u,e),a(t,T,e),a(t,c,e),a(t,R,e),a(t,h,e),a(t,y,e),a(t,$,e),a(t,L,e),a(t,g,e),a(t,z,e),q(_,t,e),a(t,B,e),a(t,x,e),M=!0},p:I,i(t){M||(N(m.$$.fragment,t),N(f.$$.fragment,t),N(p.$$.fragment,t),N(_.$$.fragment,t),M=!0)},o(t){S(m.$$.fragment,t),S(f.$$.fragment,t),S(p.$$.fragment,t),S(_.$$.fragment,t),M=!1},d(t){t&&(l(w),l(d),l(b),l(v),l(E),l(P),l(u),l(T),l(c),l(R),l(h),l(y),l($),l(L),l(g),l(z),l(B),l(x)),l(o),U(m,t),U(f,t),U(p,t),U(_,t)}}}const st='{"title":"“编码器”模型","local":"“编码器”模型","sections":[],"depth":1}';function ot(j){return K(()=>{new URLSearchParams(window.location.search).get("fw")}),[]}class ut extends V{constructor(o){super(),W(this,o,ot,nt,Q,{})}}export{ut as component};
