import{s as N,n as O,o as Q}from"../chunks/scheduler.37c15a92.js";import{S as X,i as I,g as h,s as r,r as M,A as J,h as d,f as a,c as l,j as B,u as G,x as S,k as F,y as K,a as n,v as j,d as q,t as z,w as A}from"../chunks/index.2bf4358c.js";import{Y as V}from"../chunks/Youtube.1e50a667.js";import{C as W}from"../chunks/CourseFloatingBanner.6add7356.js";import{H as Z,E as tt}from"../chunks/index.b8688d36.js";function et(D){let o,x,g,w,s,v,i,b,m,C,f,R="โมเดล decoder ใช้เพียงส่วน decoder จากโมเดล Transformer เท่านั้น ในแต่ละชั้น attention layer สามารถเข้าถึงคำที่อยู่ตำแหน่งก่อนหน้าในประโยคได้เท่านั้น โมเดลเหล่านี้เรียกว่า <em>โมเดล auto-regressive</em>",P,p,U="โมเดล pretrain ในกลุ่มนี้ใช้ในการทำนายคำต่อไปในประโยค เหมาะสำหรับงานในการสร้างข้อความ",T,u,Y="ตัวแทนโมเดลในกลุ่มนี้ได้แก่:",L,c,k='<li><a href="https://huggingface.co/transformers/model_doc/ctrl.html" rel="nofollow">CTRL</a></li> <li><a href="https://huggingface.co/docs/transformers/model_doc/openai-gpt" rel="nofollow">GPT</a></li> <li><a href="https://huggingface.co/transformers/model_doc/gpt2.html" rel="nofollow">GPT-2</a></li> <li><a href="https://huggingface.co/transformers/model_doc/transformerxl.html" rel="nofollow">Transformer XL</a></li>',y,$,E,_,H;return s=new Z({props:{title:"โมเดล Decoder",local:"โมเดล-decoder",headingTag:"h1"}}),i=new W({props:{chapter:1,classNames:"absolute z-10 right-0 top-0"}}),m=new V({props:{id:"d_ixlCubqQw"}}),$=new tt({props:{source:"https://github.com/huggingface/course/blob/main/chapters/th/chapter1/6.mdx"}}),{c(){o=h("meta"),x=r(),g=h("p"),w=r(),M(s.$$.fragment),v=r(),M(i.$$.fragment),b=r(),M(m.$$.fragment),C=r(),f=h("p"),f.innerHTML=R,P=r(),p=h("p"),p.textContent=U,T=r(),u=h("p"),u.textContent=Y,L=r(),c=h("ul"),c.innerHTML=k,y=r(),M($.$$.fragment),E=r(),_=h("p"),this.h()},l(t){const e=J("svelte-u9bgzb",document.head);o=d(e,"META",{name:!0,content:!0}),e.forEach(a),x=l(t),g=d(t,"P",{}),B(g).forEach(a),w=l(t),G(s.$$.fragment,t),v=l(t),G(i.$$.fragment,t),b=l(t),G(m.$$.fragment,t),C=l(t),f=d(t,"P",{"data-svelte-h":!0}),S(f)!=="svelte-g9wnys"&&(f.innerHTML=R),P=l(t),p=d(t,"P",{"data-svelte-h":!0}),S(p)!=="svelte-19dviih"&&(p.textContent=U),T=l(t),u=d(t,"P",{"data-svelte-h":!0}),S(u)!=="svelte-10huopx"&&(u.textContent=Y),L=l(t),c=d(t,"UL",{"data-svelte-h":!0}),S(c)!=="svelte-jabf5n"&&(c.innerHTML=k),y=l(t),G($.$$.fragment,t),E=l(t),_=d(t,"P",{}),B(_).forEach(a),this.h()},h(){F(o,"name","hf:doc:metadata"),F(o,"content",at)},m(t,e){K(document.head,o),n(t,x,e),n(t,g,e),n(t,w,e),j(s,t,e),n(t,v,e),j(i,t,e),n(t,b,e),j(m,t,e),n(t,C,e),n(t,f,e),n(t,P,e),n(t,p,e),n(t,T,e),n(t,u,e),n(t,L,e),n(t,c,e),n(t,y,e),j($,t,e),n(t,E,e),n(t,_,e),H=!0},p:O,i(t){H||(q(s.$$.fragment,t),q(i.$$.fragment,t),q(m.$$.fragment,t),q($.$$.fragment,t),H=!0)},o(t){z(s.$$.fragment,t),z(i.$$.fragment,t),z(m.$$.fragment,t),z($.$$.fragment,t),H=!1},d(t){t&&(a(x),a(g),a(w),a(v),a(b),a(C),a(f),a(P),a(p),a(T),a(u),a(L),a(c),a(y),a(E),a(_)),a(o),A(s,t),A(i,t),A(m,t),A($,t)}}}const at='{"title":"โมเดล Decoder","local":"โมเดล-decoder","sections":[],"depth":1}';function nt(D){return Q(()=>{new URLSearchParams(window.location.search).get("fw")}),[]}class mt extends X{constructor(o){super(),I(this,o,nt,et,N,{})}}export{mt as component};
