Buckets:

rtrm's picture
download
raw
5.06 kB
import{s as I,n as J,o as Q}from"../chunks/scheduler.37c15a92.js";import{S as V,i as W,g as o,s as l,r as k,A as X,h as i,f as n,c as s,j as O,u as B,x as b,k as D,y as Z,a,v as R,d as S,t as z,w as U}from"../chunks/index.2bf4358c.js";import{Y as ee}from"../chunks/Youtube.1e50a667.js";import{C as te}from"../chunks/CourseFloatingBanner.6add7356.js";import{H as ne,E as ae}from"../chunks/getInferenceSnippets.ebf8be91.js";function le(Y){let r,w,g,v,m,q,f,T,u,C,p,j="โมเดล encoder-decoder (หรือเรียกอีกชื่อหนึ่งว่า <em>โมเดล sequence-to-sequence</em>) ใช้ทั้งสองส่วนในสถาปัตยกรรม Transformer ในแต่ละชั้น attention layer ของ encoder จะเข้าถึงคำทั้งหมดในประโยคเริ่มต้นได้ ในขณะที่ attention layer ของ decoder สามารถเข้าถึงได้เพียงคำที่อยู่ตำแหน่งก่อนหน้าคำที่กำหนดใน input เท่านั้น",P,c,F='โมเดล pretrain สามารถเทรนมาในลักษณะเดียวกับโมเดล encoder หรือโมเดล decoder ก็ได้ แต่โดยมากแล้วจะซับซ้อนมากกว่า ตัวอย่างเช่น <a href="https://huggingface.co/t5-base" rel="nofollow">T5</a> ถูกเทรนมาโดยการแทนที่กลุ่มคำ(ซึ่งอาจจะมีเพียงคำเดียวหรือหลายคำก็ได้)ด้วยคำพิเศษคำเดียว และเป้าหมายคือให้ทำนายข้อความที่คำพิเศษคำนี้แทนที่มา',y,h,G="โมเดล sequence-to-sequence เหมาะกับงานในการสร้างประโยคขึ้นมาใหม่จาก input ที่กำหนดให้ เช่น การสรุปความ, การแปลภาษา, หรือการสร้างคำตอบจากคำถาม",M,$,K="ตัวแทนโมเดลในกลุ่มนี้ได้แก่:",E,d,N='<li><a href="https://huggingface.co/transformers/model_doc/bart.html" rel="nofollow">BART</a></li> <li><a href="https://huggingface.co/transformers/model_doc/mbart.html" rel="nofollow">mBART</a></li> <li><a href="https://huggingface.co/transformers/model_doc/marian.html" rel="nofollow">Marian</a></li> <li><a href="https://huggingface.co/transformers/model_doc/t5.html" rel="nofollow">T5</a></li>',H,_,L,x,A;return m=new ne({props:{title:"โมเดล sequence-to-sequence",local:"โมเดล-sequence-to-sequence",headingTag:"h1"}}),f=new te({props:{chapter:1,classNames:"absolute z-10 right-0 top-0"}}),u=new ee({props:{id:"0_4KEb08xrE"}}),_=new ae({props:{source:"https://github.com/huggingface/course/blob/main/chapters/th/chapter1/7.mdx"}}),{c(){r=o("meta"),w=l(),g=o("p"),v=l(),k(m.$$.fragment),q=l(),k(f.$$.fragment),T=l(),k(u.$$.fragment),C=l(),p=o("p"),p.innerHTML=j,P=l(),c=o("p"),c.innerHTML=F,y=l(),h=o("p"),h.textContent=G,M=l(),$=o("p"),$.textContent=K,E=l(),d=o("ul"),d.innerHTML=N,H=l(),k(_.$$.fragment),L=l(),x=o("p"),this.h()},l(e){const t=X("svelte-u9bgzb",document.head);r=i(t,"META",{name:!0,content:!0}),t.forEach(n),w=s(e),g=i(e,"P",{}),O(g).forEach(n),v=s(e),B(m.$$.fragment,e),q=s(e),B(f.$$.fragment,e),T=s(e),B(u.$$.fragment,e),C=s(e),p=i(e,"P",{"data-svelte-h":!0}),b(p)!=="svelte-1hft4u4"&&(p.innerHTML=j),P=s(e),c=i(e,"P",{"data-svelte-h":!0}),b(c)!=="svelte-1ubrxyl"&&(c.innerHTML=F),y=s(e),h=i(e,"P",{"data-svelte-h":!0}),b(h)!=="svelte-18wkkr0"&&(h.textContent=G),M=s(e),$=i(e,"P",{"data-svelte-h":!0}),b($)!=="svelte-10huopx"&&($.textContent=K),E=s(e),d=i(e,"UL",{"data-svelte-h":!0}),b(d)!=="svelte-1lyffe"&&(d.innerHTML=N),H=s(e),B(_.$$.fragment,e),L=s(e),x=i(e,"P",{}),O(x).forEach(n),this.h()},h(){D(r,"name","hf:doc:metadata"),D(r,"content",se)},m(e,t){Z(document.head,r),a(e,w,t),a(e,g,t),a(e,v,t),R(m,e,t),a(e,q,t),R(f,e,t),a(e,T,t),R(u,e,t),a(e,C,t),a(e,p,t),a(e,P,t),a(e,c,t),a(e,y,t),a(e,h,t),a(e,M,t),a(e,$,t),a(e,E,t),a(e,d,t),a(e,H,t),R(_,e,t),a(e,L,t),a(e,x,t),A=!0},p:J,i(e){A||(S(m.$$.fragment,e),S(f.$$.fragment,e),S(u.$$.fragment,e),S(_.$$.fragment,e),A=!0)},o(e){z(m.$$.fragment,e),z(f.$$.fragment,e),z(u.$$.fragment,e),z(_.$$.fragment,e),A=!1},d(e){e&&(n(w),n(g),n(v),n(q),n(T),n(C),n(p),n(P),n(c),n(y),n(h),n(M),n($),n(E),n(d),n(H),n(L),n(x)),n(r),U(m,e),U(f,e),U(u,e),U(_,e)}}}const se='{"title":"โมเดล sequence-to-sequence","local":"โมเดล-sequence-to-sequence","sections":[],"depth":1}';function re(Y){return Q(()=>{new URLSearchParams(window.location.search).get("fw")}),[]}class pe extends V{constructor(r){super(),W(this,r,re,le,I,{})}}export{pe as component};

Xet Storage Details

Size:
5.06 kB
·
Xet hash:
d7b08d4180ac54241669a5265d560b43f2f0bdb3445692319426b5db70d12457

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