import{s as Ot,n as Kt,o as tl}from"../chunks/scheduler.f38f3a0e.js";import{S as ll,i as sl,e as y,s as n,c as i,h as el,a as T,d as s,b as a,f as Lt,j as M,g as U,k as Pt,m as nl,n as e,o as p,t as J,p as o,q as u}from"../chunks/index.a03143fc.js";import{C as al,H as r,E as il}from"../chunks/MermaidChart.svelte_svelte_type_style_lang.5f629a20.js";import{C as L}from"../chunks/CodeBlock.b37d0538.js";import{C as Ml}from"../chunks/CourseFloatingBanner.9d00122a.js";function pl(Zt){let m,K,P,tt,j,lt,c,st,f,et,g,zt="대화 템플릿은 언어 모델과 사용자 간 상호작용을 구조화하는 데 필수적입니다. 이 템플릿은 대화에 일관된 형식을 제공하여, 모델이 각 메시지의 맥락과 역할을 이해하고 적절한 응답 패턴을 유지할 수 있도록 합니다.",nt,h,at,I,vt="기본 모델은 다음 토큰을 예측하기 위해 대량의 원시 텍스트 데이터로 학습되는 반면, 지시 모델은 특정 지시를 따르고 대화를 나눌 수 있도록 미세 조정된 모델입니다. 예를 들어, <code>SmolLM2-135M</code>은 기본 모델이고, <code>SmolLM2-135M-Instruct</code>는 이를 지시 조정한 변형 모델입니다.",it,$,xt="기본 모델이 지시 모델처럼 동작하도록 만들기 위해서는 모델이 이해할 수 있는 방식으로 프롬프트를 일관되게 만들어야 합니다. 이때 대화 템플릿이 유용합니다. ChatML은 이러한 템플릿 형식 중 하나로 대화를 구조화하고 명확한 역할 지시자(시스템, 사용자, 어시스턴트)를 제공합니다.",Mt,w,Et="기본 모델은 서로 다른 대화 템플릿으로 미세 조정될 수 있으므로, 지시 모델을 사용할 때는 반드시 해당 모델에 적합한 대화 템플릿을 사용하는 것이 중요합니다.",pt,C,Jt,d,Xt="대화 템플릿의 핵심은 언어 모델과 소통할 때 대화가 어떤 형식으로 이루어져야 하는지 정의하는 것입니다. 템플릿에는 시스템 수준의 지침, 사용자 메시지, 어시스턴트의 응답이 포함되어 있으며, 모델이 이해할 수 있는 구조화된 형식을 제공합니다. 이러한 구조는 상호작용의 일관성을 유지하고, 모델이 다양한 유형의 입력에 적절히 응답하도록 돕습니다. 아래는 채팅 템플릿의 예시입니다:",ot,q,ut,b,At='<code>transformers</code> 라이브러리는 모델의 토크나이저와 관련하여 대화 템플릿을 자동으로 처리해줍니다. 대화 템플릿이 transformers에서 어떻게 구성되는지 자세히 알아보려면 <a href="https://huggingface.co/docs/transformers/en/chat_templating#how-do-i-use-chat-templates" rel="nofollow">여기</a>를 참고하세요. 우리가 메시지를 올바른 형식으로 구조화하기만 하면 나머지는 토크나이저가 처리합니다. 아래는 기본적인 대화 예시입니다:',yt,N,Tt,V,_t="위 예시를 자세히 보면서 대화 템플릿 형식에 어떻게 매핑되는지 살펴봅시다.",Ut,Q,mt,B,Rt="시스템 메시지는 모델의 기본 동작 방식을 설정합니다. 이는 이후 모든 상호작용에 영향을 미치는 지속적인 지침이 됩니다.",rt,G,jt,S,ct,Z,kt="대화 템플릿은 대화 기록을 통해 맥락을 유지하며, 사용자와 어시스턴트 간의 이전 대화를 저장합니다. 이를 통해 더욱 일관된 멀티 턴 대화가 가능해집니다:",ft,z,gt,v,ht,x,Yt="transformers 라이브러리는 대화 템플릿을 위한 내장 기능을 지원합니다.사용 방법은 다음과 같습니다:",It,E,$t,X,wt,A,Wt="메시지 유형별로 원하는 형식을 설정할 수 있습니다. 예를 들어, 역할에 따라 특수 토큰을 추가하거나 형식을 지정할 수 있습니다:",Ct,_,dt,R,qt,k,Ft="템플릿은 문맥을 유지하면서 복잡한 멀티 턴 대화도 처리할 수 있습니다:",bt,Y,Nt,W,Dt='⏭️ <a href="./supervised_fine_tuning.md">다음: Supervised Fine-Tuning</a>',Vt,F,Qt,D,Ht='<li><a href="https://huggingface.co/docs/transformers/main/en/chat_templating" rel="nofollow">Hugging Face Chat Templating Guide</a></li> <li><a href="https://huggingface.co/docs/transformers" rel="nofollow">Transformers Documentation</a></li> <li><a href="https://github.com/chujiezheng/chat_templates" rel="nofollow">Chat Templates Examples Repository</a></li>',Bt,H,Gt,O,St;return j=new al({props:{containerStyle:"float: right; margin-left: 10px; display: inline-flex; position: relative; z-index: 10;"}}),c=new r({props:{title:"대화 템플릿(Chat Templates)",local:"대화-템플릿chat-templates",headingTag:"h1"}}),f=new Ml({props:{chapter:10,classNames:"absolute z-10 right-0 top-0",notebooks:[{label:"Google Colab",value:"https://colab.research.google.com/github/huggingface/smol-course/blob/main/notebooks/ko/1_instruction_tuning/chat_templates_example.ipynb"}]}}),h=new r({props:{title:"기본 모델 vs 지시 모델",local:"기본-모델-vs-지시-모델",headingTag:"h2"}}),C=new r({props:{title:"대화 템플릿 이해하기",local:"대화-템플릿-이해하기",headingTag:"h2"}}),q=new L({props:{code:"JTNDJTdDaW1fc3RhcnQlN0MlM0V1c2VyJTBBJUVDJTk1JTg4JUVCJTg1JTk1JUVEJTk1JTk4JUVDJTg0JUI4JUVDJTlBJTk0ISUzQyU3Q2ltX2VuZCU3QyUzRSUwQSUzQyU3Q2ltX3N0YXJ0JTdDJTNFYXNzaXN0YW50JTBBJUVCJUE3JThDJUVCJTgyJTk4JUVDJTg0JTlDJTIwJUVCJUIwJTk4JUVBJUIwJTkxJUVDJThBJUI1JUVCJThCJTg4JUVCJThCJUE0ISUzQyU3Q2ltX2VuZCU3QyUzRSUwQSUzQyU3Q2ltX3N0YXJ0JTdDJTNFdXNlciUwQSVFQyVBNyU4OCVFQiVBQyVCOCVFQyU5RCU4NCUyMCVFRCU5NSVCNCVFQiU4RiU4NCUyMCVFQiU5MCVBMCVFQSVCOSU4QyVFQyU5QSU5NCUzRiUzQyU3Q2ltX2VuZCU3QyUzRSUwQSUzQyU3Q2ltX3N0YXJ0JTdDJTNFYXNzaXN0YW50",highlighted:`&lt;|im_start|&gt;user
안녕하세요!&lt;|im_end|&gt;
&lt;|im_start|&gt;assistant
만나서 반갑습니다!&lt;|im_end|&gt;
&lt;|im_start|&gt;user
질문을 해도 될까요?&lt;|im_end|&gt;
&lt;|im_start|&gt;assistant`,wrap:!1}}),N=new L({props:{code:"bWVzc2FnZXMlMjAlM0QlMjAlNUIlMEElMjAlMjAlMjAlMjAlN0IlMjJyb2xlJTIyJTNBJTIwJTIyc3lzdGVtJTIyJTJDJTIwJTIyY29udGVudCUyMiUzQSUyMCUyMllvdSUyMGFyZSUyMGElMjBoZWxwZnVsJTIwYXNzaXN0YW50JTIwZm9jdXNlZCUyMG9uJTIwdGVjaG5pY2FsJTIwdG9waWNzLiUyMiU3RCUyQyUwQSUyMCUyMCUyMCUyMCU3QiUyMnJvbGUlMjIlM0ElMjAlMjJ1c2VyJTIyJTJDJTIwJTIyY29udGVudCUyMiUzQSUyMCUyMkNhbiUyMHlvdSUyMGV4cGxhaW4lMjB3aGF0JTIwYSUyMGNoYXQlMjB0ZW1wbGF0ZSUyMGlzJTNGJTIyJTdEJTJDJTBBJTIwJTIwJTIwJTIwJTdCJTIycm9sZSUyMiUzQSUyMCUyMmFzc2lzdGFudCUyMiUyQyUyMCUyMmNvbnRlbnQlMjIlM0ElMjAlMjJBJTIwY2hhdCUyMHRlbXBsYXRlJTIwc3RydWN0dXJlcyUyMGNvbnZlcnNhdGlvbnMlMjBiZXR3ZWVuJTIwdXNlcnMlMjBhbmQlMjBBSSUyMG1vZGVscy4uLiUyMiU3RCUwQSU1RA==",highlighted:`messages = [
    {<span class="hljs-string">&quot;role&quot;</span>: <span class="hljs-string">&quot;system&quot;</span>, <span class="hljs-string">&quot;content&quot;</span>: <span class="hljs-string">&quot;You are a helpful assistant focused on technical topics.&quot;</span>},
    {<span class="hljs-string">&quot;role&quot;</span>: <span class="hljs-string">&quot;user&quot;</span>, <span class="hljs-string">&quot;content&quot;</span>: <span class="hljs-string">&quot;Can you explain what a chat template is?&quot;</span>},
    {<span class="hljs-string">&quot;role&quot;</span>: <span class="hljs-string">&quot;assistant&quot;</span>, <span class="hljs-string">&quot;content&quot;</span>: <span class="hljs-string">&quot;A chat template structures conversations between users and AI models...&quot;</span>}
]`,wrap:!1}}),Q=new r({props:{title:"시스템 메시지",local:"시스템-메시지",headingTag:"h2"}}),G=new L({props:{code:"c3lzdGVtX21lc3NhZ2UlMjAlM0QlMjAlN0IlMEElMjAlMjAlMjAlMjAlMjJyb2xlJTIyJTNBJTIwJTIyc3lzdGVtJTIyJTJDJTBBJTIwJTIwJTIwJTIwJTIyY29udGVudCUyMiUzQSUyMCUyMllvdSUyMGFyZSUyMGElMjBwcm9mZXNzaW9uYWwlMjBjdXN0b21lciUyMHNlcnZpY2UlMjBhZ2VudC4lMjBBbHdheXMlMjBiZSUyMHBvbGl0ZSUyQyUyMGNsZWFyJTJDJTIwYW5kJTIwaGVscGZ1bC4lMjIlMEElN0Q=",highlighted:`system_message = {
    <span class="hljs-string">&quot;role&quot;</span>: <span class="hljs-string">&quot;system&quot;</span>,
    <span class="hljs-string">&quot;content&quot;</span>: <span class="hljs-string">&quot;You are a professional customer service agent. Always be polite, clear, and helpful.&quot;</span>
}`,wrap:!1}}),S=new r({props:{title:"대화",local:"대화",headingTag:"h2"}}),z=new L({props:{code:"Y29udmVyc2F0aW9uJTIwJTNEJTIwJTVCJTBBJTIwJTIwJTIwJTIwJTdCJTIycm9sZSUyMiUzQSUyMCUyMnVzZXIlMjIlMkMlMjAlMjJjb250ZW50JTIyJTNBJTIwJTIySSUyMG5lZWQlMjBoZWxwJTIwd2l0aCUyMG15JTIwb3JkZXIlMjIlN0QlMkMlMEElMjAlMjAlMjAlMjAlN0IlMjJyb2xlJTIyJTNBJTIwJTIyYXNzaXN0YW50JTIyJTJDJTIwJTIyY29udGVudCUyMiUzQSUyMCUyMkknZCUyMGJlJTIwaGFwcHklMjB0byUyMGhlbHAuJTIwQ291bGQlMjB5b3UlMjBwcm92aWRlJTIweW91ciUyMG9yZGVyJTIwbnVtYmVyJTNGJTIyJTdEJTJDJTBBJTIwJTIwJTIwJTIwJTdCJTIycm9sZSUyMiUzQSUyMCUyMnVzZXIlMjIlMkMlMjAlMjJjb250ZW50JTIyJTNBJTIwJTIySXQncyUyME9SREVSLTEyMyUyMiU3RCUyQyUwQSU1RA==",highlighted:`conversation = [
    {<span class="hljs-string">&quot;role&quot;</span>: <span class="hljs-string">&quot;user&quot;</span>, <span class="hljs-string">&quot;content&quot;</span>: <span class="hljs-string">&quot;I need help with my order&quot;</span>},
    {<span class="hljs-string">&quot;role&quot;</span>: <span class="hljs-string">&quot;assistant&quot;</span>, <span class="hljs-string">&quot;content&quot;</span>: <span class="hljs-string">&quot;I&#x27;d be happy to help. Could you provide your order number?&quot;</span>},
    {<span class="hljs-string">&quot;role&quot;</span>: <span class="hljs-string">&quot;user&quot;</span>, <span class="hljs-string">&quot;content&quot;</span>: <span class="hljs-string">&quot;It&#x27;s ORDER-123&quot;</span>},
]`,wrap:!1}}),v=new r({props:{title:"Transformers 기반 구현",local:"transformers-기반-구현",headingTag:"h2"}}),E=new L({props:{code:"ZnJvbSUyMHRyYW5zZm9ybWVycyUyMGltcG9ydCUyMEF1dG9Ub2tlbml6ZXIlMEElMEF0b2tlbml6ZXIlMjAlM0QlMjBBdXRvVG9rZW5pemVyLmZyb21fcHJldHJhaW5lZCglMjJIdWdnaW5nRmFjZVRCJTJGU21vbExNMi0xMzVNLUluc3RydWN0JTIyKSUwQSUwQW1lc3NhZ2VzJTIwJTNEJTIwJTVCJTBBJTIwJTIwJTIwJTIwJTdCJTIycm9sZSUyMiUzQSUyMCUyMnN5c3RlbSUyMiUyQyUyMCUyMmNvbnRlbnQlMjIlM0ElMjAlMjJZb3UlMjBhcmUlMjBhJTIwaGVscGZ1bCUyMGNvZGluZyUyMGFzc2lzdGFudC4lMjIlN0QlMkMlMEElMjAlMjAlMjAlMjAlN0IlMjJyb2xlJTIyJTNBJTIwJTIydXNlciUyMiUyQyUyMCUyMmNvbnRlbnQlMjIlM0ElMjAlMjJXcml0ZSUyMGElMjBQeXRob24lMjBmdW5jdGlvbiUyMHRvJTIwc29ydCUyMGElMjBsaXN0JTIyJTdEJTJDJTBBJTVEJTBBJTBBJTIzJTIwJUVCJThDJTgwJUVEJTk5JTk0JTIwJUVEJTg1JTlDJUVEJTk0JThDJUVCJUE2JUJGJTIwJUVDJUEwJTgxJUVDJTlBJUE5JTBBZm9ybWF0dGVkX2NoYXQlMjAlM0QlMjB0b2tlbml6ZXIuYXBwbHlfY2hhdF90ZW1wbGF0ZSglMEElMjAlMjAlMjAlMjBtZXNzYWdlcyUyQyUwQSUyMCUyMCUyMCUyMHRva2VuaXplJTNERmFsc2UlMkMlMEElMjAlMjAlMjAlMjBhZGRfZ2VuZXJhdGlvbl9wcm9tcHQlM0RUcnVlJTBBKQ==",highlighted:`<span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer

tokenizer = AutoTokenizer.from_pretrained(<span class="hljs-string">&quot;HuggingFaceTB/SmolLM2-135M-Instruct&quot;</span>)

messages = [
    {<span class="hljs-string">&quot;role&quot;</span>: <span class="hljs-string">&quot;system&quot;</span>, <span class="hljs-string">&quot;content&quot;</span>: <span class="hljs-string">&quot;You are a helpful coding assistant.&quot;</span>},
    {<span class="hljs-string">&quot;role&quot;</span>: <span class="hljs-string">&quot;user&quot;</span>, <span class="hljs-string">&quot;content&quot;</span>: <span class="hljs-string">&quot;Write a Python function to sort a list&quot;</span>},
]

<span class="hljs-comment"># 대화 템플릿 적용</span>
formatted_chat = tokenizer.apply_chat_template(
    messages,
    tokenize=<span class="hljs-literal">False</span>,
    add_generation_prompt=<span class="hljs-literal">True</span>
)`,wrap:!1}}),X=new r({props:{title:"사용자 정의 형식",local:"사용자-정의-형식",headingTag:"h2"}}),_=new L({props:{code:"dGVtcGxhdGUlMjAlM0QlMjAlMjIlMjIlMjIlMEElM0MlN0NzeXN0ZW0lN0MlM0UlN0JzeXN0ZW1fbWVzc2FnZSU3RCUwQSUzQyU3Q3VzZXIlN0MlM0UlN0J1c2VyX21lc3NhZ2UlN0QlMEElM0MlN0Nhc3Npc3RhbnQlN0MlM0UlN0Jhc3Npc3RhbnRfbWVzc2FnZSU3RCUwQSUyMiUyMiUyMi5sc3RyaXAoKQ==",highlighted:`template = <span class="hljs-string">&quot;&quot;&quot;
&lt;|system|&gt;{system_message}
&lt;|user|&gt;{user_message}
&lt;|assistant|&gt;{assistant_message}
&quot;&quot;&quot;</span>.lstrip()`,wrap:!1}}),R=new r({props:{title:"멀티 턴 지원",local:"멀티-턴-지원",headingTag:"h2"}}),Y=new L({props:{code:"bWVzc2FnZXMlMjAlM0QlMjAlNUIlMEElMjAlMjAlMjAlMjAlN0IlMjJyb2xlJTIyJTNBJTIwJTIyc3lzdGVtJTIyJTJDJTIwJTIyY29udGVudCUyMiUzQSUyMCUyMllvdSUyMGFyZSUyMGElMjBtYXRoJTIwdHV0b3IuJTIyJTdEJTJDJTBBJTIwJTIwJTIwJTIwJTdCJTIycm9sZSUyMiUzQSUyMCUyMnVzZXIlMjIlMkMlMjAlMjJjb250ZW50JTIyJTNBJTIwJTIyV2hhdCUyMGlzJTIwY2FsY3VsdXMlM0YlMjIlN0QlMkMlMEElMjAlMjAlMjAlMjAlN0IlMjJyb2xlJTIyJTNBJTIwJTIyYXNzaXN0YW50JTIyJTJDJTIwJTIyY29udGVudCUyMiUzQSUyMCUyMkNhbGN1bHVzJTIwaXMlMjBhJTIwYnJhbmNoJTIwb2YlMjBtYXRoZW1hdGljcy4uLiUyMiU3RCUyQyUwQSUyMCUyMCUyMCUyMCU3QiUyMnJvbGUlMjIlM0ElMjAlMjJ1c2VyJTIyJTJDJTIwJTIyY29udGVudCUyMiUzQSUyMCUyMkNhbiUyMHlvdSUyMGdpdmUlMjBtZSUyMGFuJTIwZXhhbXBsZSUzRiUyMiU3RCUyQyUwQSU1RA==",highlighted:`messages = [
    {<span class="hljs-string">&quot;role&quot;</span>: <span class="hljs-string">&quot;system&quot;</span>, <span class="hljs-string">&quot;content&quot;</span>: <span class="hljs-string">&quot;You are a math tutor.&quot;</span>},
    {<span class="hljs-string">&quot;role&quot;</span>: <span class="hljs-string">&quot;user&quot;</span>, <span class="hljs-string">&quot;content&quot;</span>: <span class="hljs-string">&quot;What is calculus?&quot;</span>},
    {<span class="hljs-string">&quot;role&quot;</span>: <span class="hljs-string">&quot;assistant&quot;</span>, <span class="hljs-string">&quot;content&quot;</span>: <span class="hljs-string">&quot;Calculus is a branch of mathematics...&quot;</span>},
    {<span class="hljs-string">&quot;role&quot;</span>: <span class="hljs-string">&quot;user&quot;</span>, <span class="hljs-string">&quot;content&quot;</span>: <span class="hljs-string">&quot;Can you give me an example?&quot;</span>},
]`,wrap:!1}}),F=new r({props:{title:"참고",local:"참고",headingTag:"h2"}}),H=new il({props:{source:"https://github.com/huggingface/smol-course/blob/main/units/ko/unit1/2.md"}}),{c(){m=y("meta"),K=n(),P=y("p"),tt=n(),i(j.$$.fragment),lt=n(),i(c.$$.fragment),st=n(),i(f.$$.fragment),et=n(),g=y("p"),g.textContent=zt,nt=n(),i(h.$$.fragment),at=n(),I=y("p"),I.innerHTML=vt,it=n(),$=y("p"),$.textContent=xt,Mt=n(),w=y("p"),w.textContent=Et,pt=n(),i(C.$$.fragment),Jt=n(),d=y("p"),d.textContent=Xt,ot=n(),i(q.$$.fragment),ut=n(),b=y("p"),b.innerHTML=At,yt=n(),i(N.$$.fragment),Tt=n(),V=y("p"),V.textContent=_t,Ut=n(),i(Q.$$.fragment),mt=n(),B=y("p"),B.textContent=Rt,rt=n(),i(G.$$.fragment),jt=n(),i(S.$$.fragment),ct=n(),Z=y("p"),Z.textContent=kt,ft=n(),i(z.$$.fragment),gt=n(),i(v.$$.fragment),ht=n(),x=y("p"),x.textContent=Yt,It=n(),i(E.$$.fragment),$t=n(),i(X.$$.fragment),wt=n(),A=y("p"),A.textContent=Wt,Ct=n(),i(_.$$.fragment),dt=n(),i(R.$$.fragment),qt=n(),k=y("p"),k.textContent=Ft,bt=n(),i(Y.$$.fragment),Nt=n(),W=y("p"),W.innerHTML=Dt,Vt=n(),i(F.$$.fragment),Qt=n(),D=y("ul"),D.innerHTML=Ht,Bt=n(),i(H.$$.fragment),Gt=n(),O=y("p"),this.h()},l(t){const l=el("svelte-u9bgzb",document.head);m=T(l,"META",{name:!0,content:!0}),l.forEach(s),K=a(t),P=T(t,"P",{}),Lt(P).forEach(s),tt=a(t),M(j.$$.fragment,t),lt=a(t),M(c.$$.fragment,t),st=a(t),M(f.$$.fragment,t),et=a(t),g=T(t,"P",{"data-svelte-h":!0}),U(g)!=="svelte-1nb11f0"&&(g.textContent=zt),nt=a(t),M(h.$$.fragment,t),at=a(t),I=T(t,"P",{"data-svelte-h":!0}),U(I)!=="svelte-1gez13w"&&(I.innerHTML=vt),it=a(t),$=T(t,"P",{"data-svelte-h":!0}),U($)!=="svelte-imzj7x"&&($.textContent=xt),Mt=a(t),w=T(t,"P",{"data-svelte-h":!0}),U(w)!=="svelte-4m2whd"&&(w.textContent=Et),pt=a(t),M(C.$$.fragment,t),Jt=a(t),d=T(t,"P",{"data-svelte-h":!0}),U(d)!=="svelte-1h8ildj"&&(d.textContent=Xt),ot=a(t),M(q.$$.fragment,t),ut=a(t),b=T(t,"P",{"data-svelte-h":!0}),U(b)!=="svelte-grtmou"&&(b.innerHTML=At),yt=a(t),M(N.$$.fragment,t),Tt=a(t),V=T(t,"P",{"data-svelte-h":!0}),U(V)!=="svelte-k4uyxc"&&(V.textContent=_t),Ut=a(t),M(Q.$$.fragment,t),mt=a(t),B=T(t,"P",{"data-svelte-h":!0}),U(B)!=="svelte-ftcw56"&&(B.textContent=Rt),rt=a(t),M(G.$$.fragment,t),jt=a(t),M(S.$$.fragment,t),ct=a(t),Z=T(t,"P",{"data-svelte-h":!0}),U(Z)!=="svelte-1nj4j94"&&(Z.textContent=kt),ft=a(t),M(z.$$.fragment,t),gt=a(t),M(v.$$.fragment,t),ht=a(t),x=T(t,"P",{"data-svelte-h":!0}),U(x)!=="svelte-1fho30b"&&(x.textContent=Yt),It=a(t),M(E.$$.fragment,t),$t=a(t),M(X.$$.fragment,t),wt=a(t),A=T(t,"P",{"data-svelte-h":!0}),U(A)!=="svelte-15ndmaz"&&(A.textContent=Wt),Ct=a(t),M(_.$$.fragment,t),dt=a(t),M(R.$$.fragment,t),qt=a(t),k=T(t,"P",{"data-svelte-h":!0}),U(k)!=="svelte-1tnxylv"&&(k.textContent=Ft),bt=a(t),M(Y.$$.fragment,t),Nt=a(t),W=T(t,"P",{"data-svelte-h":!0}),U(W)!=="svelte-y9d81k"&&(W.innerHTML=Dt),Vt=a(t),M(F.$$.fragment,t),Qt=a(t),D=T(t,"UL",{"data-svelte-h":!0}),U(D)!=="svelte-1xxwjgh"&&(D.innerHTML=Ht),Bt=a(t),M(H.$$.fragment,t),Gt=a(t),O=T(t,"P",{}),Lt(O).forEach(s),this.h()},h(){Pt(m,"name","hf:doc:metadata"),Pt(m,"content",Jl)},m(t,l){nl(document.head,m),e(t,K,l),e(t,P,l),e(t,tt,l),p(j,t,l),e(t,lt,l),p(c,t,l),e(t,st,l),p(f,t,l),e(t,et,l),e(t,g,l),e(t,nt,l),p(h,t,l),e(t,at,l),e(t,I,l),e(t,it,l),e(t,$,l),e(t,Mt,l),e(t,w,l),e(t,pt,l),p(C,t,l),e(t,Jt,l),e(t,d,l),e(t,ot,l),p(q,t,l),e(t,ut,l),e(t,b,l),e(t,yt,l),p(N,t,l),e(t,Tt,l),e(t,V,l),e(t,Ut,l),p(Q,t,l),e(t,mt,l),e(t,B,l),e(t,rt,l),p(G,t,l),e(t,jt,l),p(S,t,l),e(t,ct,l),e(t,Z,l),e(t,ft,l),p(z,t,l),e(t,gt,l),p(v,t,l),e(t,ht,l),e(t,x,l),e(t,It,l),p(E,t,l),e(t,$t,l),p(X,t,l),e(t,wt,l),e(t,A,l),e(t,Ct,l),p(_,t,l),e(t,dt,l),p(R,t,l),e(t,qt,l),e(t,k,l),e(t,bt,l),p(Y,t,l),e(t,Nt,l),e(t,W,l),e(t,Vt,l),p(F,t,l),e(t,Qt,l),e(t,D,l),e(t,Bt,l),p(H,t,l),e(t,Gt,l),e(t,O,l),St=!0},p:Kt,i(t){St||(J(j.$$.fragment,t),J(c.$$.fragment,t),J(f.$$.fragment,t),J(h.$$.fragment,t),J(C.$$.fragment,t),J(q.$$.fragment,t),J(N.$$.fragment,t),J(Q.$$.fragment,t),J(G.$$.fragment,t),J(S.$$.fragment,t),J(z.$$.fragment,t),J(v.$$.fragment,t),J(E.$$.fragment,t),J(X.$$.fragment,t),J(_.$$.fragment,t),J(R.$$.fragment,t),J(Y.$$.fragment,t),J(F.$$.fragment,t),J(H.$$.fragment,t),St=!0)},o(t){o(j.$$.fragment,t),o(c.$$.fragment,t),o(f.$$.fragment,t),o(h.$$.fragment,t),o(C.$$.fragment,t),o(q.$$.fragment,t),o(N.$$.fragment,t),o(Q.$$.fragment,t),o(G.$$.fragment,t),o(S.$$.fragment,t),o(z.$$.fragment,t),o(v.$$.fragment,t),o(E.$$.fragment,t),o(X.$$.fragment,t),o(_.$$.fragment,t),o(R.$$.fragment,t),o(Y.$$.fragment,t),o(F.$$.fragment,t),o(H.$$.fragment,t),St=!1},d(t){t&&(s(K),s(P),s(tt),s(lt),s(st),s(et),s(g),s(nt),s(at),s(I),s(it),s($),s(Mt),s(w),s(pt),s(Jt),s(d),s(ot),s(ut),s(b),s(yt),s(Tt),s(V),s(Ut),s(mt),s(B),s(rt),s(jt),s(ct),s(Z),s(ft),s(gt),s(ht),s(x),s(It),s($t),s(wt),s(A),s(Ct),s(dt),s(qt),s(k),s(bt),s(Nt),s(W),s(Vt),s(Qt),s(D),s(Bt),s(Gt),s(O)),s(m),u(j,t),u(c,t),u(f,t),u(h,t),u(C,t),u(q,t),u(N,t),u(Q,t),u(G,t),u(S,t),u(z,t),u(v,t),u(E,t),u(X,t),u(_,t),u(R,t),u(Y,t),u(F,t),u(H,t)}}}const Jl='{"title":"대화 템플릿(Chat Templates)","local":"대화-템플릿chat-templates","sections":[{"title":"기본 모델 vs 지시 모델","local":"기본-모델-vs-지시-모델","sections":[],"depth":2},{"title":"대화 템플릿 이해하기","local":"대화-템플릿-이해하기","sections":[],"depth":2},{"title":"시스템 메시지","local":"시스템-메시지","sections":[],"depth":2},{"title":"대화","local":"대화","sections":[],"depth":2},{"title":"Transformers 기반 구현","local":"transformers-기반-구현","sections":[],"depth":2},{"title":"사용자 정의 형식","local":"사용자-정의-형식","sections":[],"depth":2},{"title":"멀티 턴 지원","local":"멀티-턴-지원","sections":[],"depth":2},{"title":"참고","local":"참고","sections":[],"depth":2}],"depth":1}';function ol(Zt){return tl(()=>{new URLSearchParams(window.location.search).get("fw")}),[]}class rl extends ll{constructor(m){super(),sl(this,m,ol,pl,Ot,{})}}export{rl as component};
