import{S as jf,i as Pf,s as Sf,e as n,k as p,w as v,t as i,M as Af,c as s,d as o,m as h,a,x as T,h as l,b as m,G as e,g as _,y,q as w,o as $,B as E,v as Lf,L as G}from"../../chunks/vendor-hf-doc-builder.js";import{T as Be}from"../../chunks/Tip-hf-doc-builder.js";import{D as z}from"../../chunks/Docstring-hf-doc-builder.js";import{C as J}from"../../chunks/CodeBlock-hf-doc-builder.js";import{I as B}from"../../chunks/IconCopyLink-hf-doc-builder.js";import{E as Z}from"../../chunks/ExampleCodeBlock-hf-doc-builder.js";function Nf(F){let d,k,c,u,b;return u=new J({props:{code:`from transformers import EsmModel, EsmConfig

# Initializing a ESM facebook/esm-1b style configuration >>> configuration = EsmConfig()

# Initializing a model from the configuration >>> model = ESMModel(configuration)

# Accessing the model configuration >>> configuration = model.config`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> EsmModel, EsmConfig

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># Initializing a ESM facebook/esm-1b style configuration &gt;&gt;&gt; configuration = EsmConfig()</span>

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># Initializing a model from the configuration &gt;&gt;&gt; model = ESMModel(configuration)</span>

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># Accessing the model configuration &gt;&gt;&gt; configuration = model.config</span>`}}),{c(){d=n("p"),k=i("Examples:"),c=p(),v(u.$$.fragment)},l(r){d=s(r,"P",{});var f=a(d);k=l(f,"Examples:"),f.forEach(o),c=h(r),T(u.$$.fragment,r)},m(r,f){_(r,d,f),e(d,k),_(r,c,f),y(u,r,f),b=!0},p:G,i(r){b||(w(u.$$.fragment,r),b=!0)},o(r){$(u.$$.fragment,r),b=!1},d(r){r&&o(d),r&&o(c),E(u,r)}}}function Df(F){let d,k,c,u,b;return{c(){d=n("p"),k=i("Although the recipe for forward pass needs to be defined within this function, one should call the "),c=n("code"),u=i("Module"),b=i(`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`)},l(r){d=s(r,"P",{});var f=a(d);k=l(f,"Although the recipe for forward pass needs to be defined within this function, one should call the "),c=s(f,"CODE",{});var M=a(c);u=l(M,"Module"),M.forEach(o),b=l(f,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),f.forEach(o)},m(r,f){_(r,d,f),e(d,k),e(d,c),e(c,u),e(d,b)},d(r){r&&o(d)}}}function Of(F){let d,k,c,u,b;return u=new J({props:{code:`from transformers import AutoTokenizer, EsmModel
import torch

tokenizer = AutoTokenizer.from_pretrained("facebook/esm2_t6_8M_UR50D")
model = EsmModel.from_pretrained("facebook/esm2_t6_8M_UR50D")

inputs = tokenizer("Hello, my dog is cute", return_tensors="pt")
outputs = model(**inputs)

last_hidden_states = outputs.last_hidden_state`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, EsmModel
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">import</span> torch

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.from_pretrained(<span class="hljs-string">&quot;facebook/esm2_t6_8M_UR50D&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = EsmModel.from_pretrained(<span class="hljs-string">&quot;facebook/esm2_t6_8M_UR50D&quot;</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span>inputs = tokenizer(<span class="hljs-string">&quot;Hello, my dog is cute&quot;</span>, return_tensors=<span class="hljs-string">&quot;pt&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>outputs = model(**inputs)

<span class="hljs-meta">&gt;&gt;&gt; </span>last_hidden_states = outputs.last_hidden_state`}}),{c(){d=n("p"),k=i("Example:"),c=p(),v(u.$$.fragment)},l(r){d=s(r,"P",{});var f=a(d);k=l(f,"Example:"),f.forEach(o),c=h(r),T(u.$$.fragment,r)},m(r,f){_(r,d,f),e(d,k),_(r,c,f),y(u,r,f),b=!0},p:G,i(r){b||(w(u.$$.fragment,r),b=!0)},o(r){$(u.$$.fragment,r),b=!1},d(r){r&&o(d),r&&o(c),E(u,r)}}}function If(F){let d,k,c,u,b;return{c(){d=n("p"),k=i("Although the recipe for forward pass needs to be defined within this function, one should call the "),c=n("code"),u=i("Module"),b=i(`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`)},l(r){d=s(r,"P",{});var f=a(d);k=l(f,"Although the recipe for forward pass needs to be defined within this function, one should call the "),c=s(f,"CODE",{});var M=a(c);u=l(M,"Module"),M.forEach(o),b=l(f,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),f.forEach(o)},m(r,f){_(r,d,f),e(d,k),e(d,c),e(c,u),e(d,b)},d(r){r&&o(d)}}}function Uf(F){let d,k,c,u,b;return u=new J({props:{code:`from transformers import AutoTokenizer, EsmForMaskedLM
import torch

tokenizer = AutoTokenizer.from_pretrained("facebook/esm2_t6_8M_UR50D")
model = EsmForMaskedLM.from_pretrained("facebook/esm2_t6_8M_UR50D")

inputs = tokenizer("The capital of France is <mask>.", return_tensors="pt")

with torch.no_grad():
    logits = model(**inputs).logits

# retrieve index of <mask>
mask_token_index = (inputs.input_ids == tokenizer.mask_token_id)[0].nonzero(as_tuple=True)[0]

predicted_token_id = logits[0, mask_token_index].argmax(axis=-1)

labels = tokenizer("The capital of France is Paris.", return_tensors="pt")["input_ids"]
# mask labels of non-<mask> tokens
labels = torch.where(inputs.input_ids == tokenizer.mask_token_id, labels, -100)

outputs = model(**inputs, labels=labels)`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, EsmForMaskedLM
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">import</span> torch

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.from_pretrained(<span class="hljs-string">&quot;facebook/esm2_t6_8M_UR50D&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = EsmForMaskedLM.from_pretrained(<span class="hljs-string">&quot;facebook/esm2_t6_8M_UR50D&quot;</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span>inputs = tokenizer(<span class="hljs-string">&quot;The capital of France is &lt;mask&gt;.&quot;</span>, return_tensors=<span class="hljs-string">&quot;pt&quot;</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">with</span> torch.no_grad():
<span class="hljs-meta">... </span>    logits = model(**inputs).logits

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># retrieve index of &lt;mask&gt;</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>mask_token_index = (inputs.input_ids == tokenizer.mask_token_id)[<span class="hljs-number">0</span>].nonzero(as_tuple=<span class="hljs-literal">True</span>)[<span class="hljs-number">0</span>]

<span class="hljs-meta">&gt;&gt;&gt; </span>predicted_token_id = logits[<span class="hljs-number">0</span>, mask_token_index].argmax(axis=-<span class="hljs-number">1</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span>labels = tokenizer(<span class="hljs-string">&quot;The capital of France is Paris.&quot;</span>, return_tensors=<span class="hljs-string">&quot;pt&quot;</span>)[<span class="hljs-string">&quot;input_ids&quot;</span>]
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># mask labels of non-&lt;mask&gt; tokens</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>labels = torch.where(inputs.input_ids == tokenizer.mask_token_id, labels, -<span class="hljs-number">100</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span>outputs = model(**inputs, labels=labels)`}}),{c(){d=n("p"),k=i("Example:"),c=p(),v(u.$$.fragment)},l(r){d=s(r,"P",{});var f=a(d);k=l(f,"Example:"),f.forEach(o),c=h(r),T(u.$$.fragment,r)},m(r,f){_(r,d,f),e(d,k),_(r,c,f),y(u,r,f),b=!0},p:G,i(r){b||(w(u.$$.fragment,r),b=!0)},o(r){$(u.$$.fragment,r),b=!1},d(r){r&&o(d),r&&o(c),E(u,r)}}}function Rf(F){let d,k,c,u,b;return{c(){d=n("p"),k=i("Although the recipe for forward pass needs to be defined within this function, one should call the "),c=n("code"),u=i("Module"),b=i(`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`)},l(r){d=s(r,"P",{});var f=a(d);k=l(f,"Although the recipe for forward pass needs to be defined within this function, one should call the "),c=s(f,"CODE",{});var M=a(c);u=l(M,"Module"),M.forEach(o),b=l(f,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),f.forEach(o)},m(r,f){_(r,d,f),e(d,k),e(d,c),e(c,u),e(d,b)},d(r){r&&o(d)}}}function Wf(F){let d,k,c,u,b;return u=new J({props:{code:`import torch
from transformers import AutoTokenizer, EsmForSequenceClassification

tokenizer = AutoTokenizer.from_pretrained("facebook/esm2_t6_8M_UR50D")
model = EsmForSequenceClassification.from_pretrained("facebook/esm2_t6_8M_UR50D")

inputs = tokenizer("Hello, my dog is cute", return_tensors="pt")

with torch.no_grad():
    logits = model(**inputs).logits

predicted_class_id = logits.argmax().item()

# To train a model on \`num_labels\` classes, you can pass \`num_labels=num_labels\` to \`.from_pretrained(...)\`
num_labels = len(model.config.id2label)
model = EsmForSequenceClassification.from_pretrained("facebook/esm2_t6_8M_UR50D", num_labels=num_labels)

labels = torch.tensor([1])
loss = model(**inputs, labels=labels).loss`,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> AutoTokenizer, EsmForSequenceClassification

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.from_pretrained(<span class="hljs-string">&quot;facebook/esm2_t6_8M_UR50D&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = EsmForSequenceClassification.from_pretrained(<span class="hljs-string">&quot;facebook/esm2_t6_8M_UR50D&quot;</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span>inputs = tokenizer(<span class="hljs-string">&quot;Hello, my dog is cute&quot;</span>, return_tensors=<span class="hljs-string">&quot;pt&quot;</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">with</span> torch.no_grad():
<span class="hljs-meta">... </span>    logits = model(**inputs).logits

<span class="hljs-meta">&gt;&gt;&gt; </span>predicted_class_id = logits.argmax().item()

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># To train a model on \`num_labels\` classes, you can pass \`num_labels=num_labels\` to \`.from_pretrained(...)\`</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>num_labels = <span class="hljs-built_in">len</span>(model.config.id2label)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = EsmForSequenceClassification.from_pretrained(<span class="hljs-string">&quot;facebook/esm2_t6_8M_UR50D&quot;</span>, num_labels=num_labels)

<span class="hljs-meta">&gt;&gt;&gt; </span>labels = torch.tensor([<span class="hljs-number">1</span>])
<span class="hljs-meta">&gt;&gt;&gt; </span>loss = model(**inputs, labels=labels).loss`}}),{c(){d=n("p"),k=i("Example of single-label classification:"),c=p(),v(u.$$.fragment)},l(r){d=s(r,"P",{});var f=a(d);k=l(f,"Example of single-label classification:"),f.forEach(o),c=h(r),T(u.$$.fragment,r)},m(r,f){_(r,d,f),e(d,k),_(r,c,f),y(u,r,f),b=!0},p:G,i(r){b||(w(u.$$.fragment,r),b=!0)},o(r){$(u.$$.fragment,r),b=!1},d(r){r&&o(d),r&&o(c),E(u,r)}}}function Hf(F){let d,k,c,u,b;return u=new J({props:{code:`import torch
from transformers import AutoTokenizer, EsmForSequenceClassification

tokenizer = AutoTokenizer.from_pretrained("facebook/esm2_t6_8M_UR50D")
model = EsmForSequenceClassification.from_pretrained("facebook/esm2_t6_8M_UR50D", problem_type="multi_label_classification")

inputs = tokenizer("Hello, my dog is cute", return_tensors="pt")

with torch.no_grad():
    logits = model(**inputs).logits

predicted_class_ids = torch.arange(0, logits.shape[-1])[torch.sigmoid(logits).squeeze(dim=0) > 0.5]

# To train a model on \`num_labels\` classes, you can pass \`num_labels=num_labels\` to \`.from_pretrained(...)\`
num_labels = len(model.config.id2label)
model = EsmForSequenceClassification.from_pretrained(
    "facebook/esm2_t6_8M_UR50D", num_labels=num_labels, problem_type="multi_label_classification"
)

labels = torch.sum(
    torch.nn.functional.one_hot(predicted_class_ids[None, :].clone(), num_classes=num_labels), dim=1
).to(torch.float)
loss = model(**inputs, labels=labels).loss`,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> AutoTokenizer, EsmForSequenceClassification

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.from_pretrained(<span class="hljs-string">&quot;facebook/esm2_t6_8M_UR50D&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = EsmForSequenceClassification.from_pretrained(<span class="hljs-string">&quot;facebook/esm2_t6_8M_UR50D&quot;</span>, problem_type=<span class="hljs-string">&quot;multi_label_classification&quot;</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span>inputs = tokenizer(<span class="hljs-string">&quot;Hello, my dog is cute&quot;</span>, return_tensors=<span class="hljs-string">&quot;pt&quot;</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">with</span> torch.no_grad():
<span class="hljs-meta">... </span>    logits = model(**inputs).logits

<span class="hljs-meta">&gt;&gt;&gt; </span>predicted_class_ids = torch.arange(<span class="hljs-number">0</span>, logits.shape[-<span class="hljs-number">1</span>])[torch.sigmoid(logits).squeeze(dim=<span class="hljs-number">0</span>) &gt; <span class="hljs-number">0.5</span>]

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># To train a model on \`num_labels\` classes, you can pass \`num_labels=num_labels\` to \`.from_pretrained(...)\`</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>num_labels = <span class="hljs-built_in">len</span>(model.config.id2label)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = EsmForSequenceClassification.from_pretrained(
<span class="hljs-meta">... </span>    <span class="hljs-string">&quot;facebook/esm2_t6_8M_UR50D&quot;</span>, num_labels=num_labels, problem_type=<span class="hljs-string">&quot;multi_label_classification&quot;</span>
<span class="hljs-meta">... </span>)

<span class="hljs-meta">&gt;&gt;&gt; </span>labels = torch.<span class="hljs-built_in">sum</span>(
<span class="hljs-meta">... </span>    torch.nn.functional.one_hot(predicted_class_ids[<span class="hljs-literal">None</span>, :].clone(), num_classes=num_labels), dim=<span class="hljs-number">1</span>
<span class="hljs-meta">... </span>).to(torch.<span class="hljs-built_in">float</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>loss = model(**inputs, labels=labels).loss`}}),{c(){d=n("p"),k=i("Example of multi-label classification:"),c=p(),v(u.$$.fragment)},l(r){d=s(r,"P",{});var f=a(d);k=l(f,"Example of multi-label classification:"),f.forEach(o),c=h(r),T(u.$$.fragment,r)},m(r,f){_(r,d,f),e(d,k),_(r,c,f),y(u,r,f),b=!0},p:G,i(r){b||(w(u.$$.fragment,r),b=!0)},o(r){$(u.$$.fragment,r),b=!1},d(r){r&&o(d),r&&o(c),E(u,r)}}}function Kf(F){let d,k,c,u,b;return{c(){d=n("p"),k=i("Although the recipe for forward pass needs to be defined within this function, one should call the "),c=n("code"),u=i("Module"),b=i(`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`)},l(r){d=s(r,"P",{});var f=a(d);k=l(f,"Although the recipe for forward pass needs to be defined within this function, one should call the "),c=s(f,"CODE",{});var M=a(c);u=l(M,"Module"),M.forEach(o),b=l(f,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),f.forEach(o)},m(r,f){_(r,d,f),e(d,k),e(d,c),e(c,u),e(d,b)},d(r){r&&o(d)}}}function Vf(F){let d,k,c,u,b;return u=new J({props:{code:`from transformers import AutoTokenizer, EsmForTokenClassification
import torch

tokenizer = AutoTokenizer.from_pretrained("facebook/esm2_t6_8M_UR50D")
model = EsmForTokenClassification.from_pretrained("facebook/esm2_t6_8M_UR50D")

inputs = tokenizer(
    "HuggingFace is a company based in Paris and New York", add_special_tokens=False, return_tensors="pt"
)

with torch.no_grad():
    logits = model(**inputs).logits

predicted_token_class_ids = logits.argmax(-1)

# Note that tokens are classified rather then input words which means that
# there might be more predicted token classes than words.
# Multiple token classes might account for the same word
predicted_tokens_classes = [model.config.id2label[t.item()] for t in predicted_token_class_ids[0]]

labels = predicted_token_class_ids
loss = model(**inputs, labels=labels).loss`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, EsmForTokenClassification
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">import</span> torch

<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.from_pretrained(<span class="hljs-string">&quot;facebook/esm2_t6_8M_UR50D&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = EsmForTokenClassification.from_pretrained(<span class="hljs-string">&quot;facebook/esm2_t6_8M_UR50D&quot;</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span>inputs = tokenizer(
<span class="hljs-meta">... </span>    <span class="hljs-string">&quot;HuggingFace is a company based in Paris and New York&quot;</span>, add_special_tokens=<span class="hljs-literal">False</span>, return_tensors=<span class="hljs-string">&quot;pt&quot;</span>
<span class="hljs-meta">... </span>)

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">with</span> torch.no_grad():
<span class="hljs-meta">... </span>    logits = model(**inputs).logits

<span class="hljs-meta">&gt;&gt;&gt; </span>predicted_token_class_ids = logits.argmax(-<span class="hljs-number">1</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># Note that tokens are classified rather then input words which means that</span>
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># there might be more predicted token classes than words.</span>
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># Multiple token classes might account for the same word</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>predicted_tokens_classes = [model.config.id2label[t.item()] <span class="hljs-keyword">for</span> t <span class="hljs-keyword">in</span> predicted_token_class_ids[<span class="hljs-number">0</span>]]

<span class="hljs-meta">&gt;&gt;&gt; </span>labels = predicted_token_class_ids
<span class="hljs-meta">&gt;&gt;&gt; </span>loss = model(**inputs, labels=labels).loss`}}),{c(){d=n("p"),k=i("Example:"),c=p(),v(u.$$.fragment)},l(r){d=s(r,"P",{});var f=a(d);k=l(f,"Example:"),f.forEach(o),c=h(r),T(u.$$.fragment,r)},m(r,f){_(r,d,f),e(d,k),_(r,c,f),y(u,r,f),b=!0},p:G,i(r){b||(w(u.$$.fragment,r),b=!0)},o(r){$(u.$$.fragment,r),b=!1},d(r){r&&o(d),r&&o(c),E(u,r)}}}function Bf(F){let d,k,c,u,b;return{c(){d=n("p"),k=i("Although the recipe for forward pass needs to be defined within this function, one should call the "),c=n("code"),u=i("Module"),b=i(`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`)},l(r){d=s(r,"P",{});var f=a(d);k=l(f,"Although the recipe for forward pass needs to be defined within this function, one should call the "),c=s(f,"CODE",{});var M=a(c);u=l(M,"Module"),M.forEach(o),b=l(f,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),f.forEach(o)},m(r,f){_(r,d,f),e(d,k),e(d,c),e(c,u),e(d,b)},d(r){r&&o(d)}}}function Zf(F){let d,k,c,u,b;return u=new J({props:{code:`from transformers import AutoTokenizer, EsmForProteinFolding

model = EsmForProteinFolding.from_pretrained("facebook/esmfold_v1")
tokenizer = AutoTokenizer.from_pretrained("facebook/esmfold_v1")
inputs = tokenizer(["MLKNVQVQLV"], return_tensors="pt", add_special_tokens=False)  # A tiny random peptide
outputs = model(**inputs)
folded_positions = outputs.positions`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, EsmForProteinFolding

<span class="hljs-meta">&gt;&gt;&gt; </span>model = EsmForProteinFolding.from_pretrained(<span class="hljs-string">&quot;facebook/esmfold_v1&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>tokenizer = AutoTokenizer.from_pretrained(<span class="hljs-string">&quot;facebook/esmfold_v1&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>inputs = tokenizer([<span class="hljs-string">&quot;MLKNVQVQLV&quot;</span>], return_tensors=<span class="hljs-string">&quot;pt&quot;</span>, add_special_tokens=<span class="hljs-literal">False</span>)  <span class="hljs-comment"># A tiny random peptide</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>outputs = model(**inputs)
<span class="hljs-meta">&gt;&gt;&gt; </span>folded_positions = outputs.positions`}}),{c(){d=n("p"),k=i("Example:"),c=p(),v(u.$$.fragment)},l(r){d=s(r,"P",{});var f=a(d);k=l(f,"Example:"),f.forEach(o),c=h(r),T(u.$$.fragment,r)},m(r,f){_(r,d,f),e(d,k),_(r,c,f),y(u,r,f),b=!0},p:G,i(r){b||(w(u.$$.fragment,r),b=!0)},o(r){$(u.$$.fragment,r),b=!1},d(r){r&&o(d),r&&o(c),E(u,r)}}}function Gf(F){let d,k,c,u,b;return{c(){d=n("p"),k=i("Although the recipe for forward pass needs to be defined within this function, one should call the "),c=n("code"),u=i("Module"),b=i(`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`)},l(r){d=s(r,"P",{});var f=a(d);k=l(f,"Although the recipe for forward pass needs to be defined within this function, one should call the "),c=s(f,"CODE",{});var M=a(c);u=l(M,"Module"),M.forEach(o),b=l(f,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),f.forEach(o)},m(r,f){_(r,d,f),e(d,k),e(d,c),e(c,u),e(d,b)},d(r){r&&o(d)}}}function Jf(F){let d,k,c,u,b;return u=new J({props:{code:`from transformers import AutoTokenizer, TFEsmModel
import tensorflow as tf

tokenizer = AutoTokenizer.from_pretrained("facebook/esm2_t6_8M_UR50D")
model = TFEsmModel.from_pretrained("facebook/esm2_t6_8M_UR50D")

inputs = tokenizer("Hello, my dog is cute", return_tensors="tf")
outputs = model(inputs)

last_hidden_states = outputs.last_hidden_state`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, TFEsmModel
<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>tokenizer = AutoTokenizer.from_pretrained(<span class="hljs-string">&quot;facebook/esm2_t6_8M_UR50D&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = TFEsmModel.from_pretrained(<span class="hljs-string">&quot;facebook/esm2_t6_8M_UR50D&quot;</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span>inputs = tokenizer(<span class="hljs-string">&quot;Hello, my dog is cute&quot;</span>, return_tensors=<span class="hljs-string">&quot;tf&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>outputs = model(inputs)

<span class="hljs-meta">&gt;&gt;&gt; </span>last_hidden_states = outputs.last_hidden_state`}}),{c(){d=n("p"),k=i("Example:"),c=p(),v(u.$$.fragment)},l(r){d=s(r,"P",{});var f=a(d);k=l(f,"Example:"),f.forEach(o),c=h(r),T(u.$$.fragment,r)},m(r,f){_(r,d,f),e(d,k),_(r,c,f),y(u,r,f),b=!0},p:G,i(r){b||(w(u.$$.fragment,r),b=!0)},o(r){$(u.$$.fragment,r),b=!1},d(r){r&&o(d),r&&o(c),E(u,r)}}}function Qf(F){let d,k,c,u,b;return{c(){d=n("p"),k=i("Although the recipe for forward pass needs to be defined within this function, one should call the "),c=n("code"),u=i("Module"),b=i(`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`)},l(r){d=s(r,"P",{});var f=a(d);k=l(f,"Although the recipe for forward pass needs to be defined within this function, one should call the "),c=s(f,"CODE",{});var M=a(c);u=l(M,"Module"),M.forEach(o),b=l(f,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),f.forEach(o)},m(r,f){_(r,d,f),e(d,k),e(d,c),e(c,u),e(d,b)},d(r){r&&o(d)}}}function Yf(F){let d,k,c,u,b;return u=new J({props:{code:`from transformers import AutoTokenizer, TFEsmForMaskedLM
import tensorflow as tf

tokenizer = AutoTokenizer.from_pretrained("facebook/esm2_t6_8M_UR50D")
model = TFEsmForMaskedLM.from_pretrained("facebook/esm2_t6_8M_UR50D")

inputs = tokenizer("The capital of France is <mask>.", return_tensors="tf")
logits = model(**inputs).logits

# retrieve index of <mask>
mask_token_index = tf.where((inputs.input_ids == tokenizer.mask_token_id)[0])
selected_logits = tf.gather_nd(logits[0], indices=mask_token_index)

predicted_token_id = tf.math.argmax(selected_logits, axis=-1)`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, TFEsmForMaskedLM
<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>tokenizer = AutoTokenizer.from_pretrained(<span class="hljs-string">&quot;facebook/esm2_t6_8M_UR50D&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = TFEsmForMaskedLM.from_pretrained(<span class="hljs-string">&quot;facebook/esm2_t6_8M_UR50D&quot;</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span>inputs = tokenizer(<span class="hljs-string">&quot;The capital of France is &lt;mask&gt;.&quot;</span>, return_tensors=<span class="hljs-string">&quot;tf&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>logits = model(**inputs).logits

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># retrieve index of &lt;mask&gt;</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>mask_token_index = tf.where((inputs.input_ids == tokenizer.mask_token_id)[<span class="hljs-number">0</span>])
<span class="hljs-meta">&gt;&gt;&gt; </span>selected_logits = tf.gather_nd(logits[<span class="hljs-number">0</span>], indices=mask_token_index)

<span class="hljs-meta">&gt;&gt;&gt; </span>predicted_token_id = tf.math.argmax(selected_logits, axis=-<span class="hljs-number">1</span>)`}}),{c(){d=n("p"),k=i("Example:"),c=p(),v(u.$$.fragment)},l(r){d=s(r,"P",{});var f=a(d);k=l(f,"Example:"),f.forEach(o),c=h(r),T(u.$$.fragment,r)},m(r,f){_(r,d,f),e(d,k),_(r,c,f),y(u,r,f),b=!0},p:G,i(r){b||(w(u.$$.fragment,r),b=!0)},o(r){$(u.$$.fragment,r),b=!1},d(r){r&&o(d),r&&o(c),E(u,r)}}}function Xf(F){let d,k;return d=new J({props:{code:`labels = tokenizer("The capital of France is Paris.", return_tensors="tf")["input_ids"]
# mask labels of non-<mask> tokens
labels = tf.where(inputs.input_ids == tokenizer.mask_token_id, labels, -100)

outputs = model(**inputs, labels=labels)`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span>labels = tokenizer(<span class="hljs-string">&quot;The capital of France is Paris.&quot;</span>, return_tensors=<span class="hljs-string">&quot;tf&quot;</span>)[<span class="hljs-string">&quot;input_ids&quot;</span>]
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># mask labels of non-&lt;mask&gt; tokens</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>labels = tf.where(inputs.input_ids == tokenizer.mask_token_id, labels, -<span class="hljs-number">100</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span>outputs = model(**inputs, labels=labels)`}}),{c(){v(d.$$.fragment)},l(c){T(d.$$.fragment,c)},m(c,u){y(d,c,u),k=!0},p:G,i(c){k||(w(d.$$.fragment,c),k=!0)},o(c){$(d.$$.fragment,c),k=!1},d(c){E(d,c)}}}function eu(F){let d,k,c,u,b;return{c(){d=n("p"),k=i("Although the recipe for forward pass needs to be defined within this function, one should call the "),c=n("code"),u=i("Module"),b=i(`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`)},l(r){d=s(r,"P",{});var f=a(d);k=l(f,"Although the recipe for forward pass needs to be defined within this function, one should call the "),c=s(f,"CODE",{});var M=a(c);u=l(M,"Module"),M.forEach(o),b=l(f,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),f.forEach(o)},m(r,f){_(r,d,f),e(d,k),e(d,c),e(c,u),e(d,b)},d(r){r&&o(d)}}}function tu(F){let d,k,c,u,b;return u=new J({props:{code:`from transformers import AutoTokenizer, TFEsmForSequenceClassification
import tensorflow as tf

tokenizer = AutoTokenizer.from_pretrained("facebook/esm2_t6_8M_UR50D")
model = TFEsmForSequenceClassification.from_pretrained("facebook/esm2_t6_8M_UR50D")

inputs = tokenizer("Hello, my dog is cute", return_tensors="tf")

logits = model(**inputs).logits

predicted_class_id = int(tf.math.argmax(logits, axis=-1)[0])`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, TFEsmForSequenceClassification
<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>tokenizer = AutoTokenizer.from_pretrained(<span class="hljs-string">&quot;facebook/esm2_t6_8M_UR50D&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = TFEsmForSequenceClassification.from_pretrained(<span class="hljs-string">&quot;facebook/esm2_t6_8M_UR50D&quot;</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span>inputs = tokenizer(<span class="hljs-string">&quot;Hello, my dog is cute&quot;</span>, return_tensors=<span class="hljs-string">&quot;tf&quot;</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span>logits = model(**inputs).logits

<span class="hljs-meta">&gt;&gt;&gt; </span>predicted_class_id = <span class="hljs-built_in">int</span>(tf.math.argmax(logits, axis=-<span class="hljs-number">1</span>)[<span class="hljs-number">0</span>])`}}),{c(){d=n("p"),k=i("Example:"),c=p(),v(u.$$.fragment)},l(r){d=s(r,"P",{});var f=a(d);k=l(f,"Example:"),f.forEach(o),c=h(r),T(u.$$.fragment,r)},m(r,f){_(r,d,f),e(d,k),_(r,c,f),y(u,r,f),b=!0},p:G,i(r){b||(w(u.$$.fragment,r),b=!0)},o(r){$(u.$$.fragment,r),b=!1},d(r){r&&o(d),r&&o(c),E(u,r)}}}function ou(F){let d,k;return d=new J({props:{code:'# To train a model on `num_labels` classes, you can pass `num_labels=num_labels` to `.from_pretrained(...)`\nnum_labels = len(model.config.id2label)\nmodel = TFEsmForSequenceClassification.from_pretrained("facebook/esm2_t6_8M_UR50D", num_labels=num_labels)\n\nlabels = tf.constant(1)\nloss = model(**inputs, labels=labels).loss',highlighted:'<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># To train a model on `num_labels` classes, you can pass `num_labels=num_labels` to `.from_pretrained(...)`</span>\n<span class="hljs-meta">&gt;&gt;&gt; </span>num_labels = <span class="hljs-built_in">len</span>(model.config.id2label)\n<span class="hljs-meta">&gt;&gt;&gt; </span>model = TFEsmForSequenceClassification.from_pretrained(<span class="hljs-string">&quot;facebook/esm2_t6_8M_UR50D&quot;</span>, num_labels=num_labels)\n\n<span class="hljs-meta">&gt;&gt;&gt; </span>labels = tf.constant(<span class="hljs-number">1</span>)\n<span class="hljs-meta">&gt;&gt;&gt; </span>loss = model(**inputs, labels=labels).loss'}}),{c(){v(d.$$.fragment)},l(c){T(d.$$.fragment,c)},m(c,u){y(d,c,u),k=!0},p:G,i(c){k||(w(d.$$.fragment,c),k=!0)},o(c){$(d.$$.fragment,c),k=!1},d(c){E(d,c)}}}function nu(F){let d,k,c,u,b;return{c(){d=n("p"),k=i("Although the recipe for forward pass needs to be defined within this function, one should call the "),c=n("code"),u=i("Module"),b=i(`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`)},l(r){d=s(r,"P",{});var f=a(d);k=l(f,"Although the recipe for forward pass needs to be defined within this function, one should call the "),c=s(f,"CODE",{});var M=a(c);u=l(M,"Module"),M.forEach(o),b=l(f,`
instance afterwards instead of this since the former takes care of running the pre and post processing steps while
the latter silently ignores them.`),f.forEach(o)},m(r,f){_(r,d,f),e(d,k),e(d,c),e(c,u),e(d,b)},d(r){r&&o(d)}}}function su(F){let d,k,c,u,b;return u=new J({props:{code:`from transformers import AutoTokenizer, TFEsmForTokenClassification
import tensorflow as tf

tokenizer = AutoTokenizer.from_pretrained("facebook/esm2_t6_8M_UR50D")
model = TFEsmForTokenClassification.from_pretrained("facebook/esm2_t6_8M_UR50D")

inputs = tokenizer(
    "HuggingFace is a company based in Paris and New York", add_special_tokens=False, return_tensors="tf"
)

logits = model(**inputs).logits
predicted_token_class_ids = tf.math.argmax(logits, axis=-1)

# Note that tokens are classified rather then input words which means that
# there might be more predicted token classes than words.
# Multiple token classes might account for the same word
predicted_tokens_classes = [model.config.id2label[t] for t in predicted_token_class_ids[0].numpy().tolist()]`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-keyword">from</span> transformers <span class="hljs-keyword">import</span> AutoTokenizer, TFEsmForTokenClassification
<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>tokenizer = AutoTokenizer.from_pretrained(<span class="hljs-string">&quot;facebook/esm2_t6_8M_UR50D&quot;</span>)
<span class="hljs-meta">&gt;&gt;&gt; </span>model = TFEsmForTokenClassification.from_pretrained(<span class="hljs-string">&quot;facebook/esm2_t6_8M_UR50D&quot;</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span>inputs = tokenizer(
<span class="hljs-meta">... </span>    <span class="hljs-string">&quot;HuggingFace is a company based in Paris and New York&quot;</span>, add_special_tokens=<span class="hljs-literal">False</span>, return_tensors=<span class="hljs-string">&quot;tf&quot;</span>
<span class="hljs-meta">... </span>)

<span class="hljs-meta">&gt;&gt;&gt; </span>logits = model(**inputs).logits
<span class="hljs-meta">&gt;&gt;&gt; </span>predicted_token_class_ids = tf.math.argmax(logits, axis=-<span class="hljs-number">1</span>)

<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># Note that tokens are classified rather then input words which means that</span>
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># there might be more predicted token classes than words.</span>
<span class="hljs-meta">&gt;&gt;&gt; </span><span class="hljs-comment"># Multiple token classes might account for the same word</span>
<span class="hljs-meta">&gt;&gt;&gt; </span>predicted_tokens_classes = [model.config.id2label[t] <span class="hljs-keyword">for</span> t <span class="hljs-keyword">in</span> predicted_token_class_ids[<span class="hljs-number">0</span>].numpy().tolist()]`}}),{c(){d=n("p"),k=i("Example:"),c=p(),v(u.$$.fragment)},l(r){d=s(r,"P",{});var f=a(d);k=l(f,"Example:"),f.forEach(o),c=h(r),T(u.$$.fragment,r)},m(r,f){_(r,d,f),e(d,k),_(r,c,f),y(u,r,f),b=!0},p:G,i(r){b||(w(u.$$.fragment,r),b=!0)},o(r){$(u.$$.fragment,r),b=!1},d(r){r&&o(d),r&&o(c),E(u,r)}}}function au(F){let d,k;return d=new J({props:{code:`labels = predicted_token_class_ids
loss = tf.math.reduce_mean(model(**inputs, labels=labels).loss)`,highlighted:`<span class="hljs-meta">&gt;&gt;&gt; </span>labels = predicted_token_class_ids
<span class="hljs-meta">&gt;&gt;&gt; </span>loss = tf.math.reduce_mean(model(**inputs, labels=labels).loss)`}}),{c(){v(d.$$.fragment)},l(c){T(d.$$.fragment,c)},m(c,u){y(d,c,u),k=!0},p:G,i(c){k||(w(d.$$.fragment,c),k=!0)},o(c){$(d.$$.fragment,c),k=!1},d(c){E(d,c)}}}function ru(F){let d,k,c,u,b,r,f,M,ni,Da,ye,Ze,ps,Ot,si,hs,ai,Oa,Ge,ri,It,ii,li,Ia,Je,di,Ut,ci,mi,Ua,gn,pi,Ra,_n,fs,hi,Wa,kn,fi,Ha,bn,us,ui,Ka,vn,gi,Va,Tn,gs,_i,Ba,Q,ki,Rt,bi,vi,Wt,Ti,yi,Ht,wi,$i,Za,ae,Ei,Kt,Fi,Mi,Vt,zi,qi,Ga,re,xi,Bt,Ci,ji,_s,Pi,Si,Ja,we,Qe,ks,Zt,Ai,bs,Li,Qa,ie,vs,yn,Ni,Di,Ts,wn,Oi,Ii,ys,$n,Ui,Ya,$e,Ye,ws,Gt,Ri,$s,Wi,Xa,j,Jt,Hi,Ee,Ki,Es,Vi,Bi,Qt,Zi,Gi,Ji,Fe,Qi,En,Yi,Xi,Fn,el,tl,ol,Xe,nl,et,Yt,sl,Xt,al,Mn,rl,il,er,Me,tt,Fs,eo,ll,Ms,dl,tr,x,to,cl,zs,ml,pl,zn,oo,hl,ot,no,fl,ze,ul,qs,gl,_l,xs,kl,bl,vl,le,so,Tl,qn,yl,xn,wl,$l,Cs,El,Fl,Cn,ao,or,qe,nt,js,ro,Ml,Ps,zl,nr,q,io,ql,Ss,xl,Cl,lo,jl,jn,Pl,Sl,Al,co,Ll,mo,Nl,Dl,Ol,po,Il,ho,Ul,Rl,Wl,C,Hl,As,Kl,Vl,Ls,Bl,Zl,Ns,Gl,Jl,Ds,Ql,Yl,Os,Xl,ed,Is,td,od,nd,Y,fo,sd,xe,ad,Pn,rd,id,Us,ld,dd,cd,st,md,at,sr,Ce,rt,Rs,uo,pd,Ws,hd,ar,P,go,fd,_o,ud,Hs,gd,_d,kd,ko,bd,Sn,vd,Td,yd,bo,wd,vo,$d,Ed,Fd,X,To,Md,je,zd,An,qd,xd,Ks,Cd,jd,Pd,it,Sd,lt,rr,Pe,dt,Vs,yo,Ad,Bs,Ld,ir,S,wo,Nd,Zs,Dd,Od,$o,Id,Ln,Ud,Rd,Wd,Eo,Hd,Fo,Kd,Vd,Bd,U,Mo,Zd,Se,Gd,Nn,Jd,Qd,Gs,Yd,Xd,ec,ct,tc,mt,oc,pt,lr,Ae,ht,Js,zo,nc,Qs,sc,dr,A,qo,ac,Ys,rc,ic,xo,lc,Dn,dc,cc,mc,Co,pc,jo,hc,fc,uc,ee,Po,gc,Le,_c,On,kc,bc,Xs,vc,Tc,yc,ft,wc,ut,cr,Ne,gt,ea,So,$c,ta,Ec,mr,L,Ao,Fc,oa,Mc,zc,Lo,qc,In,xc,Cc,jc,No,Pc,Do,Sc,Ac,Lc,te,Oo,Nc,De,Dc,Un,Oc,Ic,na,Uc,Rc,Wc,_t,Hc,kt,pr,Oe,bt,sa,Io,Kc,aa,Vc,hr,N,Uo,Bc,ra,Zc,Gc,Ro,Jc,Rn,Qc,Yc,Xc,Wo,em,Ho,tm,om,nm,oe,Ko,sm,Ie,am,Wn,rm,im,ia,lm,dm,cm,vt,mm,Tt,fr,Ue,yt,la,Vo,pm,da,hm,ur,D,Bo,fm,Zo,um,ca,gm,_m,km,Go,bm,Hn,vm,Tm,ym,Jo,wm,Qo,$m,Em,Fm,R,Yo,Mm,Re,zm,Kn,qm,xm,ma,Cm,jm,Pm,wt,Sm,$t,Am,Et,gr,We,Ft,pa,Xo,Lm,ha,Nm,_r,O,en,Dm,fa,Om,Im,tn,Um,Vn,Rm,Wm,Hm,on,Km,nn,Vm,Bm,Zm,W,sn,Gm,He,Jm,Bn,Qm,Ym,ua,Xm,ep,tp,Mt,op,zt,np,qt,kr,Ke,xt,ga,an,sp,_a,ap,br,I,rn,rp,ka,ip,lp,ln,dp,Zn,cp,mp,pp,dn,hp,cn,fp,up,gp,H,mn,_p,Ve,kp,Gn,bp,vp,ba,Tp,yp,wp,Ct,$p,jt,Ep,Pt,vr;return r=new B({}),Ot=new B({}),Zt=new B({}),Gt=new B({}),Jt=new z({props:{name:"class transformers.EsmConfig",anchor:"transformers.EsmConfig",parameters:[{name:"vocab_size",val:" = None"},{name:"mask_token_id",val:" = None"},{name:"pad_token_id",val:" = None"},{name:"hidden_size",val:" = 768"},{name:"num_hidden_layers",val:" = 12"},{name:"num_attention_heads",val:" = 12"},{name:"intermediate_size",val:" = 3072"},{name:"hidden_dropout_prob",val:" = 0.1"},{name:"attention_probs_dropout_prob",val:" = 0.1"},{name:"max_position_embeddings",val:" = 1026"},{name:"initializer_range",val:" = 0.02"},{name:"layer_norm_eps",val:" = 1e-12"},{name:"position_embedding_type",val:" = 'absolute'"},{name:"use_cache",val:" = True"},{name:"emb_layer_norm_before",val:" = None"},{name:"token_dropout",val:" = False"},{name:"is_folding_model",val:" = False"},{name:"esmfold_config",val:" = None"},{name:"vocab_list",val:" = None"},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.EsmConfig.vocab_size",description:`<strong>vocab_size</strong> (<code>int</code>, <em>optional</em>) &#x2014;
Vocabulary size of the ESM model. Defines the number of different tokens that can be represented by the
<code>inputs_ids</code> passed when calling <code>ESMModel</code>.`,name:"vocab_size"},{anchor:"transformers.EsmConfig.mask_token_id",description:`<strong>mask_token_id</strong> (<code>int</code>, <em>optional</em>) &#x2014;
The index of the mask token in the vocabulary. This must be included in the config because of the
&#x201C;mask-dropout&#x201D; scaling trick, which will scale the inputs depending on the number of masked tokens.`,name:"mask_token_id"},{anchor:"transformers.EsmConfig.pad_token_id",description:`<strong>pad_token_id</strong> (<code>int</code>, <em>optional</em>) &#x2014;
The index of the padding token in the vocabulary. This must be included in the config because certain parts
of the ESM code use this instead of the attention mask.`,name:"pad_token_id"},{anchor:"transformers.EsmConfig.hidden_size",description:`<strong>hidden_size</strong> (<code>int</code>, <em>optional</em>, defaults to 768) &#x2014;
Dimensionality of the encoder layers and the pooler layer.`,name:"hidden_size"},{anchor:"transformers.EsmConfig.num_hidden_layers",description:`<strong>num_hidden_layers</strong> (<code>int</code>, <em>optional</em>, defaults to 12) &#x2014;
Number of hidden layers in the Transformer encoder.`,name:"num_hidden_layers"},{anchor:"transformers.EsmConfig.num_attention_heads",description:`<strong>num_attention_heads</strong> (<code>int</code>, <em>optional</em>, defaults to 12) &#x2014;
Number of attention heads for each attention layer in the Transformer encoder.`,name:"num_attention_heads"},{anchor:"transformers.EsmConfig.intermediate_size",description:`<strong>intermediate_size</strong> (<code>int</code>, <em>optional</em>, defaults to 3072) &#x2014;
Dimensionality of the &#x201C;intermediate&#x201D; (often named feed-forward) layer in the Transformer encoder.`,name:"intermediate_size"},{anchor:"transformers.EsmConfig.hidden_dropout_prob",description:`<strong>hidden_dropout_prob</strong> (<code>float</code>, <em>optional</em>, defaults to 0.1) &#x2014;
The dropout probability for all fully connected layers in the embeddings, encoder, and pooler.`,name:"hidden_dropout_prob"},{anchor:"transformers.EsmConfig.attention_probs_dropout_prob",description:`<strong>attention_probs_dropout_prob</strong> (<code>float</code>, <em>optional</em>, defaults to 0.1) &#x2014;
The dropout ratio for the attention probabilities.`,name:"attention_probs_dropout_prob"},{anchor:"transformers.EsmConfig.max_position_embeddings",description:`<strong>max_position_embeddings</strong> (<code>int</code>, <em>optional</em>, defaults to 1026) &#x2014;
The maximum sequence length that this model might ever be used with. Typically set this to something large
just in case (e.g., 512 or 1024 or 2048).`,name:"max_position_embeddings"},{anchor:"transformers.EsmConfig.initializer_range",description:`<strong>initializer_range</strong> (<code>float</code>, <em>optional</em>, defaults to 0.02) &#x2014;
The standard deviation of the truncated_normal_initializer for initializing all weight matrices.`,name:"initializer_range"},{anchor:"transformers.EsmConfig.layer_norm_eps",description:`<strong>layer_norm_eps</strong> (<code>float</code>, <em>optional</em>, defaults to 1e-12) &#x2014;
The epsilon used by the layer normalization layers.`,name:"layer_norm_eps"},{anchor:"transformers.EsmConfig.position_embedding_type",description:`<strong>position_embedding_type</strong> (<code>str</code>, <em>optional</em>, defaults to <code>&quot;absolute&quot;</code>) &#x2014;
Type of position embedding. Choose one of <code>&quot;absolute&quot;</code>, <code>&quot;relative_key&quot;</code>, <code>&quot;relative_key_query&quot;, &quot;rotary&quot;</code>.
For positional embeddings use <code>&quot;absolute&quot;</code>. For more information on <code>&quot;relative_key&quot;</code>, please refer to
<a href="https://arxiv.org/abs/1803.02155" rel="nofollow">Self-Attention with Relative Position Representations (Shaw et al.)</a>.
For more information on <code>&quot;relative_key_query&quot;</code>, please refer to <em>Method 4</em> in <a href="https://arxiv.org/abs/2009.13658" rel="nofollow">Improve Transformer Models
with Better Relative Position Embeddings (Huang et al.)</a>.`,name:"position_embedding_type"},{anchor:"transformers.EsmConfig.is_decoder",description:`<strong>is_decoder</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>False</code>) &#x2014;
Whether the model is used as a decoder or not. If <code>False</code>, the model is used as an encoder.`,name:"is_decoder"},{anchor:"transformers.EsmConfig.use_cache",description:`<strong>use_cache</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>True</code>) &#x2014;
Whether or not the model should return the last key/values attentions (not used by all models). Only
relevant if <code>config.is_decoder=True</code>.`,name:"use_cache"},{anchor:"transformers.EsmConfig.emb_layer_norm_before",description:`<strong>emb_layer_norm_before</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether to apply layer normalization after embeddings but before the main stem of the network.`,name:"emb_layer_norm_before"},{anchor:"transformers.EsmConfig.token_dropout",description:`<strong>token_dropout</strong> (<code>bool</code>, defaults to <code>False</code>) &#x2014;
When this is enabled, masked tokens are treated as if they had been dropped out by input dropout.`,name:"token_dropout"}],source:"https://github.com/huggingface/transformers/blob/v4.29.0/src/transformers/models/esm/configuration_esm.py#L33"}}),Xe=new Z({props:{anchor:"transformers.EsmConfig.example",$$slots:{default:[Nf]},$$scope:{ctx:F}}}),Yt=new z({props:{name:"to_dict",anchor:"transformers.EsmConfig.to_dict",parameters:[],source:"https://github.com/huggingface/transformers/blob/v4.29.0/src/transformers/models/esm/configuration_esm.py#L160",returnDescription:`
<p>Dictionary of all the attributes that make up this configuration instance,</p>
`,returnType:`
<p><code>Dict[str, any]</code></p>
`}}),eo=new B({}),to=new z({props:{name:"class transformers.EsmTokenizer",anchor:"transformers.EsmTokenizer",parameters:[{name:"vocab_file",val:""},{name:"unk_token",val:" = '<unk>'"},{name:"cls_token",val:" = '<cls>'"},{name:"pad_token",val:" = '<pad>'"},{name:"mask_token",val:" = '<mask>'"},{name:"eos_token",val:" = '<eos>'"},{name:"**kwargs",val:""}],source:"https://github.com/huggingface/transformers/blob/v4.29.0/src/transformers/models/esm/tokenization_esm.py#L47"}}),oo=new z({props:{name:"build_inputs_with_special_tokens",anchor:"transformers.EsmTokenizer.build_inputs_with_special_tokens",parameters:[{name:"token_ids_0",val:": typing.List[int]"},{name:"token_ids_1",val:": typing.Optional[typing.List[int]] = None"}],source:"https://github.com/huggingface/transformers/blob/v4.29.0/src/transformers/models/esm/tokenization_esm.py#L100"}}),no=new z({props:{name:"get_special_tokens_mask",anchor:"transformers.EsmTokenizer.get_special_tokens_mask",parameters:[{name:"token_ids_0",val:": typing.List"},{name:"token_ids_1",val:": typing.Optional[typing.List] = None"},{name:"already_has_special_tokens",val:": bool = False"}],parametersDescription:[{anchor:"transformers.EsmTokenizer.get_special_tokens_mask.token_ids_0",description:`<strong>token_ids_0</strong> (<code>List[int]</code>) &#x2014;
List of ids of the first sequence.`,name:"token_ids_0"},{anchor:"transformers.EsmTokenizer.get_special_tokens_mask.token_ids_1",description:`<strong>token_ids_1</strong> (<code>List[int]</code>, <em>optional</em>) &#x2014;
List of ids of the second sequence.`,name:"token_ids_1"},{anchor:"transformers.EsmTokenizer.get_special_tokens_mask.already_has_special_tokens",description:`<strong>already_has_special_tokens</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>False</code>) &#x2014;
Whether or not the token list is already formatted with special tokens for the model.`,name:"already_has_special_tokens"}],source:"https://github.com/huggingface/transformers/blob/v4.29.0/src/transformers/models/esm/tokenization_esm.py#L114",returnDescription:`
<p>1 for a special token, 0 for a sequence token.</p>
`,returnType:`
<p>A list of integers in the range [0, 1]</p>
`}}),so=new z({props:{name:"create_token_type_ids_from_sequences",anchor:"transformers.EsmTokenizer.create_token_type_ids_from_sequences",parameters:[{name:"token_ids_0",val:": typing.List[int]"},{name:"token_ids_1",val:": typing.Optional[typing.List[int]] = None"}],parametersDescription:[{anchor:"transformers.EsmTokenizer.create_token_type_ids_from_sequences.token_ids_0",description:"<strong>token_ids_0</strong> (<code>List[int]</code>) &#x2014; The first tokenized sequence.",name:"token_ids_0"},{anchor:"transformers.EsmTokenizer.create_token_type_ids_from_sequences.token_ids_1",description:"<strong>token_ids_1</strong> (<code>List[int]</code>, <em>optional</em>) &#x2014; The second tokenized sequence.",name:"token_ids_1"}],source:"https://github.com/huggingface/transformers/blob/v4.29.0/src/transformers/tokenization_utils_base.py#L3047",returnDescription:`
<p>The token type ids.</p>
`,returnType:`
<p><code>List[int]</code></p>
`}}),ao=new z({props:{name:"save_vocabulary",anchor:"transformers.EsmTokenizer.save_vocabulary",parameters:[{name:"save_directory",val:""},{name:"filename_prefix",val:""}],source:"https://github.com/huggingface/transformers/blob/v4.29.0/src/transformers/models/esm/tokenization_esm.py#L145"}}),ro=new B({}),io=new z({props:{name:"class transformers.EsmModel",anchor:"transformers.EsmModel",parameters:[{name:"config",val:""},{name:"add_pooling_layer",val:" = True"}],parametersDescription:[{anchor:"transformers.EsmModel.config",description:`<strong>config</strong> (<a href="/docs/transformers/v4.29.0/en/model_doc/esm#transformers.EsmConfig">EsmConfig</a>) &#x2014; Model configuration class with all the parameters of the
model. Initializing with a config file does not load the weights associated with the model, only the
configuration. Check out the <a href="/docs/transformers/v4.29.0/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/v4.29.0/src/transformers/models/esm/modeling_esm.py#L773"}}),fo=new z({props:{name:"forward",anchor:"transformers.EsmModel.forward",parameters:[{name:"input_ids",val:": typing.Optional[torch.Tensor] = None"},{name:"attention_mask",val:": typing.Optional[torch.Tensor] = None"},{name:"position_ids",val:": typing.Optional[torch.Tensor] = None"},{name:"head_mask",val:": typing.Optional[torch.Tensor] = None"},{name:"inputs_embeds",val:": typing.Optional[torch.Tensor] = None"},{name:"encoder_hidden_states",val:": typing.Optional[torch.Tensor] = None"},{name:"encoder_attention_mask",val:": typing.Optional[torch.Tensor] = None"},{name:"past_key_values",val:": typing.Optional[typing.List[torch.FloatTensor]] = None"},{name:"use_cache",val:": typing.Optional[bool] = None"},{name:"output_attentions",val:": typing.Optional[bool] = None"},{name:"output_hidden_states",val:": typing.Optional[bool] = None"},{name:"return_dict",val:": typing.Optional[bool] = None"}],parametersDescription:[{anchor:"transformers.EsmModel.forward.input_ids",description:`<strong>input_ids</strong> (<code>torch.LongTensor</code> of shape <code>((batch_size, sequence_length))</code>) &#x2014;
Indices of input sequence tokens in the vocabulary.</p>
<p>Indices can be obtained using <a href="/docs/transformers/v4.29.0/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/v4.29.0/en/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/v4.29.0/en/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.EsmModel.forward.attention_mask",description:`<strong>attention_mask</strong> (<code>torch.FloatTensor</code> of shape <code>((batch_size, sequence_length))</code>, <em>optional</em>) &#x2014;
Mask to avoid performing attention on padding token indices. Mask values selected in <code>[0, 1]</code>:</p>
<ul>
<li>1 for tokens that are <strong>not masked</strong>,</li>
<li>0 for tokens that are <strong>masked</strong>.</li>
</ul>
<p><a href="../glossary#attention-mask">What are attention masks?</a>`,name:"attention_mask"},{anchor:"transformers.EsmModel.forward.position_ids",description:`<strong>position_ids</strong> (<code>torch.LongTensor</code> of shape <code>((batch_size, sequence_length))</code>, <em>optional</em>) &#x2014;
Indices of positions of each input sequence tokens in the position embeddings. Selected in the range <code>[0, config.max_position_embeddings - 1]</code>.</p>
<p><a href="../glossary#position-ids">What are position IDs?</a>`,name:"position_ids"},{anchor:"transformers.EsmModel.forward.head_mask",description:`<strong>head_mask</strong> (<code>torch.FloatTensor</code> of shape <code>(num_heads,)</code> or <code>(num_layers, num_heads)</code>, <em>optional</em>) &#x2014;
Mask to nullify selected heads of the self-attention modules. Mask values selected in <code>[0, 1]</code>:</p>
<ul>
<li>1 indicates the head is <strong>not masked</strong>,</li>
<li>0 indicates the head is <strong>masked</strong>.</li>
</ul>`,name:"head_mask"},{anchor:"transformers.EsmModel.forward.inputs_embeds",description:`<strong>inputs_embeds</strong> (<code>torch.FloatTensor</code> of shape <code>((batch_size, sequence_length), hidden_size)</code>, <em>optional</em>) &#x2014;
Optionally, instead of passing <code>input_ids</code> you can choose to directly pass an embedded representation. This
is useful if you want more control over how to convert <code>input_ids</code> indices into associated vectors than the
model&#x2019;s internal embedding lookup matrix.`,name:"inputs_embeds"},{anchor:"transformers.EsmModel.forward.output_attentions",description:`<strong>output_attentions</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return the attentions tensors of all attention layers. See <code>attentions</code> under returned
tensors for more detail.`,name:"output_attentions"},{anchor:"transformers.EsmModel.forward.output_hidden_states",description:`<strong>output_hidden_states</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return the hidden states of all layers. See <code>hidden_states</code> under returned tensors for
more detail.`,name:"output_hidden_states"},{anchor:"transformers.EsmModel.forward.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/v4.29.0/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"},{anchor:"transformers.EsmModel.forward.encoder_hidden_states",description:`<strong>encoder_hidden_states</strong>  (<code>torch.FloatTensor</code> of shape <code>(batch_size, sequence_length, hidden_size)</code>, <em>optional</em>) &#x2014;
Sequence of hidden-states at the output of the last layer of the encoder. Used in the cross-attention if
the model is configured as a decoder.`,name:"encoder_hidden_states"},{anchor:"transformers.EsmModel.forward.encoder_attention_mask",description:`<strong>encoder_attention_mask</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Mask to avoid performing attention on the padding token indices of the encoder input. This mask is used in
the cross-attention if the model is configured as a decoder. Mask values selected in <code>[0, 1]</code>:</p>
<ul>
<li>1 for tokens that are <strong>not masked</strong>,</li>
<li>0 for tokens that are <strong>masked</strong>.</li>
</ul>`,name:"encoder_attention_mask"},{anchor:"transformers.EsmModel.forward.past_key_values",description:`<strong>past_key_values</strong> (<code>tuple(tuple(torch.FloatTensor))</code> of length <code>config.n_layers</code> with each tuple having 4 tensors of shape <code>(batch_size, num_heads, sequence_length - 1, embed_size_per_head)</code>) &#x2014;
Contains precomputed key and value hidden states of the attention blocks. Can be used to speed up decoding.</p>
<p>If <code>past_key_values</code> are used, the user can optionally input only the last <code>decoder_input_ids</code> (those that
don&#x2019;t have their past key value states given to this model) of shape <code>(batch_size, 1)</code> instead of all
<code>decoder_input_ids</code> of shape <code>(batch_size, sequence_length)</code>.`,name:"past_key_values"},{anchor:"transformers.EsmModel.forward.use_cache",description:`<strong>use_cache</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
If set to <code>True</code>, <code>past_key_values</code> key value states are returned and can be used to speed up decoding (see
<code>past_key_values</code>).`,name:"use_cache"}],source:"https://github.com/huggingface/transformers/blob/v4.29.0/src/transformers/models/esm/modeling_esm.py#L823",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.29.0/en/main_classes/output#transformers.modeling_outputs.BaseModelOutputWithPoolingAndCrossAttentions"
>transformers.modeling_outputs.BaseModelOutputWithPoolingAndCrossAttentions</a> or a tuple of
<code>torch.FloatTensor</code> (if <code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various
elements depending on the configuration (<a
  href="/docs/transformers/v4.29.0/en/model_doc/esm#transformers.EsmConfig"
>EsmConfig</a>) and inputs.</p>
<ul>
<li>
<p><strong>last_hidden_state</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, sequence_length, hidden_size)</code>) \u2014 Sequence of hidden-states at the output of the last layer of the model.</p>
</li>
<li>
<p><strong>pooler_output</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, hidden_size)</code>) \u2014 Last layer hidden-state of the first token of the sequence (classification token) after further processing
through the layers used for the auxiliary pretraining task. E.g. for BERT-family of models, this returns
the classification token after processing through a linear layer and a tanh activation function. The linear
layer weights are trained from the next sentence prediction (classification) objective during pretraining.</p>
</li>
<li>
<p><strong>hidden_states</strong> (<code>tuple(torch.FloatTensor)</code>, <em>optional</em>, returned when <code>output_hidden_states=True</code> is passed or when <code>config.output_hidden_states=True</code>) \u2014 Tuple of <code>torch.FloatTensor</code> (one for the output of the embeddings, if the model has an embedding layer, +
one for the output of each layer) of shape <code>(batch_size, sequence_length, hidden_size)</code>.</p>
<p>Hidden-states of the model at the output of each layer plus the optional initial embedding outputs.</p>
</li>
<li>
<p><strong>attentions</strong> (<code>tuple(torch.FloatTensor)</code>, <em>optional</em>, returned when <code>output_attentions=True</code> is passed or when <code>config.output_attentions=True</code>) \u2014 Tuple of <code>torch.FloatTensor</code> (one for each layer) of shape <code>(batch_size, num_heads, sequence_length, sequence_length)</code>.</p>
<p>Attentions weights after the attention softmax, used to compute the weighted average in the self-attention
heads.</p>
</li>
<li>
<p><strong>cross_attentions</strong> (<code>tuple(torch.FloatTensor)</code>, <em>optional</em>, returned when <code>output_attentions=True</code> and <code>config.add_cross_attention=True</code> is passed or when <code>config.output_attentions=True</code>) \u2014 Tuple of <code>torch.FloatTensor</code> (one for each layer) of shape <code>(batch_size, num_heads, sequence_length, sequence_length)</code>.</p>
<p>Attentions weights of the decoder\u2019s cross-attention layer, after the attention softmax, used to compute the
weighted average in the cross-attention heads.</p>
</li>
<li>
<p><strong>past_key_values</strong> (<code>tuple(tuple(torch.FloatTensor))</code>, <em>optional</em>, returned when <code>use_cache=True</code> is passed or when <code>config.use_cache=True</code>) \u2014 Tuple of <code>tuple(torch.FloatTensor)</code> of length <code>config.n_layers</code>, with each tuple having 2 tensors of shape
<code>(batch_size, num_heads, sequence_length, embed_size_per_head)</code>) and optionally if
<code>config.is_encoder_decoder=True</code> 2 additional tensors of shape <code>(batch_size, num_heads, encoder_sequence_length, embed_size_per_head)</code>.</p>
<p>Contains pre-computed hidden-states (key and values in the self-attention blocks and optionally if
<code>config.is_encoder_decoder=True</code> in the cross-attention blocks) that can be used (see <code>past_key_values</code>
input) to speed up sequential decoding.</p>
</li>
</ul>
`,returnType:`
<p><a
  href="/docs/transformers/v4.29.0/en/main_classes/output#transformers.modeling_outputs.BaseModelOutputWithPoolingAndCrossAttentions"
>transformers.modeling_outputs.BaseModelOutputWithPoolingAndCrossAttentions</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),st=new Be({props:{$$slots:{default:[Df]},$$scope:{ctx:F}}}),at=new Z({props:{anchor:"transformers.EsmModel.forward.example",$$slots:{default:[Of]},$$scope:{ctx:F}}}),uo=new B({}),go=new z({props:{name:"class transformers.EsmForMaskedLM",anchor:"transformers.EsmForMaskedLM",parameters:[{name:"config",val:""}],parametersDescription:[{anchor:"transformers.EsmForMaskedLM.config",description:`<strong>config</strong> (<a href="/docs/transformers/v4.29.0/en/model_doc/esm#transformers.EsmConfig">EsmConfig</a>) &#x2014; Model configuration class with all the parameters of the
model. Initializing with a config file does not load the weights associated with the model, only the
configuration. Check out the <a href="/docs/transformers/v4.29.0/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/v4.29.0/src/transformers/models/esm/modeling_esm.py#L962"}}),To=new z({props:{name:"forward",anchor:"transformers.EsmForMaskedLM.forward",parameters:[{name:"input_ids",val:": typing.Optional[torch.LongTensor] = None"},{name:"attention_mask",val:": typing.Optional[torch.Tensor] = None"},{name:"position_ids",val:": typing.Optional[torch.LongTensor] = None"},{name:"head_mask",val:": typing.Optional[torch.Tensor] = None"},{name:"inputs_embeds",val:": typing.Optional[torch.FloatTensor] = None"},{name:"encoder_hidden_states",val:": typing.Optional[torch.FloatTensor] = None"},{name:"encoder_attention_mask",val:": typing.Optional[torch.Tensor] = None"},{name:"labels",val:": typing.Optional[torch.LongTensor] = None"},{name:"output_attentions",val:": typing.Optional[bool] = None"},{name:"output_hidden_states",val:": typing.Optional[bool] = None"},{name:"return_dict",val:": typing.Optional[bool] = None"}],parametersDescription:[{anchor:"transformers.EsmForMaskedLM.forward.input_ids",description:`<strong>input_ids</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, sequence_length)</code>) &#x2014;
Indices of input sequence tokens in the vocabulary.</p>
<p>Indices can be obtained using <a href="/docs/transformers/v4.29.0/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/v4.29.0/en/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/v4.29.0/en/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.EsmForMaskedLM.forward.attention_mask",description:`<strong>attention_mask</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Mask to avoid performing attention on padding token indices. Mask values selected in <code>[0, 1]</code>:</p>
<ul>
<li>1 for tokens that are <strong>not masked</strong>,</li>
<li>0 for tokens that are <strong>masked</strong>.</li>
</ul>
<p><a href="../glossary#attention-mask">What are attention masks?</a>`,name:"attention_mask"},{anchor:"transformers.EsmForMaskedLM.forward.position_ids",description:`<strong>position_ids</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Indices of positions of each input sequence tokens in the position embeddings. Selected in the range <code>[0, config.max_position_embeddings - 1]</code>.</p>
<p><a href="../glossary#position-ids">What are position IDs?</a>`,name:"position_ids"},{anchor:"transformers.EsmForMaskedLM.forward.head_mask",description:`<strong>head_mask</strong> (<code>torch.FloatTensor</code> of shape <code>(num_heads,)</code> or <code>(num_layers, num_heads)</code>, <em>optional</em>) &#x2014;
Mask to nullify selected heads of the self-attention modules. Mask values selected in <code>[0, 1]</code>:</p>
<ul>
<li>1 indicates the head is <strong>not masked</strong>,</li>
<li>0 indicates the head is <strong>masked</strong>.</li>
</ul>`,name:"head_mask"},{anchor:"transformers.EsmForMaskedLM.forward.inputs_embeds",description:`<strong>inputs_embeds</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, sequence_length, hidden_size)</code>, <em>optional</em>) &#x2014;
Optionally, instead of passing <code>input_ids</code> you can choose to directly pass an embedded representation. This
is useful if you want more control over how to convert <code>input_ids</code> indices into associated vectors than the
model&#x2019;s internal embedding lookup matrix.`,name:"inputs_embeds"},{anchor:"transformers.EsmForMaskedLM.forward.output_attentions",description:`<strong>output_attentions</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return the attentions tensors of all attention layers. See <code>attentions</code> under returned
tensors for more detail.`,name:"output_attentions"},{anchor:"transformers.EsmForMaskedLM.forward.output_hidden_states",description:`<strong>output_hidden_states</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return the hidden states of all layers. See <code>hidden_states</code> under returned tensors for
more detail.`,name:"output_hidden_states"},{anchor:"transformers.EsmForMaskedLM.forward.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/v4.29.0/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"},{anchor:"transformers.EsmForMaskedLM.forward.labels",description:`<strong>labels</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Labels for computing the masked language modeling loss. Indices should be in <code>[-100, 0, ..., config.vocab_size]</code> (see <code>input_ids</code> docstring) Tokens with indices set to <code>-100</code> are ignored (masked), the
loss is only computed for the tokens with labels in <code>[0, ..., config.vocab_size]</code>`,name:"labels"},{anchor:"transformers.EsmForMaskedLM.forward.kwargs",description:`<strong>kwargs</strong> (<code>Dict[str, any]</code>, optional, defaults to <em>{}</em>) &#x2014;
Used to hide legacy arguments that have been deprecated.`,name:"kwargs"}],source:"https://github.com/huggingface/transformers/blob/v4.29.0/src/transformers/models/esm/modeling_esm.py#L986",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.29.0/en/main_classes/output#transformers.modeling_outputs.MaskedLMOutput"
>transformers.modeling_outputs.MaskedLMOutput</a> or a tuple of
<code>torch.FloatTensor</code> (if <code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various
elements depending on the configuration (<a
  href="/docs/transformers/v4.29.0/en/model_doc/esm#transformers.EsmConfig"
>EsmConfig</a>) and inputs.</p>
<ul>
<li>
<p><strong>loss</strong> (<code>torch.FloatTensor</code> of shape <code>(1,)</code>, <em>optional</em>, returned when <code>labels</code> is provided) \u2014 Masked language modeling (MLM) loss.</p>
</li>
<li>
<p><strong>logits</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, sequence_length, config.vocab_size)</code>) \u2014 Prediction scores of the language modeling head (scores for each vocabulary token before SoftMax).</p>
</li>
<li>
<p><strong>hidden_states</strong> (<code>tuple(torch.FloatTensor)</code>, <em>optional</em>, returned when <code>output_hidden_states=True</code> is passed or when <code>config.output_hidden_states=True</code>) \u2014 Tuple of <code>torch.FloatTensor</code> (one for the output of the embeddings, if the model has an embedding layer, +
one for the output of each layer) of shape <code>(batch_size, sequence_length, hidden_size)</code>.</p>
<p>Hidden-states of the model at the output of each layer plus the optional initial embedding outputs.</p>
</li>
<li>
<p><strong>attentions</strong> (<code>tuple(torch.FloatTensor)</code>, <em>optional</em>, returned when <code>output_attentions=True</code> is passed or when <code>config.output_attentions=True</code>) \u2014 Tuple of <code>torch.FloatTensor</code> (one for each layer) of shape <code>(batch_size, num_heads, sequence_length, sequence_length)</code>.</p>
<p>Attentions weights after the attention softmax, used to compute the weighted average in the self-attention
heads.</p>
</li>
</ul>
`,returnType:`
<p><a
  href="/docs/transformers/v4.29.0/en/main_classes/output#transformers.modeling_outputs.MaskedLMOutput"
>transformers.modeling_outputs.MaskedLMOutput</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),it=new Be({props:{$$slots:{default:[If]},$$scope:{ctx:F}}}),lt=new Z({props:{anchor:"transformers.EsmForMaskedLM.forward.example",$$slots:{default:[Uf]},$$scope:{ctx:F}}}),yo=new B({}),wo=new z({props:{name:"class transformers.EsmForSequenceClassification",anchor:"transformers.EsmForSequenceClassification",parameters:[{name:"config",val:""}],parametersDescription:[{anchor:"transformers.EsmForSequenceClassification.config",description:`<strong>config</strong> (<a href="/docs/transformers/v4.29.0/en/model_doc/esm#transformers.EsmConfig">EsmConfig</a>) &#x2014; Model configuration class with all the parameters of the
model. Initializing with a config file does not load the weights associated with the model, only the
configuration. Check out the <a href="/docs/transformers/v4.29.0/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/v4.29.0/src/transformers/models/esm/modeling_esm.py#L1082"}}),Mo=new z({props:{name:"forward",anchor:"transformers.EsmForSequenceClassification.forward",parameters:[{name:"input_ids",val:": typing.Optional[torch.LongTensor] = None"},{name:"attention_mask",val:": typing.Optional[torch.Tensor] = None"},{name:"position_ids",val:": typing.Optional[torch.LongTensor] = None"},{name:"head_mask",val:": typing.Optional[torch.Tensor] = None"},{name:"inputs_embeds",val:": typing.Optional[torch.FloatTensor] = None"},{name:"labels",val:": typing.Optional[torch.LongTensor] = None"},{name:"output_attentions",val:": typing.Optional[bool] = None"},{name:"output_hidden_states",val:": typing.Optional[bool] = None"},{name:"return_dict",val:": typing.Optional[bool] = None"}],parametersDescription:[{anchor:"transformers.EsmForSequenceClassification.forward.input_ids",description:`<strong>input_ids</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, sequence_length)</code>) &#x2014;
Indices of input sequence tokens in the vocabulary.</p>
<p>Indices can be obtained using <a href="/docs/transformers/v4.29.0/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/v4.29.0/en/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/v4.29.0/en/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.EsmForSequenceClassification.forward.attention_mask",description:`<strong>attention_mask</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Mask to avoid performing attention on padding token indices. Mask values selected in <code>[0, 1]</code>:</p>
<ul>
<li>1 for tokens that are <strong>not masked</strong>,</li>
<li>0 for tokens that are <strong>masked</strong>.</li>
</ul>
<p><a href="../glossary#attention-mask">What are attention masks?</a>`,name:"attention_mask"},{anchor:"transformers.EsmForSequenceClassification.forward.position_ids",description:`<strong>position_ids</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Indices of positions of each input sequence tokens in the position embeddings. Selected in the range <code>[0, config.max_position_embeddings - 1]</code>.</p>
<p><a href="../glossary#position-ids">What are position IDs?</a>`,name:"position_ids"},{anchor:"transformers.EsmForSequenceClassification.forward.head_mask",description:`<strong>head_mask</strong> (<code>torch.FloatTensor</code> of shape <code>(num_heads,)</code> or <code>(num_layers, num_heads)</code>, <em>optional</em>) &#x2014;
Mask to nullify selected heads of the self-attention modules. Mask values selected in <code>[0, 1]</code>:</p>
<ul>
<li>1 indicates the head is <strong>not masked</strong>,</li>
<li>0 indicates the head is <strong>masked</strong>.</li>
</ul>`,name:"head_mask"},{anchor:"transformers.EsmForSequenceClassification.forward.inputs_embeds",description:`<strong>inputs_embeds</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, sequence_length, hidden_size)</code>, <em>optional</em>) &#x2014;
Optionally, instead of passing <code>input_ids</code> you can choose to directly pass an embedded representation. This
is useful if you want more control over how to convert <code>input_ids</code> indices into associated vectors than the
model&#x2019;s internal embedding lookup matrix.`,name:"inputs_embeds"},{anchor:"transformers.EsmForSequenceClassification.forward.output_attentions",description:`<strong>output_attentions</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return the attentions tensors of all attention layers. See <code>attentions</code> under returned
tensors for more detail.`,name:"output_attentions"},{anchor:"transformers.EsmForSequenceClassification.forward.output_hidden_states",description:`<strong>output_hidden_states</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return the hidden states of all layers. See <code>hidden_states</code> under returned tensors for
more detail.`,name:"output_hidden_states"},{anchor:"transformers.EsmForSequenceClassification.forward.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/v4.29.0/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"},{anchor:"transformers.EsmForSequenceClassification.forward.labels",description:`<strong>labels</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size,)</code>, <em>optional</em>) &#x2014;
Labels for computing the sequence classification/regression loss. Indices should be in <code>[0, ..., config.num_labels - 1]</code>. If <code>config.num_labels == 1</code> a regression loss is computed (Mean-Square loss), If
<code>config.num_labels &gt; 1</code> a classification loss is computed (Cross-Entropy).`,name:"labels"}],source:"https://github.com/huggingface/transformers/blob/v4.29.0/src/transformers/models/esm/modeling_esm.py#L1095",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.29.0/en/main_classes/output#transformers.modeling_outputs.SequenceClassifierOutput"
>transformers.modeling_outputs.SequenceClassifierOutput</a> or a tuple of
<code>torch.FloatTensor</code> (if <code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various
elements depending on the configuration (<a
  href="/docs/transformers/v4.29.0/en/model_doc/esm#transformers.EsmConfig"
>EsmConfig</a>) and inputs.</p>
<ul>
<li>
<p><strong>loss</strong> (<code>torch.FloatTensor</code> of shape <code>(1,)</code>, <em>optional</em>, returned when <code>labels</code> is provided) \u2014 Classification (or regression if config.num_labels==1) loss.</p>
</li>
<li>
<p><strong>logits</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, config.num_labels)</code>) \u2014 Classification (or regression if config.num_labels==1) scores (before SoftMax).</p>
</li>
<li>
<p><strong>hidden_states</strong> (<code>tuple(torch.FloatTensor)</code>, <em>optional</em>, returned when <code>output_hidden_states=True</code> is passed or when <code>config.output_hidden_states=True</code>) \u2014 Tuple of <code>torch.FloatTensor</code> (one for the output of the embeddings, if the model has an embedding layer, +
one for the output of each layer) of shape <code>(batch_size, sequence_length, hidden_size)</code>.</p>
<p>Hidden-states of the model at the output of each layer plus the optional initial embedding outputs.</p>
</li>
<li>
<p><strong>attentions</strong> (<code>tuple(torch.FloatTensor)</code>, <em>optional</em>, returned when <code>output_attentions=True</code> is passed or when <code>config.output_attentions=True</code>) \u2014 Tuple of <code>torch.FloatTensor</code> (one for each layer) of shape <code>(batch_size, num_heads, sequence_length, sequence_length)</code>.</p>
<p>Attentions weights after the attention softmax, used to compute the weighted average in the self-attention
heads.</p>
</li>
</ul>
`,returnType:`
<p><a
  href="/docs/transformers/v4.29.0/en/main_classes/output#transformers.modeling_outputs.SequenceClassifierOutput"
>transformers.modeling_outputs.SequenceClassifierOutput</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),ct=new Be({props:{$$slots:{default:[Rf]},$$scope:{ctx:F}}}),mt=new Z({props:{anchor:"transformers.EsmForSequenceClassification.forward.example",$$slots:{default:[Wf]},$$scope:{ctx:F}}}),pt=new Z({props:{anchor:"transformers.EsmForSequenceClassification.forward.example-2",$$slots:{default:[Hf]},$$scope:{ctx:F}}}),zo=new B({}),qo=new z({props:{name:"class transformers.EsmForTokenClassification",anchor:"transformers.EsmForTokenClassification",parameters:[{name:"config",val:""}],parametersDescription:[{anchor:"transformers.EsmForTokenClassification.config",description:`<strong>config</strong> (<a href="/docs/transformers/v4.29.0/en/model_doc/esm#transformers.EsmConfig">EsmConfig</a>) &#x2014; Model configuration class with all the parameters of the
model. Initializing with a config file does not load the weights associated with the model, only the
configuration. Check out the <a href="/docs/transformers/v4.29.0/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/v4.29.0/src/transformers/models/esm/modeling_esm.py#L1178"}}),Po=new z({props:{name:"forward",anchor:"transformers.EsmForTokenClassification.forward",parameters:[{name:"input_ids",val:": typing.Optional[torch.LongTensor] = None"},{name:"attention_mask",val:": typing.Optional[torch.Tensor] = None"},{name:"position_ids",val:": typing.Optional[torch.LongTensor] = None"},{name:"head_mask",val:": typing.Optional[torch.Tensor] = None"},{name:"inputs_embeds",val:": typing.Optional[torch.FloatTensor] = None"},{name:"labels",val:": typing.Optional[torch.LongTensor] = None"},{name:"output_attentions",val:": typing.Optional[bool] = None"},{name:"output_hidden_states",val:": typing.Optional[bool] = None"},{name:"return_dict",val:": typing.Optional[bool] = None"}],parametersDescription:[{anchor:"transformers.EsmForTokenClassification.forward.input_ids",description:`<strong>input_ids</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, sequence_length)</code>) &#x2014;
Indices of input sequence tokens in the vocabulary.</p>
<p>Indices can be obtained using <a href="/docs/transformers/v4.29.0/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/v4.29.0/en/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/v4.29.0/en/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.EsmForTokenClassification.forward.attention_mask",description:`<strong>attention_mask</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Mask to avoid performing attention on padding token indices. Mask values selected in <code>[0, 1]</code>:</p>
<ul>
<li>1 for tokens that are <strong>not masked</strong>,</li>
<li>0 for tokens that are <strong>masked</strong>.</li>
</ul>
<p><a href="../glossary#attention-mask">What are attention masks?</a>`,name:"attention_mask"},{anchor:"transformers.EsmForTokenClassification.forward.position_ids",description:`<strong>position_ids</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Indices of positions of each input sequence tokens in the position embeddings. Selected in the range <code>[0, config.max_position_embeddings - 1]</code>.</p>
<p><a href="../glossary#position-ids">What are position IDs?</a>`,name:"position_ids"},{anchor:"transformers.EsmForTokenClassification.forward.head_mask",description:`<strong>head_mask</strong> (<code>torch.FloatTensor</code> of shape <code>(num_heads,)</code> or <code>(num_layers, num_heads)</code>, <em>optional</em>) &#x2014;
Mask to nullify selected heads of the self-attention modules. Mask values selected in <code>[0, 1]</code>:</p>
<ul>
<li>1 indicates the head is <strong>not masked</strong>,</li>
<li>0 indicates the head is <strong>masked</strong>.</li>
</ul>`,name:"head_mask"},{anchor:"transformers.EsmForTokenClassification.forward.inputs_embeds",description:`<strong>inputs_embeds</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, sequence_length, hidden_size)</code>, <em>optional</em>) &#x2014;
Optionally, instead of passing <code>input_ids</code> you can choose to directly pass an embedded representation. This
is useful if you want more control over how to convert <code>input_ids</code> indices into associated vectors than the
model&#x2019;s internal embedding lookup matrix.`,name:"inputs_embeds"},{anchor:"transformers.EsmForTokenClassification.forward.output_attentions",description:`<strong>output_attentions</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return the attentions tensors of all attention layers. See <code>attentions</code> under returned
tensors for more detail.`,name:"output_attentions"},{anchor:"transformers.EsmForTokenClassification.forward.output_hidden_states",description:`<strong>output_hidden_states</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return the hidden states of all layers. See <code>hidden_states</code> under returned tensors for
more detail.`,name:"output_hidden_states"},{anchor:"transformers.EsmForTokenClassification.forward.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/v4.29.0/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"},{anchor:"transformers.EsmForTokenClassification.forward.labels",description:`<strong>labels</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Labels for computing the token classification loss. Indices should be in <code>[0, ..., config.num_labels - 1]</code>.`,name:"labels"}],source:"https://github.com/huggingface/transformers/blob/v4.29.0/src/transformers/models/esm/modeling_esm.py#L1192",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.29.0/en/main_classes/output#transformers.modeling_outputs.TokenClassifierOutput"
>transformers.modeling_outputs.TokenClassifierOutput</a> or a tuple of
<code>torch.FloatTensor</code> (if <code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various
elements depending on the configuration (<a
  href="/docs/transformers/v4.29.0/en/model_doc/esm#transformers.EsmConfig"
>EsmConfig</a>) and inputs.</p>
<ul>
<li>
<p><strong>loss</strong> (<code>torch.FloatTensor</code> of shape <code>(1,)</code>, <em>optional</em>, returned when <code>labels</code> is provided)  \u2014 Classification loss.</p>
</li>
<li>
<p><strong>logits</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, sequence_length, config.num_labels)</code>) \u2014 Classification scores (before SoftMax).</p>
</li>
<li>
<p><strong>hidden_states</strong> (<code>tuple(torch.FloatTensor)</code>, <em>optional</em>, returned when <code>output_hidden_states=True</code> is passed or when <code>config.output_hidden_states=True</code>) \u2014 Tuple of <code>torch.FloatTensor</code> (one for the output of the embeddings, if the model has an embedding layer, +
one for the output of each layer) of shape <code>(batch_size, sequence_length, hidden_size)</code>.</p>
<p>Hidden-states of the model at the output of each layer plus the optional initial embedding outputs.</p>
</li>
<li>
<p><strong>attentions</strong> (<code>tuple(torch.FloatTensor)</code>, <em>optional</em>, returned when <code>output_attentions=True</code> is passed or when <code>config.output_attentions=True</code>) \u2014 Tuple of <code>torch.FloatTensor</code> (one for each layer) of shape <code>(batch_size, num_heads, sequence_length, sequence_length)</code>.</p>
<p>Attentions weights after the attention softmax, used to compute the weighted average in the self-attention
heads.</p>
</li>
</ul>
`,returnType:`
<p><a
  href="/docs/transformers/v4.29.0/en/main_classes/output#transformers.modeling_outputs.TokenClassifierOutput"
>transformers.modeling_outputs.TokenClassifierOutput</a> or <code>tuple(torch.FloatTensor)</code></p>
`}}),ft=new Be({props:{$$slots:{default:[Kf]},$$scope:{ctx:F}}}),ut=new Z({props:{anchor:"transformers.EsmForTokenClassification.forward.example",$$slots:{default:[Vf]},$$scope:{ctx:F}}}),So=new B({}),Ao=new z({props:{name:"class transformers.EsmForProteinFolding",anchor:"transformers.EsmForProteinFolding",parameters:[{name:"config",val:""}],parametersDescription:[{anchor:"transformers.EsmForProteinFolding.config",description:`<strong>config</strong> (<a href="/docs/transformers/v4.29.0/en/model_doc/esm#transformers.EsmConfig">EsmConfig</a>) &#x2014; Model configuration class with all the parameters of the
model. Initializing with a config file does not load the weights associated with the model, only the
configuration. Check out the <a href="/docs/transformers/v4.29.0/en/main_classes/model#transformers.PreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/v4.29.0/src/transformers/models/esm/modeling_esmfold.py#L2020"}}),Oo=new z({props:{name:"forward",anchor:"transformers.EsmForProteinFolding.forward",parameters:[{name:"input_ids",val:": Tensor"},{name:"attention_mask",val:": Tensor = None"},{name:"position_ids",val:": typing.Optional[torch.Tensor] = None"},{name:"masking_pattern",val:": typing.Optional[torch.Tensor] = None"},{name:"num_recycles",val:": typing.Optional[int] = None"}],parametersDescription:[{anchor:"transformers.EsmForProteinFolding.forward.input_ids",description:`<strong>input_ids</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, sequence_length)</code>) &#x2014;
Indices of input sequence tokens in the vocabulary.</p>
<p>Indices can be obtained using <a href="/docs/transformers/v4.29.0/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/v4.29.0/en/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/v4.29.0/en/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.EsmForProteinFolding.forward.attention_mask",description:`<strong>attention_mask</strong> (<code>torch.FloatTensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Mask to avoid performing attention on padding token indices. Mask values selected in <code>[0, 1]</code>:</p>
<ul>
<li>1 for tokens that are <strong>not masked</strong>,</li>
<li>0 for tokens that are <strong>masked</strong>.</li>
</ul>
<p><a href="../glossary#attention-mask">What are attention masks?</a>`,name:"attention_mask"},{anchor:"transformers.EsmForProteinFolding.forward.position_ids",description:`<strong>position_ids</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Indices of positions of each input sequence tokens in the position embeddings. Selected in the range <code>[0, config.max_position_embeddings - 1]</code>.</p>
<p><a href="../glossary#position-ids">What are position IDs?</a>`,name:"position_ids"},{anchor:"transformers.EsmForProteinFolding.forward.masking_pattern",description:`<strong>masking_pattern</strong> (<code>torch.LongTensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Locations of tokens to mask during training as a form of regularization. Mask values selected in <code>[0, 1]</code>.`,name:"masking_pattern"},{anchor:"transformers.EsmForProteinFolding.forward.num_recycles",description:`<strong>num_recycles</strong> (<code>int</code>, <em>optional</em>, defaults to <code>None</code>) &#x2014;
Number of times to recycle the input sequence. If <code>None</code>, defaults to <code>config.num_recycles</code>. &#x201C;Recycling&#x201D;
consists of passing the output of the folding trunk back in as input to the trunk. During training, the
number of recycles should vary with each batch, to ensure that the model learns to output valid predictions
after each recycle. During inference, num_recycles should be set to the highest value that the model was
trained with for maximum accuracy. Accordingly, when this value is set to <code>None</code>, config.max_recycles is
used.`,name:"num_recycles"}],source:"https://github.com/huggingface/transformers/blob/v4.29.0/src/transformers/models/esm/modeling_esmfold.py#L2082",returnDescription:`
<p>A <code>transformers.models.esm.modeling_esmfold.EsmForProteinFoldingOutput</code> or a tuple of
<code>torch.FloatTensor</code> (if <code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various
elements depending on the configuration (<code>&lt;class 'transformers.models.esm.configuration_esm.EsmConfig'&gt;</code>) and inputs.</p>
<ul>
<li><strong>frames</strong> (<code>torch.FloatTensor</code>) \u2014 Output frames.</li>
<li><strong>sidechain_frames</strong> (<code>torch.FloatTensor</code>) \u2014 Output sidechain frames.</li>
<li><strong>unnormalized_angles</strong> (<code>torch.FloatTensor</code>) \u2014 Predicted unnormalized backbone and side chain torsion angles.</li>
<li><strong>angles</strong> (<code>torch.FloatTensor</code>) \u2014 Predicted backbone and side chain torsion angles.</li>
<li><strong>positions</strong> (<code>torch.FloatTensor</code>) \u2014 Predicted positions of the backbone and side chain atoms.</li>
<li><strong>states</strong> (<code>torch.FloatTensor</code>) \u2014 Hidden states from the protein folding trunk.</li>
<li><strong>s_s</strong> (<code>torch.FloatTensor</code>) \u2014 Per-residue embeddings derived by concatenating the hidden states of each layer of the ESM-2 LM stem.</li>
<li><strong>s_z</strong> (<code>torch.FloatTensor</code>) \u2014 Pairwise residue embeddings.</li>
<li><strong>distogram_logits</strong> (<code>torch.FloatTensor</code>) \u2014 Input logits to the distogram used to compute residue distances.</li>
<li><strong>lm_logits</strong> (<code>torch.FloatTensor</code>) \u2014 Logits output by the ESM-2 protein language model stem.</li>
<li><strong>aatype</strong> (<code>torch.FloatTensor</code>) \u2014 Input amino acids (AlphaFold2 indices).</li>
<li><strong>atom14_atom_exists</strong> (<code>torch.FloatTensor</code>) \u2014 Whether each atom exists in the atom14 representation.</li>
<li><strong>residx_atom14_to_atom37</strong> (<code>torch.FloatTensor</code>) \u2014 Mapping between atoms in the atom14 and atom37 representations.</li>
<li><strong>residx_atom37_to_atom14</strong> (<code>torch.FloatTensor</code>) \u2014 Mapping between atoms in the atom37 and atom14 representations.</li>
<li><strong>atom37_atom_exists</strong> (<code>torch.FloatTensor</code>) \u2014 Whether each atom exists in the atom37 representation.</li>
<li><strong>residue_index</strong> (<code>torch.FloatTensor</code>) \u2014 The index of each residue in the protein chain. Unless internal padding tokens are used, this will just be
a sequence of integers from 0 to <code>sequence_length</code>.</li>
<li><strong>lddt_head</strong> (<code>torch.FloatTensor</code>) \u2014 Raw outputs from the lddt head used to compute plddt.</li>
<li><strong>plddt</strong> (<code>torch.FloatTensor</code>) \u2014 Per-residue confidence scores. Regions of low confidence may indicate areas where the model\u2019s prediction is
uncertain, or where the protein structure is disordered.</li>
<li><strong>ptm_logits</strong> (<code>torch.FloatTensor</code>) \u2014 Raw logits used for computing ptm.</li>
<li><strong>ptm</strong> (<code>torch.FloatTensor</code>) \u2014 TM-score output representing the model\u2019s high-level confidence in the overall structure.</li>
<li><strong>aligned_confidence_probs</strong> (<code>torch.FloatTensor</code>) \u2014 Per-residue confidence scores for the aligned structure.</li>
<li><strong>predicted_aligned_error</strong> (<code>torch.FloatTensor</code>) \u2014 Predicted error between the model\u2019s prediction and the ground truth.</li>
<li><strong>max_predicted_aligned_error</strong> (<code>torch.FloatTensor</code>) \u2014 Per-sample maximum predicted error.</li>
</ul>
`,returnType:`
<p><code>transformers.models.esm.modeling_esmfold.EsmForProteinFoldingOutput</code> or <code>tuple(torch.FloatTensor)</code></p>
`}}),_t=new Be({props:{$$slots:{default:[Bf]},$$scope:{ctx:F}}}),kt=new Z({props:{anchor:"transformers.EsmForProteinFolding.forward.example",$$slots:{default:[Zf]},$$scope:{ctx:F}}}),Io=new B({}),Uo=new z({props:{name:"class transformers.TFEsmModel",anchor:"transformers.TFEsmModel",parameters:[{name:"*args",val:""},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.TFEsmModel.config",description:`<strong>config</strong> (<a href="/docs/transformers/v4.29.0/en/model_doc/esm#transformers.EsmConfig">EsmConfig</a>) &#x2014; Model configuration class with all the parameters of the
model. Initializing with a config file does not load the weights associated with the model, only the
configuration. Check out the <a href="/docs/transformers/v4.29.0/en/main_classes/model#transformers.TFPreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/v4.29.0/src/transformers/models/esm/modeling_tf_esm.py#L981"}}),Ko=new z({props:{name:"call",anchor:"transformers.TFEsmModel.call",parameters:[{name:"input_ids",val:": typing.Union[typing.List[tensorflow.python.framework.ops.Tensor], typing.List[numpy.ndarray], typing.List[keras.engine.keras_tensor.KerasTensor], typing.Dict[str, tensorflow.python.framework.ops.Tensor], typing.Dict[str, numpy.ndarray], typing.Dict[str, keras.engine.keras_tensor.KerasTensor], tensorflow.python.framework.ops.Tensor, numpy.ndarray, keras.engine.keras_tensor.KerasTensor, NoneType] = None"},{name:"attention_mask",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"position_ids",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"head_mask",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"inputs_embeds",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"encoder_hidden_states",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"encoder_attention_mask",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"past_key_values",val:": typing.Union[typing.Tuple[typing.Tuple[typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor]]], NoneType] = None"},{name:"use_cache",val:": typing.Optional[bool] = None"},{name:"output_attentions",val:": typing.Optional[bool] = None"},{name:"output_hidden_states",val:": typing.Optional[bool] = None"},{name:"return_dict",val:": typing.Optional[bool] = None"},{name:"training",val:": typing.Optional[bool] = False"}],parametersDescription:[{anchor:"transformers.TFEsmModel.call.input_ids",description:`<strong>input_ids</strong> (<code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>) &#x2014;
Indices of input sequence tokens in the vocabulary.</p>
<p>Indices can be obtained using <a href="/docs/transformers/v4.29.0/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/v4.29.0/en/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/v4.29.0/en/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.TFEsmModel.call.attention_mask",description:`<strong>attention_mask</strong> (<code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Mask to avoid performing attention on padding token indices. Mask values selected in <code>[0, 1]</code>:</p>
<ul>
<li>1 for tokens that are <strong>not masked</strong>,</li>
<li>0 for tokens that are <strong>masked</strong>.</li>
</ul>
<p><a href="../glossary#attention-mask">What are attention masks?</a>`,name:"attention_mask"},{anchor:"transformers.TFEsmModel.call.position_ids",description:`<strong>position_ids</strong> (<code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Indices of positions of each input sequence tokens in the position embeddings. Selected in the range <code>[0, config.max_position_embeddings - 1]</code>.</p>
<p><a href="../glossary#position-ids">What are position IDs?</a>`,name:"position_ids"},{anchor:"transformers.TFEsmModel.call.head_mask",description:`<strong>head_mask</strong> (<code>tf.Tensor</code> of shape <code>(num_heads,)</code> or <code>(num_layers, num_heads)</code>, <em>optional</em>) &#x2014;
Mask to nullify selected heads of the self-attention modules. Mask values selected in <code>[0, 1]</code>:</p>
<ul>
<li>1 indicates the head is <strong>not masked</strong>,</li>
<li>0 indicates the head is <strong>masked</strong>.</li>
</ul>`,name:"head_mask"},{anchor:"transformers.TFEsmModel.call.inputs_embeds",description:`<strong>inputs_embeds</strong> (<code>tf.Tensor</code> of shape <code>(batch_size, sequence_length, hidden_size)</code>, <em>optional</em>) &#x2014;
Optionally, instead of passing <code>input_ids</code> you can choose to directly pass an embedded representation. This
is useful if you want more control over how to convert <code>input_ids</code> indices into associated vectors than the
model&#x2019;s internal embedding lookup matrix.`,name:"inputs_embeds"},{anchor:"transformers.TFEsmModel.call.output_attentions",description:`<strong>output_attentions</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return the attentions tensors of all attention layers. See <code>attentions</code> under returned
tensors for more detail.`,name:"output_attentions"},{anchor:"transformers.TFEsmModel.call.output_hidden_states",description:`<strong>output_hidden_states</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return the hidden states of all layers. See <code>hidden_states</code> under returned tensors for
more detail.`,name:"output_hidden_states"},{anchor:"transformers.TFEsmModel.call.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/v4.29.0/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"},{anchor:"transformers.TFEsmModel.call.encoder_hidden_states",description:`<strong>encoder_hidden_states</strong>  (<code>tf.Tensor</code> of shape <code>(batch_size, sequence_length, hidden_size)</code>, <em>optional</em>) &#x2014;
Sequence of hidden-states at the output of the last layer of the encoder. Used in the cross-attention if
the model is configured as a decoder.`,name:"encoder_hidden_states"},{anchor:"transformers.TFEsmModel.call.encoder_attention_mask",description:`<strong>encoder_attention_mask</strong> (<code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Mask to avoid performing attention on the padding token indices of the encoder input. This mask is used in
the cross-attention if the model is configured as a decoder. Mask values selected in <code>[0, 1]</code>:</p>
<ul>
<li>1 for tokens that are <strong>not masked</strong>,</li>
<li>0 for tokens that are <strong>masked</strong>.</li>
</ul>`,name:"encoder_attention_mask"},{anchor:"transformers.TFEsmModel.call.past_key_values",description:`<strong>past_key_values</strong> (<code>Tuple[Tuple[tf.Tensor]]</code> of length <code>config.n_layers</code>) &#x2014;
contains precomputed key and value hidden states of the attention blocks. Can be used to speed up decoding.
If <code>past_key_values</code> are used, the user can optionally input only the last <code>decoder_input_ids</code> (those that
don&#x2019;t have their past key value states given to this model) of shape <code>(batch_size, 1)</code> instead of all
<code>decoder_input_ids</code> of shape <code>(batch_size, sequence_length)</code>.`,name:"past_key_values"},{anchor:"transformers.TFEsmModel.call.use_cache",description:`<strong>use_cache</strong> (<code>bool</code>, <em>optional</em>, defaults to <code>True</code>) &#x2014;
If set to <code>True</code>, <code>past_key_values</code> key value states are returned and can be used to speed up decoding (see
<code>past_key_values</code>). Set to <code>False</code> during training, <code>True</code> during generation`,name:"use_cache"}],source:"https://github.com/huggingface/transformers/blob/v4.29.0/src/transformers/models/esm/modeling_tf_esm.py#L987",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.29.0/en/main_classes/output#transformers.modeling_tf_outputs.TFBaseModelOutputWithPoolingAndCrossAttentions"
>transformers.modeling_tf_outputs.TFBaseModelOutputWithPoolingAndCrossAttentions</a> or a tuple of <code>tf.Tensor</code> (if
<code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various elements depending on the
configuration (<a
  href="/docs/transformers/v4.29.0/en/model_doc/esm#transformers.EsmConfig"
>EsmConfig</a>) and inputs.</p>
<ul>
<li>
<p><strong>last_hidden_state</strong> (<code>tf.Tensor</code> of shape <code>(batch_size, sequence_length, hidden_size)</code>) \u2014 Sequence of hidden-states at the output of the last layer of the model.</p>
</li>
<li>
<p><strong>pooler_output</strong> (<code>tf.Tensor</code> of shape <code>(batch_size, hidden_size)</code>) \u2014 Last layer hidden-state of the first token of the sequence (classification token) further processed by a
Linear layer and a Tanh activation function. The Linear layer weights are trained from the next sentence
prediction (classification) objective during pretraining.</p>
<p>This output is usually <em>not</em> a good summary of the semantic content of the input, you\u2019re often better with
averaging or pooling the sequence of hidden-states for the whole input sequence.</p>
</li>
<li>
<p><strong>past_key_values</strong> (<code>List[tf.Tensor]</code>, <em>optional</em>, returned when <code>use_cache=True</code> is passed or when <code>config.use_cache=True</code>) \u2014 List of <code>tf.Tensor</code> of length <code>config.n_layers</code>, with each tensor of shape <code>(2, batch_size, num_heads, sequence_length, embed_size_per_head)</code>).</p>
<p>Contains pre-computed hidden-states (key and values in the attention blocks) that can be used (see
<code>past_key_values</code> input) to speed up sequential decoding.</p>
</li>
<li>
<p><strong>hidden_states</strong> (<code>tuple(tf.Tensor)</code>, <em>optional</em>, returned when <code>output_hidden_states=True</code> is passed or when <code>config.output_hidden_states=True</code>) \u2014 Tuple of <code>tf.Tensor</code> (one for the output of the embeddings + one for the output of each layer) of shape
<code>(batch_size, sequence_length, hidden_size)</code>.</p>
<p>Hidden-states of the model at the output of each layer plus the initial embedding outputs.</p>
</li>
<li>
<p><strong>attentions</strong> (<code>tuple(tf.Tensor)</code>, <em>optional</em>, returned when <code>output_attentions=True</code> is passed or when <code>config.output_attentions=True</code>) \u2014 Tuple of <code>tf.Tensor</code> (one for each layer) of shape <code>(batch_size, num_heads, sequence_length, sequence_length)</code>.</p>
<p>Attentions weights after the attention softmax, used to compute the weighted average in the self-attention
heads.</p>
</li>
<li>
<p><strong>cross_attentions</strong> (<code>tuple(tf.Tensor)</code>, <em>optional</em>, returned when <code>output_attentions=True</code> is passed or when <code>config.output_attentions=True</code>) \u2014 Tuple of <code>tf.Tensor</code> (one for each layer) of shape <code>(batch_size, num_heads, sequence_length, sequence_length)</code>.</p>
<p>Attentions weights of the decoder\u2019s cross-attention layer, after the attention softmax, used to compute the
weighted average in the cross-attention heads.</p>
</li>
</ul>
`,returnType:`
<p><a
  href="/docs/transformers/v4.29.0/en/main_classes/output#transformers.modeling_tf_outputs.TFBaseModelOutputWithPoolingAndCrossAttentions"
>transformers.modeling_tf_outputs.TFBaseModelOutputWithPoolingAndCrossAttentions</a> or <code>tuple(tf.Tensor)</code></p>
`}}),vt=new Be({props:{$$slots:{default:[Gf]},$$scope:{ctx:F}}}),Tt=new Z({props:{anchor:"transformers.TFEsmModel.call.example",$$slots:{default:[Jf]},$$scope:{ctx:F}}}),Vo=new B({}),Bo=new z({props:{name:"class transformers.TFEsmForMaskedLM",anchor:"transformers.TFEsmForMaskedLM",parameters:[{name:"*args",val:""},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.TFEsmForMaskedLM.config",description:`<strong>config</strong> (<a href="/docs/transformers/v4.29.0/en/model_doc/esm#transformers.EsmConfig">EsmConfig</a>) &#x2014; Model configuration class with all the parameters of the
model. Initializing with a config file does not load the weights associated with the model, only the
configuration. Check out the <a href="/docs/transformers/v4.29.0/en/main_classes/model#transformers.TFPreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/v4.29.0/src/transformers/models/esm/modeling_tf_esm.py#L1085"}}),Yo=new z({props:{name:"call",anchor:"transformers.TFEsmForMaskedLM.call",parameters:[{name:"input_ids",val:": typing.Union[typing.List[tensorflow.python.framework.ops.Tensor], typing.List[numpy.ndarray], typing.List[keras.engine.keras_tensor.KerasTensor], typing.Dict[str, tensorflow.python.framework.ops.Tensor], typing.Dict[str, numpy.ndarray], typing.Dict[str, keras.engine.keras_tensor.KerasTensor], tensorflow.python.framework.ops.Tensor, numpy.ndarray, keras.engine.keras_tensor.KerasTensor, NoneType] = None"},{name:"attention_mask",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"position_ids",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"head_mask",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"inputs_embeds",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"encoder_hidden_states",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"encoder_attention_mask",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"labels",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"output_attentions",val:": typing.Optional[bool] = None"},{name:"output_hidden_states",val:": typing.Optional[bool] = None"},{name:"return_dict",val:": typing.Optional[bool] = None"},{name:"training",val:": bool = False"}],parametersDescription:[{anchor:"transformers.TFEsmForMaskedLM.call.input_ids",description:`<strong>input_ids</strong> (<code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>) &#x2014;
Indices of input sequence tokens in the vocabulary.</p>
<p>Indices can be obtained using <a href="/docs/transformers/v4.29.0/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/v4.29.0/en/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/v4.29.0/en/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.TFEsmForMaskedLM.call.attention_mask",description:`<strong>attention_mask</strong> (<code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Mask to avoid performing attention on padding token indices. Mask values selected in <code>[0, 1]</code>:</p>
<ul>
<li>1 for tokens that are <strong>not masked</strong>,</li>
<li>0 for tokens that are <strong>masked</strong>.</li>
</ul>
<p><a href="../glossary#attention-mask">What are attention masks?</a>`,name:"attention_mask"},{anchor:"transformers.TFEsmForMaskedLM.call.position_ids",description:`<strong>position_ids</strong> (<code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Indices of positions of each input sequence tokens in the position embeddings. Selected in the range <code>[0, config.max_position_embeddings - 1]</code>.</p>
<p><a href="../glossary#position-ids">What are position IDs?</a>`,name:"position_ids"},{anchor:"transformers.TFEsmForMaskedLM.call.head_mask",description:`<strong>head_mask</strong> (<code>tf.Tensor</code> of shape <code>(num_heads,)</code> or <code>(num_layers, num_heads)</code>, <em>optional</em>) &#x2014;
Mask to nullify selected heads of the self-attention modules. Mask values selected in <code>[0, 1]</code>:</p>
<ul>
<li>1 indicates the head is <strong>not masked</strong>,</li>
<li>0 indicates the head is <strong>masked</strong>.</li>
</ul>`,name:"head_mask"},{anchor:"transformers.TFEsmForMaskedLM.call.inputs_embeds",description:`<strong>inputs_embeds</strong> (<code>tf.Tensor</code> of shape <code>(batch_size, sequence_length, hidden_size)</code>, <em>optional</em>) &#x2014;
Optionally, instead of passing <code>input_ids</code> you can choose to directly pass an embedded representation. This
is useful if you want more control over how to convert <code>input_ids</code> indices into associated vectors than the
model&#x2019;s internal embedding lookup matrix.`,name:"inputs_embeds"},{anchor:"transformers.TFEsmForMaskedLM.call.output_attentions",description:`<strong>output_attentions</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return the attentions tensors of all attention layers. See <code>attentions</code> under returned
tensors for more detail.`,name:"output_attentions"},{anchor:"transformers.TFEsmForMaskedLM.call.output_hidden_states",description:`<strong>output_hidden_states</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return the hidden states of all layers. See <code>hidden_states</code> under returned tensors for
more detail.`,name:"output_hidden_states"},{anchor:"transformers.TFEsmForMaskedLM.call.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/v4.29.0/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"},{anchor:"transformers.TFEsmForMaskedLM.call.labels",description:`<strong>labels</strong> (<code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Labels for computing the masked language modeling loss. Indices should be in <code>[-100, 0, ..., config.vocab_size]</code> (see <code>input_ids</code> docstring) Tokens with indices set to <code>-100</code> are ignored (masked), the
loss is only computed for the tokens with labels in <code>[0, ..., config.vocab_size]</code>`,name:"labels"},{anchor:"transformers.TFEsmForMaskedLM.call.kwargs",description:`<strong>kwargs</strong> (<code>Dict[str, any]</code>, optional, defaults to <em>{}</em>) &#x2014;
Used to hide legacy arguments that have been deprecated.`,name:"kwargs"}],source:"https://github.com/huggingface/transformers/blob/v4.29.0/src/transformers/models/esm/modeling_tf_esm.py#L1115",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.29.0/en/main_classes/output#transformers.modeling_tf_outputs.TFMaskedLMOutput"
>transformers.modeling_tf_outputs.TFMaskedLMOutput</a> or a tuple of <code>tf.Tensor</code> (if
<code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various elements depending on the
configuration (<a
  href="/docs/transformers/v4.29.0/en/model_doc/esm#transformers.EsmConfig"
>EsmConfig</a>) and inputs.</p>
<ul>
<li>
<p><strong>loss</strong> (<code>tf.Tensor</code> of shape <code>(n,)</code>, <em>optional</em>, where n is the number of non-masked labels, returned when <code>labels</code> is provided) \u2014 Masked language modeling (MLM) loss.</p>
</li>
<li>
<p><strong>logits</strong> (<code>tf.Tensor</code> of shape <code>(batch_size, sequence_length, config.vocab_size)</code>) \u2014 Prediction scores of the language modeling head (scores for each vocabulary token before SoftMax).</p>
</li>
<li>
<p><strong>hidden_states</strong> (<code>tuple(tf.Tensor)</code>, <em>optional</em>, returned when <code>output_hidden_states=True</code> is passed or when <code>config.output_hidden_states=True</code>) \u2014 Tuple of <code>tf.Tensor</code> (one for the output of the embeddings + one for the output of each layer) of shape
<code>(batch_size, sequence_length, hidden_size)</code>.</p>
<p>Hidden-states of the model at the output of each layer plus the initial embedding outputs.</p>
</li>
<li>
<p><strong>attentions</strong> (<code>tuple(tf.Tensor)</code>, <em>optional</em>, returned when <code>output_attentions=True</code> is passed or when <code>config.output_attentions=True</code>) \u2014 Tuple of <code>tf.Tensor</code> (one for each layer) of shape <code>(batch_size, num_heads, sequence_length, sequence_length)</code>.</p>
<p>Attentions weights after the attention softmax, used to compute the weighted average in the self-attention
heads.</p>
</li>
</ul>
`,returnType:`
<p><a
  href="/docs/transformers/v4.29.0/en/main_classes/output#transformers.modeling_tf_outputs.TFMaskedLMOutput"
>transformers.modeling_tf_outputs.TFMaskedLMOutput</a> or <code>tuple(tf.Tensor)</code></p>
`}}),wt=new Be({props:{$$slots:{default:[Qf]},$$scope:{ctx:F}}}),$t=new Z({props:{anchor:"transformers.TFEsmForMaskedLM.call.example",$$slots:{default:[Yf]},$$scope:{ctx:F}}}),Et=new Z({props:{anchor:"transformers.TFEsmForMaskedLM.call.example-2",$$slots:{default:[Xf]},$$scope:{ctx:F}}}),Xo=new B({}),en=new z({props:{name:"class transformers.TFEsmForSequenceClassification",anchor:"transformers.TFEsmForSequenceClassification",parameters:[{name:"*args",val:""},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.TFEsmForSequenceClassification.config",description:`<strong>config</strong> (<a href="/docs/transformers/v4.29.0/en/model_doc/esm#transformers.EsmConfig">EsmConfig</a>) &#x2014; Model configuration class with all the parameters of the
model. Initializing with a config file does not load the weights associated with the model, only the
configuration. Check out the <a href="/docs/transformers/v4.29.0/en/main_classes/model#transformers.TFPreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/v4.29.0/src/transformers/models/esm/modeling_tf_esm.py#L1253"}}),sn=new z({props:{name:"call",anchor:"transformers.TFEsmForSequenceClassification.call",parameters:[{name:"input_ids",val:": typing.Union[typing.List[tensorflow.python.framework.ops.Tensor], typing.List[numpy.ndarray], typing.List[keras.engine.keras_tensor.KerasTensor], typing.Dict[str, tensorflow.python.framework.ops.Tensor], typing.Dict[str, numpy.ndarray], typing.Dict[str, keras.engine.keras_tensor.KerasTensor], tensorflow.python.framework.ops.Tensor, numpy.ndarray, keras.engine.keras_tensor.KerasTensor, NoneType] = None"},{name:"attention_mask",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"position_ids",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"head_mask",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"inputs_embeds",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"labels",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"output_attentions",val:": typing.Optional[bool] = None"},{name:"output_hidden_states",val:": typing.Optional[bool] = None"},{name:"return_dict",val:": typing.Optional[bool] = None"},{name:"training",val:": bool = False"}],parametersDescription:[{anchor:"transformers.TFEsmForSequenceClassification.call.input_ids",description:`<strong>input_ids</strong> (<code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>) &#x2014;
Indices of input sequence tokens in the vocabulary.</p>
<p>Indices can be obtained using <a href="/docs/transformers/v4.29.0/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/v4.29.0/en/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/v4.29.0/en/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.TFEsmForSequenceClassification.call.attention_mask",description:`<strong>attention_mask</strong> (<code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Mask to avoid performing attention on padding token indices. Mask values selected in <code>[0, 1]</code>:</p>
<ul>
<li>1 for tokens that are <strong>not masked</strong>,</li>
<li>0 for tokens that are <strong>masked</strong>.</li>
</ul>
<p><a href="../glossary#attention-mask">What are attention masks?</a>`,name:"attention_mask"},{anchor:"transformers.TFEsmForSequenceClassification.call.position_ids",description:`<strong>position_ids</strong> (<code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Indices of positions of each input sequence tokens in the position embeddings. Selected in the range <code>[0, config.max_position_embeddings - 1]</code>.</p>
<p><a href="../glossary#position-ids">What are position IDs?</a>`,name:"position_ids"},{anchor:"transformers.TFEsmForSequenceClassification.call.head_mask",description:`<strong>head_mask</strong> (<code>tf.Tensor</code> of shape <code>(num_heads,)</code> or <code>(num_layers, num_heads)</code>, <em>optional</em>) &#x2014;
Mask to nullify selected heads of the self-attention modules. Mask values selected in <code>[0, 1]</code>:</p>
<ul>
<li>1 indicates the head is <strong>not masked</strong>,</li>
<li>0 indicates the head is <strong>masked</strong>.</li>
</ul>`,name:"head_mask"},{anchor:"transformers.TFEsmForSequenceClassification.call.inputs_embeds",description:`<strong>inputs_embeds</strong> (<code>tf.Tensor</code> of shape <code>(batch_size, sequence_length, hidden_size)</code>, <em>optional</em>) &#x2014;
Optionally, instead of passing <code>input_ids</code> you can choose to directly pass an embedded representation. This
is useful if you want more control over how to convert <code>input_ids</code> indices into associated vectors than the
model&#x2019;s internal embedding lookup matrix.`,name:"inputs_embeds"},{anchor:"transformers.TFEsmForSequenceClassification.call.output_attentions",description:`<strong>output_attentions</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return the attentions tensors of all attention layers. See <code>attentions</code> under returned
tensors for more detail.`,name:"output_attentions"},{anchor:"transformers.TFEsmForSequenceClassification.call.output_hidden_states",description:`<strong>output_hidden_states</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return the hidden states of all layers. See <code>hidden_states</code> under returned tensors for
more detail.`,name:"output_hidden_states"},{anchor:"transformers.TFEsmForSequenceClassification.call.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/v4.29.0/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"},{anchor:"transformers.TFEsmForSequenceClassification.call.labels",description:`<strong>labels</strong> (<code>tf.Tensor</code> of shape <code>(batch_size,)</code>, <em>optional</em>) &#x2014;
Labels for computing the sequence classification/regression loss. Indices should be in <code>[0, ..., config.num_labels - 1]</code>. If <code>config.num_labels == 1</code> a regression loss is computed (Mean-Square loss), If
<code>config.num_labels &gt; 1</code> a classification loss is computed (Cross-Entropy).`,name:"labels"}],source:"https://github.com/huggingface/transformers/blob/v4.29.0/src/transformers/models/esm/modeling_tf_esm.py#L1264",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.29.0/en/main_classes/output#transformers.modeling_tf_outputs.TFSequenceClassifierOutput"
>transformers.modeling_tf_outputs.TFSequenceClassifierOutput</a> or a tuple of <code>tf.Tensor</code> (if
<code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various elements depending on the
configuration (<a
  href="/docs/transformers/v4.29.0/en/model_doc/esm#transformers.EsmConfig"
>EsmConfig</a>) and inputs.</p>
<ul>
<li>
<p><strong>loss</strong> (<code>tf.Tensor</code> of shape <code>(batch_size, )</code>, <em>optional</em>, returned when <code>labels</code> is provided) \u2014 Classification (or regression if config.num_labels==1) loss.</p>
</li>
<li>
<p><strong>logits</strong> (<code>tf.Tensor</code> of shape <code>(batch_size, config.num_labels)</code>) \u2014 Classification (or regression if config.num_labels==1) scores (before SoftMax).</p>
</li>
<li>
<p><strong>hidden_states</strong> (<code>tuple(tf.Tensor)</code>, <em>optional</em>, returned when <code>output_hidden_states=True</code> is passed or when <code>config.output_hidden_states=True</code>) \u2014 Tuple of <code>tf.Tensor</code> (one for the output of the embeddings + one for the output of each layer) of shape
<code>(batch_size, sequence_length, hidden_size)</code>.</p>
<p>Hidden-states of the model at the output of each layer plus the initial embedding outputs.</p>
</li>
<li>
<p><strong>attentions</strong> (<code>tuple(tf.Tensor)</code>, <em>optional</em>, returned when <code>output_attentions=True</code> is passed or when <code>config.output_attentions=True</code>) \u2014 Tuple of <code>tf.Tensor</code> (one for each layer) of shape <code>(batch_size, num_heads, sequence_length, sequence_length)</code>.</p>
<p>Attentions weights after the attention softmax, used to compute the weighted average in the self-attention
heads.</p>
</li>
</ul>
`,returnType:`
<p><a
  href="/docs/transformers/v4.29.0/en/main_classes/output#transformers.modeling_tf_outputs.TFSequenceClassifierOutput"
>transformers.modeling_tf_outputs.TFSequenceClassifierOutput</a> or <code>tuple(tf.Tensor)</code></p>
`}}),Mt=new Be({props:{$$slots:{default:[eu]},$$scope:{ctx:F}}}),zt=new Z({props:{anchor:"transformers.TFEsmForSequenceClassification.call.example",$$slots:{default:[tu]},$$scope:{ctx:F}}}),qt=new Z({props:{anchor:"transformers.TFEsmForSequenceClassification.call.example-2",$$slots:{default:[ou]},$$scope:{ctx:F}}}),an=new B({}),rn=new z({props:{name:"class transformers.TFEsmForTokenClassification",anchor:"transformers.TFEsmForTokenClassification",parameters:[{name:"*args",val:""},{name:"**kwargs",val:""}],parametersDescription:[{anchor:"transformers.TFEsmForTokenClassification.config",description:`<strong>config</strong> (<a href="/docs/transformers/v4.29.0/en/model_doc/esm#transformers.EsmConfig">EsmConfig</a>) &#x2014; Model configuration class with all the parameters of the
model. Initializing with a config file does not load the weights associated with the model, only the
configuration. Check out the <a href="/docs/transformers/v4.29.0/en/main_classes/model#transformers.TFPreTrainedModel.from_pretrained">from_pretrained()</a> method to load the model weights.`,name:"config"}],source:"https://github.com/huggingface/transformers/blob/v4.29.0/src/transformers/models/esm/modeling_tf_esm.py#L1347"}}),mn=new z({props:{name:"call",anchor:"transformers.TFEsmForTokenClassification.call",parameters:[{name:"input_ids",val:": typing.Union[typing.List[tensorflow.python.framework.ops.Tensor], typing.List[numpy.ndarray], typing.List[keras.engine.keras_tensor.KerasTensor], typing.Dict[str, tensorflow.python.framework.ops.Tensor], typing.Dict[str, numpy.ndarray], typing.Dict[str, keras.engine.keras_tensor.KerasTensor], tensorflow.python.framework.ops.Tensor, numpy.ndarray, keras.engine.keras_tensor.KerasTensor, NoneType] = None"},{name:"attention_mask",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"position_ids",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"head_mask",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"inputs_embeds",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"labels",val:": typing.Union[numpy.ndarray, tensorflow.python.framework.ops.Tensor, NoneType] = None"},{name:"output_attentions",val:": typing.Optional[bool] = None"},{name:"output_hidden_states",val:": typing.Optional[bool] = None"},{name:"return_dict",val:": typing.Optional[bool] = None"},{name:"training",val:": bool = False"}],parametersDescription:[{anchor:"transformers.TFEsmForTokenClassification.call.input_ids",description:`<strong>input_ids</strong> (<code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>) &#x2014;
Indices of input sequence tokens in the vocabulary.</p>
<p>Indices can be obtained using <a href="/docs/transformers/v4.29.0/en/model_doc/auto#transformers.AutoTokenizer">AutoTokenizer</a>. See <a href="/docs/transformers/v4.29.0/en/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.encode">PreTrainedTokenizer.encode()</a> and
<a href="/docs/transformers/v4.29.0/en/main_classes/tokenizer#transformers.PreTrainedTokenizerFast.__call__">PreTrainedTokenizer.<strong>call</strong>()</a> for details.</p>
<p><a href="../glossary#input-ids">What are input IDs?</a>`,name:"input_ids"},{anchor:"transformers.TFEsmForTokenClassification.call.attention_mask",description:`<strong>attention_mask</strong> (<code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Mask to avoid performing attention on padding token indices. Mask values selected in <code>[0, 1]</code>:</p>
<ul>
<li>1 for tokens that are <strong>not masked</strong>,</li>
<li>0 for tokens that are <strong>masked</strong>.</li>
</ul>
<p><a href="../glossary#attention-mask">What are attention masks?</a>`,name:"attention_mask"},{anchor:"transformers.TFEsmForTokenClassification.call.position_ids",description:`<strong>position_ids</strong> (<code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Indices of positions of each input sequence tokens in the position embeddings. Selected in the range <code>[0, config.max_position_embeddings - 1]</code>.</p>
<p><a href="../glossary#position-ids">What are position IDs?</a>`,name:"position_ids"},{anchor:"transformers.TFEsmForTokenClassification.call.head_mask",description:`<strong>head_mask</strong> (<code>tf.Tensor</code> of shape <code>(num_heads,)</code> or <code>(num_layers, num_heads)</code>, <em>optional</em>) &#x2014;
Mask to nullify selected heads of the self-attention modules. Mask values selected in <code>[0, 1]</code>:</p>
<ul>
<li>1 indicates the head is <strong>not masked</strong>,</li>
<li>0 indicates the head is <strong>masked</strong>.</li>
</ul>`,name:"head_mask"},{anchor:"transformers.TFEsmForTokenClassification.call.inputs_embeds",description:`<strong>inputs_embeds</strong> (<code>tf.Tensor</code> of shape <code>(batch_size, sequence_length, hidden_size)</code>, <em>optional</em>) &#x2014;
Optionally, instead of passing <code>input_ids</code> you can choose to directly pass an embedded representation. This
is useful if you want more control over how to convert <code>input_ids</code> indices into associated vectors than the
model&#x2019;s internal embedding lookup matrix.`,name:"inputs_embeds"},{anchor:"transformers.TFEsmForTokenClassification.call.output_attentions",description:`<strong>output_attentions</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return the attentions tensors of all attention layers. See <code>attentions</code> under returned
tensors for more detail.`,name:"output_attentions"},{anchor:"transformers.TFEsmForTokenClassification.call.output_hidden_states",description:`<strong>output_hidden_states</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return the hidden states of all layers. See <code>hidden_states</code> under returned tensors for
more detail.`,name:"output_hidden_states"},{anchor:"transformers.TFEsmForTokenClassification.call.return_dict",description:`<strong>return_dict</strong> (<code>bool</code>, <em>optional</em>) &#x2014;
Whether or not to return a <a href="/docs/transformers/v4.29.0/en/main_classes/output#transformers.utils.ModelOutput">ModelOutput</a> instead of a plain tuple.`,name:"return_dict"},{anchor:"transformers.TFEsmForTokenClassification.call.labels",description:`<strong>labels</strong> (<code>tf.Tensor</code> of shape <code>(batch_size, sequence_length)</code>, <em>optional</em>) &#x2014;
Labels for computing the token classification loss. Indices should be in <code>[0, ..., config.num_labels - 1]</code>.`,name:"labels"}],source:"https://github.com/huggingface/transformers/blob/v4.29.0/src/transformers/models/esm/modeling_tf_esm.py#L1359",returnDescription:`
<p>A <a
  href="/docs/transformers/v4.29.0/en/main_classes/output#transformers.modeling_tf_outputs.TFTokenClassifierOutput"
>transformers.modeling_tf_outputs.TFTokenClassifierOutput</a> or a tuple of <code>tf.Tensor</code> (if
<code>return_dict=False</code> is passed or when <code>config.return_dict=False</code>) comprising various elements depending on the
configuration (<a
  href="/docs/transformers/v4.29.0/en/model_doc/esm#transformers.EsmConfig"
>EsmConfig</a>) and inputs.</p>
<ul>
<li>
<p><strong>loss</strong> (<code>tf.Tensor</code> of shape <code>(n,)</code>, <em>optional</em>, where n is the number of unmasked labels, returned when <code>labels</code> is provided)  \u2014 Classification loss.</p>
</li>
<li>
<p><strong>logits</strong> (<code>tf.Tensor</code> of shape <code>(batch_size, sequence_length, config.num_labels)</code>) \u2014 Classification scores (before SoftMax).</p>
</li>
<li>
<p><strong>hidden_states</strong> (<code>tuple(tf.Tensor)</code>, <em>optional</em>, returned when <code>output_hidden_states=True</code> is passed or when <code>config.output_hidden_states=True</code>) \u2014 Tuple of <code>tf.Tensor</code> (one for the output of the embeddings + one for the output of each layer) of shape
<code>(batch_size, sequence_length, hidden_size)</code>.</p>
<p>Hidden-states of the model at the output of each layer plus the initial embedding outputs.</p>
</li>
<li>
<p><strong>attentions</strong> (<code>tuple(tf.Tensor)</code>, <em>optional</em>, returned when <code>output_attentions=True</code> is passed or when <code>config.output_attentions=True</code>) \u2014 Tuple of <code>tf.Tensor</code> (one for each layer) of shape <code>(batch_size, num_heads, sequence_length, sequence_length)</code>.</p>
<p>Attentions weights after the attention softmax, used to compute the weighted average in the self-attention
heads.</p>
</li>
</ul>
`,returnType:`
<p><a
  href="/docs/transformers/v4.29.0/en/main_classes/output#transformers.modeling_tf_outputs.TFTokenClassifierOutput"
>transformers.modeling_tf_outputs.TFTokenClassifierOutput</a> or <code>tuple(tf.Tensor)</code></p>
`}}),Ct=new Be({props:{$$slots:{default:[nu]},$$scope:{ctx:F}}}),jt=new Z({props:{anchor:"transformers.TFEsmForTokenClassification.call.example",$$slots:{default:[su]},$$scope:{ctx:F}}}),Pt=new Z({props:{anchor:"transformers.TFEsmForTokenClassification.call.example-2",$$slots:{default:[au]},$$scope:{ctx:F}}}),{c(){d=n("meta"),k=p(),c=n("h1"),u=n("a"),b=n("span"),v(r.$$.fragment),f=p(),M=n("span"),ni=i("ESM"),Da=p(),ye=n("h2"),Ze=n("a"),ps=n("span"),v(Ot.$$.fragment),si=p(),hs=n("span"),ai=i("Overview"),Oa=i(`

This page provides code and pre-trained weights for Transformer protein language models from Meta AI's Fundamental 
AI Research Team, providing the state-of-the-art ESMFold and ESM-2, and the previously released ESM-1b and ESM-1v.
Transformer protein language models were introduced in the paper [Biological structure and function emerge from scaling
unsupervised learning to 250 million protein sequences](https://www.pnas.org/content/118/15/e2016239118) by 
Alexander Rives, Joshua Meier, Tom Sercu, Siddharth Goyal, Zeming Lin, Jason Liu, Demi Guo, Myle Ott, 
C. Lawrence Zitnick, Jerry Ma, and Rob Fergus.
The first version of this paper was [preprinted in 2019](https://www.biorxiv.org/content/10.1101/622803v1?versioned=true).
`),Ge=n("p"),ri=i(`ESM-2 outperforms all tested single-sequence protein language models across a range of structure prediction tasks,
and enables atomic resolution structure prediction.
It was released with the paper `),It=n("a"),ii=i(`Language models of protein sequences at the scale of evolution enable accurate
structure prediction`),li=i(` by Zeming Lin, Halil Akin, Roshan Rao, Brian Hie,
Zhongkai Zhu, Wenting Lu, Allan dos Santos Costa, Maryam Fazel-Zarandi, Tom Sercu, Sal Candido and Alexander Rives.`),Ia=p(),Je=n("p"),di=i(`Also introduced in this paper was ESMFold. It uses an ESM-2 stem with a head that can predict folded protein
structures with state-of-the-art accuracy. Unlike `),Ut=n("a"),ci=i("AlphaFold2"),mi=i(`,
it relies on the token embeddings from the large pre-trained protein language model stem and does not perform a multiple
sequence alignment (MSA) step at inference time, which means that ESMFold checkpoints are fully \u201Cstandalone\u201D -
they do not require a database of known protein sequences and structures with associated external query tools
to make predictions, and are much faster as a result.`),Ua=p(),gn=n("p"),pi=i(`The abstract from
\u201CBiological structure and function emerge from scaling unsupervised learning to 250
million protein sequences\u201D is`),Ra=p(),_n=n("p"),fs=n("em"),hi=i(`In the field of artificial intelligence, a combination of scale in data and model capacity enabled by unsupervised
learning has led to major advances in representation learning and statistical generation. In the life sciences, the
anticipated growth of sequencing promises unprecedented data on natural sequence diversity. Protein language modeling
at the scale of evolution is a logical step toward predictive and generative artificial intelligence for biology. To
this end, we use unsupervised learning to train a deep contextual language model on 86 billion amino acids across 250
million protein sequences spanning evolutionary diversity. The resulting model contains information about biological
properties in its representations. The representations are learned from sequence data alone. The learned representation
space has a multiscale organization reflecting structure from the level of biochemical properties of amino acids to
remote homology of proteins. Information about secondary and tertiary structure is encoded in the representations and
can be identified by linear projections. Representation learning produces features that generalize across a range of
applications, enabling state-of-the-art supervised prediction of mutational effect and secondary structure and
improving state-of-the-art features for long-range contact prediction.`),Wa=p(),kn=n("p"),fi=i(`The abstract from
\u201CLanguage models of protein sequences at the scale of evolution enable accurate structure prediction\u201D is`),Ha=p(),bn=n("p"),us=n("em"),ui=i(`Large language models have recently been shown to develop emergent capabilities with scale, going beyond
simple pattern matching to perform higher level reasoning and generate lifelike images and text. While
language models trained on protein sequences have been studied at a smaller scale, little is known about
what they learn about biology as they are scaled up. In this work we train models up to 15 billion parameters,
the largest language models of proteins to be evaluated to date. We find that as models are scaled they learn
information enabling the prediction of the three-dimensional structure of a protein at the resolution of
individual atoms. We present ESMFold for high accuracy end-to-end atomic level structure prediction directly
from the individual sequence of a protein. ESMFold has similar accuracy to AlphaFold2 and RoseTTAFold for
sequences with low perplexity that are well understood by the language model. ESMFold inference is an
order of magnitude faster than AlphaFold2, enabling exploration of the structural space of metagenomic
proteins in practical timescales.`),Ka=p(),vn=n("p"),gi=i("Tips:"),Va=p(),Tn=n("ul"),gs=n("li"),_i=i("ESM models are trained with a masked language modeling (MLM) objective."),Ba=p(),Q=n("p"),ki=i("The original code can be found "),Rt=n("a"),bi=i("here"),vi=i(` and was
was developed by the Fundamental AI Research team at Meta AI.
ESM-1b, ESM-1v and ESM-2 were contributed to huggingface by `),Wt=n("a"),Ti=i("jasonliu"),yi=i(`
and `),Ht=n("a"),wi=i("Matt"),$i=i("."),Za=p(),ae=n("p"),Ei=i("ESMFold was contributed to huggingface by "),Kt=n("a"),Fi=i("Matt"),Mi=i(` and
`),Vt=n("a"),zi=i("Sylvain"),qi=i(`, with a big thank you to Nikita Smetanin, Roshan Rao and Tom Sercu for their
help throughout the process!`),Ga=p(),re=n("p"),xi=i("The HuggingFace port of ESMFold uses portions of the "),Bt=n("a"),Ci=i("openfold"),ji=i(` library.
The `),_s=n("code"),Pi=i("openfold"),Si=i(" library is licensed under the Apache License 2.0."),Ja=p(),we=n("h2"),Qe=n("a"),ks=n("span"),v(Zt.$$.fragment),Ai=p(),bs=n("span"),Li=i("Documentation resources"),Qa=p(),ie=n("ul"),vs=n("li"),yn=n("a"),Ni=i("Text classification task guide"),Di=p(),Ts=n("li"),wn=n("a"),Oi=i("Token classification task guide"),Ii=p(),ys=n("li"),$n=n("a"),Ui=i("Masked language modeling task guide"),Ya=p(),$e=n("h2"),Ye=n("a"),ws=n("span"),v(Gt.$$.fragment),Ri=p(),$s=n("span"),Wi=i("EsmConfig"),Xa=p(),j=n("div"),v(Jt.$$.fragment),Hi=p(),Ee=n("p"),Ki=i("This is the configuration class to store the configuration of a "),Es=n("code"),Vi=i("ESMModel"),Bi=i(`. It is used to instantiate a ESM model
according to the specified arguments, defining the model architecture. Instantiating a configuration with the
defaults will yield a similar configuration to that of the ESM
`),Qt=n("a"),Zi=i("facebook/esm-1b"),Gi=i(" architecture."),Ji=p(),Fe=n("p"),Qi=i("Configuration objects inherit from "),En=n("a"),Yi=i("PretrainedConfig"),Xi=i(` and can be used to control the model outputs. Read the
documentation from `),Fn=n("a"),el=i("PretrainedConfig"),tl=i(" for more information."),ol=p(),v(Xe.$$.fragment),nl=p(),et=n("div"),v(Yt.$$.fragment),sl=p(),Xt=n("p"),al=i("Serializes this instance to a Python dictionary. Override the default "),Mn=n("a"),rl=i("to_dict()"),il=i("."),er=p(),Me=n("h2"),tt=n("a"),Fs=n("span"),v(eo.$$.fragment),ll=p(),Ms=n("span"),dl=i("EsmTokenizer"),tr=p(),x=n("div"),v(to.$$.fragment),cl=p(),zs=n("p"),ml=i("Constructs an ESM tokenizer."),pl=p(),zn=n("div"),v(oo.$$.fragment),hl=p(),ot=n("div"),v(no.$$.fragment),fl=p(),ze=n("p"),ul=i(`Retrieves sequence ids from a token list that has no special tokens added. This method is called when adding
special tokens using the tokenizer `),qs=n("code"),gl=i("prepare_for_model"),_l=i(" or "),xs=n("code"),kl=i("encode_plus"),bl=i(" methods."),vl=p(),le=n("div"),v(so.$$.fragment),Tl=p(),qn=n("p"),yl=i("Create the token type IDs corresponding to the sequences passed. "),xn=n("a"),wl=i(`What are token type
IDs?`),$l=p(),Cs=n("p"),El=i("Should be overridden in a subclass if the model has a special way of building those."),Fl=p(),Cn=n("div"),v(ao.$$.fragment),or=p(),qe=n("h2"),nt=n("a"),js=n("span"),v(ro.$$.fragment),Ml=p(),Ps=n("span"),zl=i("EsmModel"),nr=p(),q=n("div"),v(io.$$.fragment),ql=p(),Ss=n("p"),xl=i("The bare ESM Model transformer outputting raw hidden-states without any specific head on top."),Cl=p(),lo=n("p"),jl=i("This model inherits from "),jn=n("a"),Pl=i("PreTrainedModel"),Sl=i(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),Al=p(),co=n("p"),Ll=i("This model is also a PyTorch "),mo=n("a"),Nl=i("torch.nn.Module"),Dl=i(` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),Ol=p(),po=n("p"),Il=i(`The model can behave as an encoder (with only self-attention) as well as a decoder, in which case a layer of
cross-attention is added between the self-attention layers, following the architecture described in `),ho=n("a"),Ul=i(`Attention is
all you need`),Rl=i(` by Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit,
Llion Jones, Aidan N. Gomez, Lukasz Kaiser and Illia Polosukhin.`),Wl=p(),C=n("p"),Hl=i("To behave as an decoder the model needs to be initialized with the "),As=n("code"),Kl=i("is_decoder"),Vl=i(` argument of the configuration set
to `),Ls=n("code"),Bl=i("True"),Zl=i(". To be used in a Seq2Seq model, the model needs to initialized with both "),Ns=n("code"),Gl=i("is_decoder"),Jl=i(` argument and
`),Ds=n("code"),Ql=i("add_cross_attention"),Yl=i(" set to "),Os=n("code"),Xl=i("True"),ed=i("; an "),Is=n("code"),td=i("encoder_hidden_states"),od=i(" is then expected as an input to the forward pass."),nd=p(),Y=n("div"),v(fo.$$.fragment),sd=p(),xe=n("p"),ad=i("The "),Pn=n("a"),rd=i("EsmModel"),id=i(" forward method, overrides the "),Us=n("code"),ld=i("__call__"),dd=i(" special method."),cd=p(),v(st.$$.fragment),md=p(),v(at.$$.fragment),sr=p(),Ce=n("h2"),rt=n("a"),Rs=n("span"),v(uo.$$.fragment),pd=p(),Ws=n("span"),hd=i("EsmForMaskedLM"),ar=p(),P=n("div"),v(go.$$.fragment),fd=p(),_o=n("p"),ud=i("ESM Model with a "),Hs=n("code"),gd=i("language modeling"),_d=i(" head on top."),kd=p(),ko=n("p"),bd=i("This model inherits from "),Sn=n("a"),vd=i("PreTrainedModel"),Td=i(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),yd=p(),bo=n("p"),wd=i("This model is also a PyTorch "),vo=n("a"),$d=i("torch.nn.Module"),Ed=i(` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),Fd=p(),X=n("div"),v(To.$$.fragment),Md=p(),je=n("p"),zd=i("The "),An=n("a"),qd=i("EsmForMaskedLM"),xd=i(" forward method, overrides the "),Ks=n("code"),Cd=i("__call__"),jd=i(" special method."),Pd=p(),v(it.$$.fragment),Sd=p(),v(lt.$$.fragment),rr=p(),Pe=n("h2"),dt=n("a"),Vs=n("span"),v(yo.$$.fragment),Ad=p(),Bs=n("span"),Ld=i("EsmForSequenceClassification"),ir=p(),S=n("div"),v(wo.$$.fragment),Nd=p(),Zs=n("p"),Dd=i(`ESM Model transformer with a sequence classification/regression head on top (a linear layer on top of the pooled
output) e.g. for GLUE tasks.`),Od=p(),$o=n("p"),Id=i("This model inherits from "),Ln=n("a"),Ud=i("PreTrainedModel"),Rd=i(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),Wd=p(),Eo=n("p"),Hd=i("This model is also a PyTorch "),Fo=n("a"),Kd=i("torch.nn.Module"),Vd=i(` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),Bd=p(),U=n("div"),v(Mo.$$.fragment),Zd=p(),Se=n("p"),Gd=i("The "),Nn=n("a"),Jd=i("EsmForSequenceClassification"),Qd=i(" forward method, overrides the "),Gs=n("code"),Yd=i("__call__"),Xd=i(" special method."),ec=p(),v(ct.$$.fragment),tc=p(),v(mt.$$.fragment),oc=p(),v(pt.$$.fragment),lr=p(),Ae=n("h2"),ht=n("a"),Js=n("span"),v(zo.$$.fragment),nc=p(),Qs=n("span"),sc=i("EsmForTokenClassification"),dr=p(),A=n("div"),v(qo.$$.fragment),ac=p(),Ys=n("p"),rc=i(`ESM Model with a token classification head on top (a linear layer on top of the hidden-states output) e.g. for
Named-Entity-Recognition (NER) tasks.`),ic=p(),xo=n("p"),lc=i("This model inherits from "),Dn=n("a"),dc=i("PreTrainedModel"),cc=i(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),mc=p(),Co=n("p"),pc=i("This model is also a PyTorch "),jo=n("a"),hc=i("torch.nn.Module"),fc=i(` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),uc=p(),ee=n("div"),v(Po.$$.fragment),gc=p(),Le=n("p"),_c=i("The "),On=n("a"),kc=i("EsmForTokenClassification"),bc=i(" forward method, overrides the "),Xs=n("code"),vc=i("__call__"),Tc=i(" special method."),yc=p(),v(ft.$$.fragment),wc=p(),v(ut.$$.fragment),cr=p(),Ne=n("h2"),gt=n("a"),ea=n("span"),v(So.$$.fragment),$c=p(),ta=n("span"),Ec=i("EsmForProteinFolding"),mr=p(),L=n("div"),v(Ao.$$.fragment),Fc=p(),oa=n("p"),Mc=i(`ESMForProteinFolding is the HuggingFace port of the original ESMFold model. It consists of an ESM-2 \u201Cstem\u201D followed
by a protein folding \u201Chead\u201D, although unlike most other output heads, this \u201Chead\u201D is similar in size and runtime to
the rest of the model combined! It outputs a dictionary containing predicted structural information about the input
protein(s).`),zc=p(),Lo=n("p"),qc=i("This model inherits from "),In=n("a"),xc=i("PreTrainedModel"),Cc=i(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),jc=p(),No=n("p"),Pc=i("This model is also a PyTorch "),Do=n("a"),Sc=i("torch.nn.Module"),Ac=i(` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),Lc=p(),te=n("div"),v(Oo.$$.fragment),Nc=p(),De=n("p"),Dc=i("The "),Un=n("a"),Oc=i("EsmForProteinFolding"),Ic=i(" forward method, overrides the "),na=n("code"),Uc=i("__call__"),Rc=i(" special method."),Wc=p(),v(_t.$$.fragment),Hc=p(),v(kt.$$.fragment),pr=p(),Oe=n("h2"),bt=n("a"),sa=n("span"),v(Io.$$.fragment),Kc=p(),aa=n("span"),Vc=i("TFEsmModel"),hr=p(),N=n("div"),v(Uo.$$.fragment),Bc=p(),ra=n("p"),Zc=i("The bare ESM Model transformer outputting raw hidden-states without any specific head on top."),Gc=p(),Ro=n("p"),Jc=i("This model inherits from "),Rn=n("a"),Qc=i("TFPreTrainedModel"),Yc=i(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),Xc=p(),Wo=n("p"),em=i("This model is also a Keras "),Ho=n("a"),tm=i("Model"),om=i(` subclass. Use it as a
regular Keras model and refer to the TF/Keras documentation for all matters related to general usage and behavior.`),nm=p(),oe=n("div"),v(Ko.$$.fragment),sm=p(),Ie=n("p"),am=i("The "),Wn=n("a"),rm=i("TFEsmModel"),im=i(" forward method, overrides the "),ia=n("code"),lm=i("__call__"),dm=i(" special method."),cm=p(),v(vt.$$.fragment),mm=p(),v(Tt.$$.fragment),fr=p(),Ue=n("h2"),yt=n("a"),la=n("span"),v(Vo.$$.fragment),pm=p(),da=n("span"),hm=i("TFEsmForMaskedLM"),ur=p(),D=n("div"),v(Bo.$$.fragment),fm=p(),Zo=n("p"),um=i("ESM Model with a "),ca=n("code"),gm=i("language modeling"),_m=i(" head on top."),km=p(),Go=n("p"),bm=i("This model inherits from "),Hn=n("a"),vm=i("TFPreTrainedModel"),Tm=i(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),ym=p(),Jo=n("p"),wm=i("This model is also a Keras "),Qo=n("a"),$m=i("Model"),Em=i(` subclass. Use it as a
regular Keras model and refer to the TF/Keras documentation for all matters related to general usage and behavior.`),Fm=p(),R=n("div"),v(Yo.$$.fragment),Mm=p(),Re=n("p"),zm=i("The "),Kn=n("a"),qm=i("TFEsmForMaskedLM"),xm=i(" forward method, overrides the "),ma=n("code"),Cm=i("__call__"),jm=i(" special method."),Pm=p(),v(wt.$$.fragment),Sm=p(),v($t.$$.fragment),Am=p(),v(Et.$$.fragment),gr=p(),We=n("h2"),Ft=n("a"),pa=n("span"),v(Xo.$$.fragment),Lm=p(),ha=n("span"),Nm=i("TFEsmForSequenceClassification"),_r=p(),O=n("div"),v(en.$$.fragment),Dm=p(),fa=n("p"),Om=i(`ESM Model transformer with a sequence classification/regression head on top (a linear layer on top of the pooled
output) e.g. for GLUE tasks.`),Im=p(),tn=n("p"),Um=i("This model inherits from "),Vn=n("a"),Rm=i("TFPreTrainedModel"),Wm=i(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),Hm=p(),on=n("p"),Km=i("This model is also a Keras "),nn=n("a"),Vm=i("Model"),Bm=i(` subclass. Use it as a
regular Keras model and refer to the TF/Keras documentation for all matters related to general usage and behavior.`),Zm=p(),W=n("div"),v(sn.$$.fragment),Gm=p(),He=n("p"),Jm=i("The "),Bn=n("a"),Qm=i("TFEsmForSequenceClassification"),Ym=i(" forward method, overrides the "),ua=n("code"),Xm=i("__call__"),ep=i(" special method."),tp=p(),v(Mt.$$.fragment),op=p(),v(zt.$$.fragment),np=p(),v(qt.$$.fragment),kr=p(),Ke=n("h2"),xt=n("a"),ga=n("span"),v(an.$$.fragment),sp=p(),_a=n("span"),ap=i("TFEsmForTokenClassification"),br=p(),I=n("div"),v(rn.$$.fragment),rp=p(),ka=n("p"),ip=i(`ESM Model with a token classification head on top (a linear layer on top of the hidden-states output) e.g. for
Named-Entity-Recognition (NER) tasks.`),lp=p(),ln=n("p"),dp=i("This model inherits from "),Zn=n("a"),cp=i("TFPreTrainedModel"),mp=i(`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),pp=p(),dn=n("p"),hp=i("This model is also a Keras "),cn=n("a"),fp=i("Model"),up=i(` subclass. Use it as a
regular Keras model and refer to the TF/Keras documentation for all matters related to general usage and behavior.`),gp=p(),H=n("div"),v(mn.$$.fragment),_p=p(),Ve=n("p"),kp=i("The "),Gn=n("a"),bp=i("TFEsmForTokenClassification"),vp=i(" forward method, overrides the "),ba=n("code"),Tp=i("__call__"),yp=i(" special method."),wp=p(),v(Ct.$$.fragment),$p=p(),v(jt.$$.fragment),Ep=p(),v(Pt.$$.fragment),this.h()},l(t){const g=Af('[data-svelte="svelte-1phssyn"]',document.head);d=s(g,"META",{name:!0,content:!0}),g.forEach(o),k=h(t),c=s(t,"H1",{class:!0});var pn=a(c);u=s(pn,"A",{id:!0,class:!0,href:!0});var va=a(u);b=s(va,"SPAN",{});var Ta=a(b);T(r.$$.fragment,Ta),Ta.forEach(o),va.forEach(o),f=h(pn),M=s(pn,"SPAN",{});var ya=a(M);ni=l(ya,"ESM"),ya.forEach(o),pn.forEach(o),Da=h(t),ye=s(t,"H2",{class:!0});var hn=a(ye);Ze=s(hn,"A",{id:!0,class:!0,href:!0});var wa=a(Ze);ps=s(wa,"SPAN",{});var $a=a(ps);T(Ot.$$.fragment,$a),$a.forEach(o),wa.forEach(o),si=h(hn),hs=s(hn,"SPAN",{});var Ea=a(hs);ai=l(Ea,"Overview"),Ea.forEach(o),hn.forEach(o),Oa=l(t,`

This page provides code and pre-trained weights for Transformer protein language models from Meta AI's Fundamental 
AI Research Team, providing the state-of-the-art ESMFold and ESM-2, and the previously released ESM-1b and ESM-1v.
Transformer protein language models were introduced in the paper [Biological structure and function emerge from scaling
unsupervised learning to 250 million protein sequences](https://www.pnas.org/content/118/15/e2016239118) by 
Alexander Rives, Joshua Meier, Tom Sercu, Siddharth Goyal, Zeming Lin, Jason Liu, Demi Guo, Myle Ott, 
C. Lawrence Zitnick, Jerry Ma, and Rob Fergus.
The first version of this paper was [preprinted in 2019](https://www.biorxiv.org/content/10.1101/622803v1?versioned=true).
`),Ge=s(t,"P",{});var fn=a(Ge);ri=l(fn,`ESM-2 outperforms all tested single-sequence protein language models across a range of structure prediction tasks,
and enables atomic resolution structure prediction.
It was released with the paper `),It=s(fn,"A",{href:!0,rel:!0});var Fa=a(It);ii=l(Fa,`Language models of protein sequences at the scale of evolution enable accurate
structure prediction`),Fa.forEach(o),li=l(fn,` by Zeming Lin, Halil Akin, Roshan Rao, Brian Hie,
Zhongkai Zhu, Wenting Lu, Allan dos Santos Costa, Maryam Fazel-Zarandi, Tom Sercu, Sal Candido and Alexander Rives.`),fn.forEach(o),Ia=h(t),Je=s(t,"P",{});var un=a(Je);di=l(un,`Also introduced in this paper was ESMFold. It uses an ESM-2 stem with a head that can predict folded protein
structures with state-of-the-art accuracy. Unlike `),Ut=s(un,"A",{href:!0,rel:!0});var Ma=a(Ut);ci=l(Ma,"AlphaFold2"),Ma.forEach(o),mi=l(un,`,
it relies on the token embeddings from the large pre-trained protein language model stem and does not perform a multiple
sequence alignment (MSA) step at inference time, which means that ESMFold checkpoints are fully \u201Cstandalone\u201D -
they do not require a database of known protein sequences and structures with associated external query tools
to make predictions, and are much faster as a result.`),un.forEach(o),Ua=h(t),gn=s(t,"P",{});var za=a(gn);pi=l(za,`The abstract from
\u201CBiological structure and function emerge from scaling unsupervised learning to 250
million protein sequences\u201D is`),za.forEach(o),Ra=h(t),_n=s(t,"P",{});var qa=a(_n);fs=s(qa,"EM",{});var xa=a(fs);hi=l(xa,`In the field of artificial intelligence, a combination of scale in data and model capacity enabled by unsupervised
learning has led to major advances in representation learning and statistical generation. In the life sciences, the
anticipated growth of sequencing promises unprecedented data on natural sequence diversity. Protein language modeling
at the scale of evolution is a logical step toward predictive and generative artificial intelligence for biology. To
this end, we use unsupervised learning to train a deep contextual language model on 86 billion amino acids across 250
million protein sequences spanning evolutionary diversity. The resulting model contains information about biological
properties in its representations. The representations are learned from sequence data alone. The learned representation
space has a multiscale organization reflecting structure from the level of biochemical properties of amino acids to
remote homology of proteins. Information about secondary and tertiary structure is encoded in the representations and
can be identified by linear projections. Representation learning produces features that generalize across a range of
applications, enabling state-of-the-art supervised prediction of mutational effect and secondary structure and
improving state-of-the-art features for long-range contact prediction.`),xa.forEach(o),qa.forEach(o),Wa=h(t),kn=s(t,"P",{});var Ca=a(kn);fi=l(Ca,`The abstract from
\u201CLanguage models of protein sequences at the scale of evolution enable accurate structure prediction\u201D is`),Ca.forEach(o),Ha=h(t),bn=s(t,"P",{});var ja=a(bn);us=s(ja,"EM",{});var Pa=a(us);ui=l(Pa,`Large language models have recently been shown to develop emergent capabilities with scale, going beyond
simple pattern matching to perform higher level reasoning and generate lifelike images and text. While
language models trained on protein sequences have been studied at a smaller scale, little is known about
what they learn about biology as they are scaled up. In this work we train models up to 15 billion parameters,
the largest language models of proteins to be evaluated to date. We find that as models are scaled they learn
information enabling the prediction of the three-dimensional structure of a protein at the resolution of
individual atoms. We present ESMFold for high accuracy end-to-end atomic level structure prediction directly
from the individual sequence of a protein. ESMFold has similar accuracy to AlphaFold2 and RoseTTAFold for
sequences with low perplexity that are well understood by the language model. ESMFold inference is an
order of magnitude faster than AlphaFold2, enabling exploration of the structural space of metagenomic
proteins in practical timescales.`),Pa.forEach(o),ja.forEach(o),Ka=h(t),vn=s(t,"P",{});var Sa=a(vn);gi=l(Sa,"Tips:"),Sa.forEach(o),Va=h(t),Tn=s(t,"UL",{});var Aa=a(Tn);gs=s(Aa,"LI",{});var La=a(gs);_i=l(La,"ESM models are trained with a masked language modeling (MLM) objective."),La.forEach(o),Aa.forEach(o),Ba=h(t),Q=s(t,"P",{});var se=a(Q);ki=l(se,"The original code can be found "),Rt=s(se,"A",{href:!0,rel:!0});var Na=a(Rt);bi=l(Na,"here"),Na.forEach(o),vi=l(se,` and was
was developed by the Fundamental AI Research team at Meta AI.
ESM-1b, ESM-1v and ESM-2 were contributed to huggingface by `),Wt=s(se,"A",{href:!0,rel:!0});var Mp=a(Wt);Ti=l(Mp,"jasonliu"),Mp.forEach(o),yi=l(se,`
and `),Ht=s(se,"A",{href:!0,rel:!0});var zp=a(Ht);wi=l(zp,"Matt"),zp.forEach(o),$i=l(se,"."),se.forEach(o),Za=h(t),ae=s(t,"P",{});var Jn=a(ae);Ei=l(Jn,"ESMFold was contributed to huggingface by "),Kt=s(Jn,"A",{href:!0,rel:!0});var qp=a(Kt);Fi=l(qp,"Matt"),qp.forEach(o),Mi=l(Jn,` and
`),Vt=s(Jn,"A",{href:!0,rel:!0});var xp=a(Vt);zi=l(xp,"Sylvain"),xp.forEach(o),qi=l(Jn,`, with a big thank you to Nikita Smetanin, Roshan Rao and Tom Sercu for their
help throughout the process!`),Jn.forEach(o),Ga=h(t),re=s(t,"P",{});var Qn=a(re);xi=l(Qn,"The HuggingFace port of ESMFold uses portions of the "),Bt=s(Qn,"A",{href:!0,rel:!0});var Cp=a(Bt);Ci=l(Cp,"openfold"),Cp.forEach(o),ji=l(Qn,` library.
The `),_s=s(Qn,"CODE",{});var jp=a(_s);Pi=l(jp,"openfold"),jp.forEach(o),Si=l(Qn," library is licensed under the Apache License 2.0."),Qn.forEach(o),Ja=h(t),we=s(t,"H2",{class:!0});var Tr=a(we);Qe=s(Tr,"A",{id:!0,class:!0,href:!0});var Pp=a(Qe);ks=s(Pp,"SPAN",{});var Sp=a(ks);T(Zt.$$.fragment,Sp),Sp.forEach(o),Pp.forEach(o),Ai=h(Tr),bs=s(Tr,"SPAN",{});var Ap=a(bs);Li=l(Ap,"Documentation resources"),Ap.forEach(o),Tr.forEach(o),Qa=h(t),ie=s(t,"UL",{});var Yn=a(ie);vs=s(Yn,"LI",{});var Lp=a(vs);yn=s(Lp,"A",{href:!0});var Np=a(yn);Ni=l(Np,"Text classification task guide"),Np.forEach(o),Lp.forEach(o),Di=h(Yn),Ts=s(Yn,"LI",{});var Dp=a(Ts);wn=s(Dp,"A",{href:!0});var Op=a(wn);Oi=l(Op,"Token classification task guide"),Op.forEach(o),Dp.forEach(o),Ii=h(Yn),ys=s(Yn,"LI",{});var Ip=a(ys);$n=s(Ip,"A",{href:!0});var Up=a($n);Ui=l(Up,"Masked language modeling task guide"),Up.forEach(o),Ip.forEach(o),Yn.forEach(o),Ya=h(t),$e=s(t,"H2",{class:!0});var yr=a($e);Ye=s(yr,"A",{id:!0,class:!0,href:!0});var Rp=a(Ye);ws=s(Rp,"SPAN",{});var Wp=a(ws);T(Gt.$$.fragment,Wp),Wp.forEach(o),Rp.forEach(o),Ri=h(yr),$s=s(yr,"SPAN",{});var Hp=a($s);Wi=l(Hp,"EsmConfig"),Hp.forEach(o),yr.forEach(o),Xa=h(t),j=s(t,"DIV",{class:!0});var de=a(j);T(Jt.$$.fragment,de),Hi=h(de),Ee=s(de,"P",{});var Xn=a(Ee);Ki=l(Xn,"This is the configuration class to store the configuration of a "),Es=s(Xn,"CODE",{});var Kp=a(Es);Vi=l(Kp,"ESMModel"),Kp.forEach(o),Bi=l(Xn,`. It is used to instantiate a ESM model
according to the specified arguments, defining the model architecture. Instantiating a configuration with the
defaults will yield a similar configuration to that of the ESM
`),Qt=s(Xn,"A",{href:!0,rel:!0});var Vp=a(Qt);Zi=l(Vp,"facebook/esm-1b"),Vp.forEach(o),Gi=l(Xn," architecture."),Xn.forEach(o),Ji=h(de),Fe=s(de,"P",{});var es=a(Fe);Qi=l(es,"Configuration objects inherit from "),En=s(es,"A",{href:!0});var Bp=a(En);Yi=l(Bp,"PretrainedConfig"),Bp.forEach(o),Xi=l(es,` and can be used to control the model outputs. Read the
documentation from `),Fn=s(es,"A",{href:!0});var Zp=a(Fn);el=l(Zp,"PretrainedConfig"),Zp.forEach(o),tl=l(es," for more information."),es.forEach(o),ol=h(de),T(Xe.$$.fragment,de),nl=h(de),et=s(de,"DIV",{class:!0});var wr=a(et);T(Yt.$$.fragment,wr),sl=h(wr),Xt=s(wr,"P",{});var $r=a(Xt);al=l($r,"Serializes this instance to a Python dictionary. Override the default "),Mn=s($r,"A",{href:!0});var Gp=a(Mn);rl=l(Gp,"to_dict()"),Gp.forEach(o),il=l($r,"."),$r.forEach(o),wr.forEach(o),de.forEach(o),er=h(t),Me=s(t,"H2",{class:!0});var Er=a(Me);tt=s(Er,"A",{id:!0,class:!0,href:!0});var Jp=a(tt);Fs=s(Jp,"SPAN",{});var Qp=a(Fs);T(eo.$$.fragment,Qp),Qp.forEach(o),Jp.forEach(o),ll=h(Er),Ms=s(Er,"SPAN",{});var Yp=a(Ms);dl=l(Yp,"EsmTokenizer"),Yp.forEach(o),Er.forEach(o),tr=h(t),x=s(t,"DIV",{class:!0});var ne=a(x);T(to.$$.fragment,ne),cl=h(ne),zs=s(ne,"P",{});var Xp=a(zs);ml=l(Xp,"Constructs an ESM tokenizer."),Xp.forEach(o),pl=h(ne),zn=s(ne,"DIV",{class:!0});var eh=a(zn);T(oo.$$.fragment,eh),eh.forEach(o),hl=h(ne),ot=s(ne,"DIV",{class:!0});var Fr=a(ot);T(no.$$.fragment,Fr),fl=h(Fr),ze=s(Fr,"P",{});var ts=a(ze);ul=l(ts,`Retrieves sequence ids from a token list that has no special tokens added. This method is called when adding
special tokens using the tokenizer `),qs=s(ts,"CODE",{});var th=a(qs);gl=l(th,"prepare_for_model"),th.forEach(o),_l=l(ts," or "),xs=s(ts,"CODE",{});var oh=a(xs);kl=l(oh,"encode_plus"),oh.forEach(o),bl=l(ts," methods."),ts.forEach(o),Fr.forEach(o),vl=h(ne),le=s(ne,"DIV",{class:!0});var os=a(le);T(so.$$.fragment,os),Tl=h(os),qn=s(os,"P",{});var Fp=a(qn);yl=l(Fp,"Create the token type IDs corresponding to the sequences passed. "),xn=s(Fp,"A",{href:!0});var nh=a(xn);wl=l(nh,`What are token type
IDs?`),nh.forEach(o),Fp.forEach(o),$l=h(os),Cs=s(os,"P",{});var sh=a(Cs);El=l(sh,"Should be overridden in a subclass if the model has a special way of building those."),sh.forEach(o),os.forEach(o),Fl=h(ne),Cn=s(ne,"DIV",{class:!0});var ah=a(Cn);T(ao.$$.fragment,ah),ah.forEach(o),ne.forEach(o),or=h(t),qe=s(t,"H2",{class:!0});var Mr=a(qe);nt=s(Mr,"A",{id:!0,class:!0,href:!0});var rh=a(nt);js=s(rh,"SPAN",{});var ih=a(js);T(ro.$$.fragment,ih),ih.forEach(o),rh.forEach(o),Ml=h(Mr),Ps=s(Mr,"SPAN",{});var lh=a(Ps);zl=l(lh,"EsmModel"),lh.forEach(o),Mr.forEach(o),nr=h(t),q=s(t,"DIV",{class:!0});var K=a(q);T(io.$$.fragment,K),ql=h(K),Ss=s(K,"P",{});var dh=a(Ss);xl=l(dh,"The bare ESM Model transformer outputting raw hidden-states without any specific head on top."),dh.forEach(o),Cl=h(K),lo=s(K,"P",{});var zr=a(lo);jl=l(zr,"This model inherits from "),jn=s(zr,"A",{href:!0});var ch=a(jn);Pl=l(ch,"PreTrainedModel"),ch.forEach(o),Sl=l(zr,`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),zr.forEach(o),Al=h(K),co=s(K,"P",{});var qr=a(co);Ll=l(qr,"This model is also a PyTorch "),mo=s(qr,"A",{href:!0,rel:!0});var mh=a(mo);Nl=l(mh,"torch.nn.Module"),mh.forEach(o),Dl=l(qr,` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),qr.forEach(o),Ol=h(K),po=s(K,"P",{});var xr=a(po);Il=l(xr,`The model can behave as an encoder (with only self-attention) as well as a decoder, in which case a layer of
cross-attention is added between the self-attention layers, following the architecture described in `),ho=s(xr,"A",{href:!0,rel:!0});var ph=a(ho);Ul=l(ph,`Attention is
all you need`),ph.forEach(o),Rl=l(xr,` by Ashish Vaswani, Noam Shazeer, Niki Parmar, Jakob Uszkoreit,
Llion Jones, Aidan N. Gomez, Lukasz Kaiser and Illia Polosukhin.`),xr.forEach(o),Wl=h(K),C=s(K,"P",{});var V=a(C);Hl=l(V,"To behave as an decoder the model needs to be initialized with the "),As=s(V,"CODE",{});var hh=a(As);Kl=l(hh,"is_decoder"),hh.forEach(o),Vl=l(V,` argument of the configuration set
to `),Ls=s(V,"CODE",{});var fh=a(Ls);Bl=l(fh,"True"),fh.forEach(o),Zl=l(V,". To be used in a Seq2Seq model, the model needs to initialized with both "),Ns=s(V,"CODE",{});var uh=a(Ns);Gl=l(uh,"is_decoder"),uh.forEach(o),Jl=l(V,` argument and
`),Ds=s(V,"CODE",{});var gh=a(Ds);Ql=l(gh,"add_cross_attention"),gh.forEach(o),Yl=l(V," set to "),Os=s(V,"CODE",{});var _h=a(Os);Xl=l(_h,"True"),_h.forEach(o),ed=l(V,"; an "),Is=s(V,"CODE",{});var kh=a(Is);td=l(kh,"encoder_hidden_states"),kh.forEach(o),od=l(V," is then expected as an input to the forward pass."),V.forEach(o),nd=h(K),Y=s(K,"DIV",{class:!0});var St=a(Y);T(fo.$$.fragment,St),sd=h(St),xe=s(St,"P",{});var ns=a(xe);ad=l(ns,"The "),Pn=s(ns,"A",{href:!0});var bh=a(Pn);rd=l(bh,"EsmModel"),bh.forEach(o),id=l(ns," forward method, overrides the "),Us=s(ns,"CODE",{});var vh=a(Us);ld=l(vh,"__call__"),vh.forEach(o),dd=l(ns," special method."),ns.forEach(o),cd=h(St),T(st.$$.fragment,St),md=h(St),T(at.$$.fragment,St),St.forEach(o),K.forEach(o),sr=h(t),Ce=s(t,"H2",{class:!0});var Cr=a(Ce);rt=s(Cr,"A",{id:!0,class:!0,href:!0});var Th=a(rt);Rs=s(Th,"SPAN",{});var yh=a(Rs);T(uo.$$.fragment,yh),yh.forEach(o),Th.forEach(o),pd=h(Cr),Ws=s(Cr,"SPAN",{});var wh=a(Ws);hd=l(wh,"EsmForMaskedLM"),wh.forEach(o),Cr.forEach(o),ar=h(t),P=s(t,"DIV",{class:!0});var ce=a(P);T(go.$$.fragment,ce),fd=h(ce),_o=s(ce,"P",{});var jr=a(_o);ud=l(jr,"ESM Model with a "),Hs=s(jr,"CODE",{});var $h=a(Hs);gd=l($h,"language modeling"),$h.forEach(o),_d=l(jr," head on top."),jr.forEach(o),kd=h(ce),ko=s(ce,"P",{});var Pr=a(ko);bd=l(Pr,"This model inherits from "),Sn=s(Pr,"A",{href:!0});var Eh=a(Sn);vd=l(Eh,"PreTrainedModel"),Eh.forEach(o),Td=l(Pr,`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),Pr.forEach(o),yd=h(ce),bo=s(ce,"P",{});var Sr=a(bo);wd=l(Sr,"This model is also a PyTorch "),vo=s(Sr,"A",{href:!0,rel:!0});var Fh=a(vo);$d=l(Fh,"torch.nn.Module"),Fh.forEach(o),Ed=l(Sr,` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),Sr.forEach(o),Fd=h(ce),X=s(ce,"DIV",{class:!0});var At=a(X);T(To.$$.fragment,At),Md=h(At),je=s(At,"P",{});var ss=a(je);zd=l(ss,"The "),An=s(ss,"A",{href:!0});var Mh=a(An);qd=l(Mh,"EsmForMaskedLM"),Mh.forEach(o),xd=l(ss," forward method, overrides the "),Ks=s(ss,"CODE",{});var zh=a(Ks);Cd=l(zh,"__call__"),zh.forEach(o),jd=l(ss," special method."),ss.forEach(o),Pd=h(At),T(it.$$.fragment,At),Sd=h(At),T(lt.$$.fragment,At),At.forEach(o),ce.forEach(o),rr=h(t),Pe=s(t,"H2",{class:!0});var Ar=a(Pe);dt=s(Ar,"A",{id:!0,class:!0,href:!0});var qh=a(dt);Vs=s(qh,"SPAN",{});var xh=a(Vs);T(yo.$$.fragment,xh),xh.forEach(o),qh.forEach(o),Ad=h(Ar),Bs=s(Ar,"SPAN",{});var Ch=a(Bs);Ld=l(Ch,"EsmForSequenceClassification"),Ch.forEach(o),Ar.forEach(o),ir=h(t),S=s(t,"DIV",{class:!0});var me=a(S);T(wo.$$.fragment,me),Nd=h(me),Zs=s(me,"P",{});var jh=a(Zs);Dd=l(jh,`ESM Model transformer with a sequence classification/regression head on top (a linear layer on top of the pooled
output) e.g. for GLUE tasks.`),jh.forEach(o),Od=h(me),$o=s(me,"P",{});var Lr=a($o);Id=l(Lr,"This model inherits from "),Ln=s(Lr,"A",{href:!0});var Ph=a(Ln);Ud=l(Ph,"PreTrainedModel"),Ph.forEach(o),Rd=l(Lr,`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),Lr.forEach(o),Wd=h(me),Eo=s(me,"P",{});var Nr=a(Eo);Hd=l(Nr,"This model is also a PyTorch "),Fo=s(Nr,"A",{href:!0,rel:!0});var Sh=a(Fo);Kd=l(Sh,"torch.nn.Module"),Sh.forEach(o),Vd=l(Nr,` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),Nr.forEach(o),Bd=h(me),U=s(me,"DIV",{class:!0});var pe=a(U);T(Mo.$$.fragment,pe),Zd=h(pe),Se=s(pe,"P",{});var as=a(Se);Gd=l(as,"The "),Nn=s(as,"A",{href:!0});var Ah=a(Nn);Jd=l(Ah,"EsmForSequenceClassification"),Ah.forEach(o),Qd=l(as," forward method, overrides the "),Gs=s(as,"CODE",{});var Lh=a(Gs);Yd=l(Lh,"__call__"),Lh.forEach(o),Xd=l(as," special method."),as.forEach(o),ec=h(pe),T(ct.$$.fragment,pe),tc=h(pe),T(mt.$$.fragment,pe),oc=h(pe),T(pt.$$.fragment,pe),pe.forEach(o),me.forEach(o),lr=h(t),Ae=s(t,"H2",{class:!0});var Dr=a(Ae);ht=s(Dr,"A",{id:!0,class:!0,href:!0});var Nh=a(ht);Js=s(Nh,"SPAN",{});var Dh=a(Js);T(zo.$$.fragment,Dh),Dh.forEach(o),Nh.forEach(o),nc=h(Dr),Qs=s(Dr,"SPAN",{});var Oh=a(Qs);sc=l(Oh,"EsmForTokenClassification"),Oh.forEach(o),Dr.forEach(o),dr=h(t),A=s(t,"DIV",{class:!0});var he=a(A);T(qo.$$.fragment,he),ac=h(he),Ys=s(he,"P",{});var Ih=a(Ys);rc=l(Ih,`ESM Model with a token classification head on top (a linear layer on top of the hidden-states output) e.g. for
Named-Entity-Recognition (NER) tasks.`),Ih.forEach(o),ic=h(he),xo=s(he,"P",{});var Or=a(xo);lc=l(Or,"This model inherits from "),Dn=s(Or,"A",{href:!0});var Uh=a(Dn);dc=l(Uh,"PreTrainedModel"),Uh.forEach(o),cc=l(Or,`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),Or.forEach(o),mc=h(he),Co=s(he,"P",{});var Ir=a(Co);pc=l(Ir,"This model is also a PyTorch "),jo=s(Ir,"A",{href:!0,rel:!0});var Rh=a(jo);hc=l(Rh,"torch.nn.Module"),Rh.forEach(o),fc=l(Ir,` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),Ir.forEach(o),uc=h(he),ee=s(he,"DIV",{class:!0});var Lt=a(ee);T(Po.$$.fragment,Lt),gc=h(Lt),Le=s(Lt,"P",{});var rs=a(Le);_c=l(rs,"The "),On=s(rs,"A",{href:!0});var Wh=a(On);kc=l(Wh,"EsmForTokenClassification"),Wh.forEach(o),bc=l(rs," forward method, overrides the "),Xs=s(rs,"CODE",{});var Hh=a(Xs);vc=l(Hh,"__call__"),Hh.forEach(o),Tc=l(rs," special method."),rs.forEach(o),yc=h(Lt),T(ft.$$.fragment,Lt),wc=h(Lt),T(ut.$$.fragment,Lt),Lt.forEach(o),he.forEach(o),cr=h(t),Ne=s(t,"H2",{class:!0});var Ur=a(Ne);gt=s(Ur,"A",{id:!0,class:!0,href:!0});var Kh=a(gt);ea=s(Kh,"SPAN",{});var Vh=a(ea);T(So.$$.fragment,Vh),Vh.forEach(o),Kh.forEach(o),$c=h(Ur),ta=s(Ur,"SPAN",{});var Bh=a(ta);Ec=l(Bh,"EsmForProteinFolding"),Bh.forEach(o),Ur.forEach(o),mr=h(t),L=s(t,"DIV",{class:!0});var fe=a(L);T(Ao.$$.fragment,fe),Fc=h(fe),oa=s(fe,"P",{});var Zh=a(oa);Mc=l(Zh,`ESMForProteinFolding is the HuggingFace port of the original ESMFold model. It consists of an ESM-2 \u201Cstem\u201D followed
by a protein folding \u201Chead\u201D, although unlike most other output heads, this \u201Chead\u201D is similar in size and runtime to
the rest of the model combined! It outputs a dictionary containing predicted structural information about the input
protein(s).`),Zh.forEach(o),zc=h(fe),Lo=s(fe,"P",{});var Rr=a(Lo);qc=l(Rr,"This model inherits from "),In=s(Rr,"A",{href:!0});var Gh=a(In);xc=l(Gh,"PreTrainedModel"),Gh.forEach(o),Cc=l(Rr,`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),Rr.forEach(o),jc=h(fe),No=s(fe,"P",{});var Wr=a(No);Pc=l(Wr,"This model is also a PyTorch "),Do=s(Wr,"A",{href:!0,rel:!0});var Jh=a(Do);Sc=l(Jh,"torch.nn.Module"),Jh.forEach(o),Ac=l(Wr,` subclass.
Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage
and behavior.`),Wr.forEach(o),Lc=h(fe),te=s(fe,"DIV",{class:!0});var Nt=a(te);T(Oo.$$.fragment,Nt),Nc=h(Nt),De=s(Nt,"P",{});var is=a(De);Dc=l(is,"The "),Un=s(is,"A",{href:!0});var Qh=a(Un);Oc=l(Qh,"EsmForProteinFolding"),Qh.forEach(o),Ic=l(is," forward method, overrides the "),na=s(is,"CODE",{});var Yh=a(na);Uc=l(Yh,"__call__"),Yh.forEach(o),Rc=l(is," special method."),is.forEach(o),Wc=h(Nt),T(_t.$$.fragment,Nt),Hc=h(Nt),T(kt.$$.fragment,Nt),Nt.forEach(o),fe.forEach(o),pr=h(t),Oe=s(t,"H2",{class:!0});var Hr=a(Oe);bt=s(Hr,"A",{id:!0,class:!0,href:!0});var Xh=a(bt);sa=s(Xh,"SPAN",{});var ef=a(sa);T(Io.$$.fragment,ef),ef.forEach(o),Xh.forEach(o),Kc=h(Hr),aa=s(Hr,"SPAN",{});var tf=a(aa);Vc=l(tf,"TFEsmModel"),tf.forEach(o),Hr.forEach(o),hr=h(t),N=s(t,"DIV",{class:!0});var ue=a(N);T(Uo.$$.fragment,ue),Bc=h(ue),ra=s(ue,"P",{});var of=a(ra);Zc=l(of,"The bare ESM Model transformer outputting raw hidden-states without any specific head on top."),of.forEach(o),Gc=h(ue),Ro=s(ue,"P",{});var Kr=a(Ro);Jc=l(Kr,"This model inherits from "),Rn=s(Kr,"A",{href:!0});var nf=a(Rn);Qc=l(nf,"TFPreTrainedModel"),nf.forEach(o),Yc=l(Kr,`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),Kr.forEach(o),Xc=h(ue),Wo=s(ue,"P",{});var Vr=a(Wo);em=l(Vr,"This model is also a Keras "),Ho=s(Vr,"A",{href:!0,rel:!0});var sf=a(Ho);tm=l(sf,"Model"),sf.forEach(o),om=l(Vr,` subclass. Use it as a
regular Keras model and refer to the TF/Keras documentation for all matters related to general usage and behavior.`),Vr.forEach(o),nm=h(ue),oe=s(ue,"DIV",{class:!0});var Dt=a(oe);T(Ko.$$.fragment,Dt),sm=h(Dt),Ie=s(Dt,"P",{});var ls=a(Ie);am=l(ls,"The "),Wn=s(ls,"A",{href:!0});var af=a(Wn);rm=l(af,"TFEsmModel"),af.forEach(o),im=l(ls," forward method, overrides the "),ia=s(ls,"CODE",{});var rf=a(ia);lm=l(rf,"__call__"),rf.forEach(o),dm=l(ls," special method."),ls.forEach(o),cm=h(Dt),T(vt.$$.fragment,Dt),mm=h(Dt),T(Tt.$$.fragment,Dt),Dt.forEach(o),ue.forEach(o),fr=h(t),Ue=s(t,"H2",{class:!0});var Br=a(Ue);yt=s(Br,"A",{id:!0,class:!0,href:!0});var lf=a(yt);la=s(lf,"SPAN",{});var df=a(la);T(Vo.$$.fragment,df),df.forEach(o),lf.forEach(o),pm=h(Br),da=s(Br,"SPAN",{});var cf=a(da);hm=l(cf,"TFEsmForMaskedLM"),cf.forEach(o),Br.forEach(o),ur=h(t),D=s(t,"DIV",{class:!0});var ge=a(D);T(Bo.$$.fragment,ge),fm=h(ge),Zo=s(ge,"P",{});var Zr=a(Zo);um=l(Zr,"ESM Model with a "),ca=s(Zr,"CODE",{});var mf=a(ca);gm=l(mf,"language modeling"),mf.forEach(o),_m=l(Zr," head on top."),Zr.forEach(o),km=h(ge),Go=s(ge,"P",{});var Gr=a(Go);bm=l(Gr,"This model inherits from "),Hn=s(Gr,"A",{href:!0});var pf=a(Hn);vm=l(pf,"TFPreTrainedModel"),pf.forEach(o),Tm=l(Gr,`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),Gr.forEach(o),ym=h(ge),Jo=s(ge,"P",{});var Jr=a(Jo);wm=l(Jr,"This model is also a Keras "),Qo=s(Jr,"A",{href:!0,rel:!0});var hf=a(Qo);$m=l(hf,"Model"),hf.forEach(o),Em=l(Jr,` subclass. Use it as a
regular Keras model and refer to the TF/Keras documentation for all matters related to general usage and behavior.`),Jr.forEach(o),Fm=h(ge),R=s(ge,"DIV",{class:!0});var _e=a(R);T(Yo.$$.fragment,_e),Mm=h(_e),Re=s(_e,"P",{});var ds=a(Re);zm=l(ds,"The "),Kn=s(ds,"A",{href:!0});var ff=a(Kn);qm=l(ff,"TFEsmForMaskedLM"),ff.forEach(o),xm=l(ds," forward method, overrides the "),ma=s(ds,"CODE",{});var uf=a(ma);Cm=l(uf,"__call__"),uf.forEach(o),jm=l(ds," special method."),ds.forEach(o),Pm=h(_e),T(wt.$$.fragment,_e),Sm=h(_e),T($t.$$.fragment,_e),Am=h(_e),T(Et.$$.fragment,_e),_e.forEach(o),ge.forEach(o),gr=h(t),We=s(t,"H2",{class:!0});var Qr=a(We);Ft=s(Qr,"A",{id:!0,class:!0,href:!0});var gf=a(Ft);pa=s(gf,"SPAN",{});var _f=a(pa);T(Xo.$$.fragment,_f),_f.forEach(o),gf.forEach(o),Lm=h(Qr),ha=s(Qr,"SPAN",{});var kf=a(ha);Nm=l(kf,"TFEsmForSequenceClassification"),kf.forEach(o),Qr.forEach(o),_r=h(t),O=s(t,"DIV",{class:!0});var ke=a(O);T(en.$$.fragment,ke),Dm=h(ke),fa=s(ke,"P",{});var bf=a(fa);Om=l(bf,`ESM Model transformer with a sequence classification/regression head on top (a linear layer on top of the pooled
output) e.g. for GLUE tasks.`),bf.forEach(o),Im=h(ke),tn=s(ke,"P",{});var Yr=a(tn);Um=l(Yr,"This model inherits from "),Vn=s(Yr,"A",{href:!0});var vf=a(Vn);Rm=l(vf,"TFPreTrainedModel"),vf.forEach(o),Wm=l(Yr,`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),Yr.forEach(o),Hm=h(ke),on=s(ke,"P",{});var Xr=a(on);Km=l(Xr,"This model is also a Keras "),nn=s(Xr,"A",{href:!0,rel:!0});var Tf=a(nn);Vm=l(Tf,"Model"),Tf.forEach(o),Bm=l(Xr,` subclass. Use it as a
regular Keras model and refer to the TF/Keras documentation for all matters related to general usage and behavior.`),Xr.forEach(o),Zm=h(ke),W=s(ke,"DIV",{class:!0});var be=a(W);T(sn.$$.fragment,be),Gm=h(be),He=s(be,"P",{});var cs=a(He);Jm=l(cs,"The "),Bn=s(cs,"A",{href:!0});var yf=a(Bn);Qm=l(yf,"TFEsmForSequenceClassification"),yf.forEach(o),Ym=l(cs," forward method, overrides the "),ua=s(cs,"CODE",{});var wf=a(ua);Xm=l(wf,"__call__"),wf.forEach(o),ep=l(cs," special method."),cs.forEach(o),tp=h(be),T(Mt.$$.fragment,be),op=h(be),T(zt.$$.fragment,be),np=h(be),T(qt.$$.fragment,be),be.forEach(o),ke.forEach(o),kr=h(t),Ke=s(t,"H2",{class:!0});var ei=a(Ke);xt=s(ei,"A",{id:!0,class:!0,href:!0});var $f=a(xt);ga=s($f,"SPAN",{});var Ef=a(ga);T(an.$$.fragment,Ef),Ef.forEach(o),$f.forEach(o),sp=h(ei),_a=s(ei,"SPAN",{});var Ff=a(_a);ap=l(Ff,"TFEsmForTokenClassification"),Ff.forEach(o),ei.forEach(o),br=h(t),I=s(t,"DIV",{class:!0});var ve=a(I);T(rn.$$.fragment,ve),rp=h(ve),ka=s(ve,"P",{});var Mf=a(ka);ip=l(Mf,`ESM Model with a token classification head on top (a linear layer on top of the hidden-states output) e.g. for
Named-Entity-Recognition (NER) tasks.`),Mf.forEach(o),lp=h(ve),ln=s(ve,"P",{});var ti=a(ln);dp=l(ti,"This model inherits from "),Zn=s(ti,"A",{href:!0});var zf=a(Zn);cp=l(zf,"TFPreTrainedModel"),zf.forEach(o),mp=l(ti,`. Check the superclass documentation for the generic methods the
library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads
etc.)`),ti.forEach(o),pp=h(ve),dn=s(ve,"P",{});var oi=a(dn);hp=l(oi,"This model is also a Keras "),cn=s(oi,"A",{href:!0,rel:!0});var qf=a(cn);fp=l(qf,"Model"),qf.forEach(o),up=l(oi,` subclass. Use it as a
regular Keras model and refer to the TF/Keras documentation for all matters related to general usage and behavior.`),oi.forEach(o),gp=h(ve),H=s(ve,"DIV",{class:!0});var Te=a(H);T(mn.$$.fragment,Te),_p=h(Te),Ve=s(Te,"P",{});var ms=a(Ve);kp=l(ms,"The "),Gn=s(ms,"A",{href:!0});var xf=a(Gn);bp=l(xf,"TFEsmForTokenClassification"),xf.forEach(o),vp=l(ms," forward method, overrides the "),ba=s(ms,"CODE",{});var Cf=a(ba);Tp=l(Cf,"__call__"),Cf.forEach(o),yp=l(ms," special method."),ms.forEach(o),wp=h(Te),T(Ct.$$.fragment,Te),$p=h(Te),T(jt.$$.fragment,Te),Ep=h(Te),T(Pt.$$.fragment,Te),Te.forEach(o),ve.forEach(o),this.h()},h(){m(d,"name","hf:doc:metadata"),m(d,"content",JSON.stringify(iu)),m(u,"id","esm"),m(u,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),m(u,"href","#esm"),m(c,"class","relative group"),m(Ze,"id","overview"),m(Ze,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),m(Ze,"href","#overview"),m(ye,"class","relative group"),m(It,"href","https://doi.org/10.1101/2022.07.20.500902"),m(It,"rel","nofollow"),m(Ut,"href","https://www.nature.com/articles/s41586-021-03819-2"),m(Ut,"rel","nofollow"),m(Rt,"href","https://github.com/facebookresearch/esm"),m(Rt,"rel","nofollow"),m(Wt,"href","https://huggingface.co/jasonliu"),m(Wt,"rel","nofollow"),m(Ht,"href","https://huggingface.co/Rocketknight1"),m(Ht,"rel","nofollow"),m(Kt,"href","https://huggingface.co/Rocketknight1"),m(Kt,"rel","nofollow"),m(Vt,"href","https://huggingface.co/sgugger"),m(Vt,"rel","nofollow"),m(Bt,"href","https://github.com/aqlaboratory/openfold"),m(Bt,"rel","nofollow"),m(Qe,"id","documentation-resources"),m(Qe,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),m(Qe,"href","#documentation-resources"),m(we,"class","relative group"),m(yn,"href","../tasks/sequence_classification"),m(wn,"href","../tasks/token_classification"),m($n,"href","../tasks/masked_language_modeling"),m(Ye,"id","transformers.EsmConfig"),m(Ye,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),m(Ye,"href","#transformers.EsmConfig"),m($e,"class","relative group"),m(Qt,"href","https://huggingface.co/facebook/esm-1b"),m(Qt,"rel","nofollow"),m(En,"href","/docs/transformers/v4.29.0/en/main_classes/configuration#transformers.PretrainedConfig"),m(Fn,"href","/docs/transformers/v4.29.0/en/main_classes/configuration#transformers.PretrainedConfig"),m(Mn,"href","/docs/transformers/v4.29.0/en/main_classes/configuration#transformers.PretrainedConfig.to_dict"),m(et,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),m(j,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),m(tt,"id","transformers.EsmTokenizer"),m(tt,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),m(tt,"href","#transformers.EsmTokenizer"),m(Me,"class","relative group"),m(zn,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),m(ot,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),m(xn,"href","../glossary#token-type-ids"),m(le,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),m(Cn,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),m(x,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),m(nt,"id","transformers.EsmModel"),m(nt,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),m(nt,"href","#transformers.EsmModel"),m(qe,"class","relative group"),m(jn,"href","/docs/transformers/v4.29.0/en/main_classes/model#transformers.PreTrainedModel"),m(mo,"href","https://pytorch.org/docs/stable/nn.html#torch.nn.Module"),m(mo,"rel","nofollow"),m(ho,"href","https://arxiv.org/abs/1706.03762"),m(ho,"rel","nofollow"),m(Pn,"href","/docs/transformers/v4.29.0/en/model_doc/esm#transformers.EsmModel"),m(Y,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),m(q,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),m(rt,"id","transformers.EsmForMaskedLM"),m(rt,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),m(rt,"href","#transformers.EsmForMaskedLM"),m(Ce,"class","relative group"),m(Sn,"href","/docs/transformers/v4.29.0/en/main_classes/model#transformers.PreTrainedModel"),m(vo,"href","https://pytorch.org/docs/stable/nn.html#torch.nn.Module"),m(vo,"rel","nofollow"),m(An,"href","/docs/transformers/v4.29.0/en/model_doc/esm#transformers.EsmForMaskedLM"),m(X,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),m(P,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),m(dt,"id","transformers.EsmForSequenceClassification"),m(dt,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),m(dt,"href","#transformers.EsmForSequenceClassification"),m(Pe,"class","relative group"),m(Ln,"href","/docs/transformers/v4.29.0/en/main_classes/model#transformers.PreTrainedModel"),m(Fo,"href","https://pytorch.org/docs/stable/nn.html#torch.nn.Module"),m(Fo,"rel","nofollow"),m(Nn,"href","/docs/transformers/v4.29.0/en/model_doc/esm#transformers.EsmForSequenceClassification"),m(U,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),m(S,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),m(ht,"id","transformers.EsmForTokenClassification"),m(ht,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),m(ht,"href","#transformers.EsmForTokenClassification"),m(Ae,"class","relative group"),m(Dn,"href","/docs/transformers/v4.29.0/en/main_classes/model#transformers.PreTrainedModel"),m(jo,"href","https://pytorch.org/docs/stable/nn.html#torch.nn.Module"),m(jo,"rel","nofollow"),m(On,"href","/docs/transformers/v4.29.0/en/model_doc/esm#transformers.EsmForTokenClassification"),m(ee,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),m(A,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),m(gt,"id","transformers.EsmForProteinFolding"),m(gt,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),m(gt,"href","#transformers.EsmForProteinFolding"),m(Ne,"class","relative group"),m(In,"href","/docs/transformers/v4.29.0/en/main_classes/model#transformers.PreTrainedModel"),m(Do,"href","https://pytorch.org/docs/stable/nn.html#torch.nn.Module"),m(Do,"rel","nofollow"),m(Un,"href","/docs/transformers/v4.29.0/en/model_doc/esm#transformers.EsmForProteinFolding"),m(te,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),m(L,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),m(bt,"id","transformers.TFEsmModel"),m(bt,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),m(bt,"href","#transformers.TFEsmModel"),m(Oe,"class","relative group"),m(Rn,"href","/docs/transformers/v4.29.0/en/main_classes/model#transformers.TFPreTrainedModel"),m(Ho,"href","https://www.tensorflow.org/api_docs/python/tf/keras/Model"),m(Ho,"rel","nofollow"),m(Wn,"href","/docs/transformers/v4.29.0/en/model_doc/esm#transformers.TFEsmModel"),m(oe,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),m(N,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),m(yt,"id","transformers.TFEsmForMaskedLM"),m(yt,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),m(yt,"href","#transformers.TFEsmForMaskedLM"),m(Ue,"class","relative group"),m(Hn,"href","/docs/transformers/v4.29.0/en/main_classes/model#transformers.TFPreTrainedModel"),m(Qo,"href","https://www.tensorflow.org/api_docs/python/tf/keras/Model"),m(Qo,"rel","nofollow"),m(Kn,"href","/docs/transformers/v4.29.0/en/model_doc/esm#transformers.TFEsmForMaskedLM"),m(R,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),m(D,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),m(Ft,"id","transformers.TFEsmForSequenceClassification"),m(Ft,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),m(Ft,"href","#transformers.TFEsmForSequenceClassification"),m(We,"class","relative group"),m(Vn,"href","/docs/transformers/v4.29.0/en/main_classes/model#transformers.TFPreTrainedModel"),m(nn,"href","https://www.tensorflow.org/api_docs/python/tf/keras/Model"),m(nn,"rel","nofollow"),m(Bn,"href","/docs/transformers/v4.29.0/en/model_doc/esm#transformers.TFEsmForSequenceClassification"),m(W,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),m(O,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),m(xt,"id","transformers.TFEsmForTokenClassification"),m(xt,"class","header-link block pr-1.5 text-lg no-hover:hidden with-hover:absolute with-hover:p-1.5 with-hover:opacity-0 with-hover:group-hover:opacity-100 with-hover:right-full"),m(xt,"href","#transformers.TFEsmForTokenClassification"),m(Ke,"class","relative group"),m(Zn,"href","/docs/transformers/v4.29.0/en/main_classes/model#transformers.TFPreTrainedModel"),m(cn,"href","https://www.tensorflow.org/api_docs/python/tf/keras/Model"),m(cn,"rel","nofollow"),m(Gn,"href","/docs/transformers/v4.29.0/en/model_doc/esm#transformers.TFEsmForTokenClassification"),m(H,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8"),m(I,"class","docstring border-l-2 border-t-2 pl-4 pt-3.5 border-gray-100 rounded-tl-xl mb-6 mt-8")},m(t,g){e(document.head,d),_(t,k,g),_(t,c,g),e(c,u),e(u,b),y(r,b,null),e(c,f),e(c,M),e(M,ni),_(t,Da,g),_(t,ye,g),e(ye,Ze),e(Ze,ps),y(Ot,ps,null),e(ye,si),e(ye,hs),e(hs,ai),_(t,Oa,g),_(t,Ge,g),e(Ge,ri),e(Ge,It),e(It,ii),e(Ge,li),_(t,Ia,g),_(t,Je,g),e(Je,di),e(Je,Ut),e(Ut,ci),e(Je,mi),_(t,Ua,g),_(t,gn,g),e(gn,pi),_(t,Ra,g),_(t,_n,g),e(_n,fs),e(fs,hi),_(t,Wa,g),_(t,kn,g),e(kn,fi),_(t,Ha,g),_(t,bn,g),e(bn,us),e(us,ui),_(t,Ka,g),_(t,vn,g),e(vn,gi),_(t,Va,g),_(t,Tn,g),e(Tn,gs),e(gs,_i),_(t,Ba,g),_(t,Q,g),e(Q,ki),e(Q,Rt),e(Rt,bi),e(Q,vi),e(Q,Wt),e(Wt,Ti),e(Q,yi),e(Q,Ht),e(Ht,wi),e(Q,$i),_(t,Za,g),_(t,ae,g),e(ae,Ei),e(ae,Kt),e(Kt,Fi),e(ae,Mi),e(ae,Vt),e(Vt,zi),e(ae,qi),_(t,Ga,g),_(t,re,g),e(re,xi),e(re,Bt),e(Bt,Ci),e(re,ji),e(re,_s),e(_s,Pi),e(re,Si),_(t,Ja,g),_(t,we,g),e(we,Qe),e(Qe,ks),y(Zt,ks,null),e(we,Ai),e(we,bs),e(bs,Li),_(t,Qa,g),_(t,ie,g),e(ie,vs),e(vs,yn),e(yn,Ni),e(ie,Di),e(ie,Ts),e(Ts,wn),e(wn,Oi),e(ie,Ii),e(ie,ys),e(ys,$n),e($n,Ui),_(t,Ya,g),_(t,$e,g),e($e,Ye),e(Ye,ws),y(Gt,ws,null),e($e,Ri),e($e,$s),e($s,Wi),_(t,Xa,g),_(t,j,g),y(Jt,j,null),e(j,Hi),e(j,Ee),e(Ee,Ki),e(Ee,Es),e(Es,Vi),e(Ee,Bi),e(Ee,Qt),e(Qt,Zi),e(Ee,Gi),e(j,Ji),e(j,Fe),e(Fe,Qi),e(Fe,En),e(En,Yi),e(Fe,Xi),e(Fe,Fn),e(Fn,el),e(Fe,tl),e(j,ol),y(Xe,j,null),e(j,nl),e(j,et),y(Yt,et,null),e(et,sl),e(et,Xt),e(Xt,al),e(Xt,Mn),e(Mn,rl),e(Xt,il),_(t,er,g),_(t,Me,g),e(Me,tt),e(tt,Fs),y(eo,Fs,null),e(Me,ll),e(Me,Ms),e(Ms,dl),_(t,tr,g),_(t,x,g),y(to,x,null),e(x,cl),e(x,zs),e(zs,ml),e(x,pl),e(x,zn),y(oo,zn,null),e(x,hl),e(x,ot),y(no,ot,null),e(ot,fl),e(ot,ze),e(ze,ul),e(ze,qs),e(qs,gl),e(ze,_l),e(ze,xs),e(xs,kl),e(ze,bl),e(x,vl),e(x,le),y(so,le,null),e(le,Tl),e(le,qn),e(qn,yl),e(qn,xn),e(xn,wl),e(le,$l),e(le,Cs),e(Cs,El),e(x,Fl),e(x,Cn),y(ao,Cn,null),_(t,or,g),_(t,qe,g),e(qe,nt),e(nt,js),y(ro,js,null),e(qe,Ml),e(qe,Ps),e(Ps,zl),_(t,nr,g),_(t,q,g),y(io,q,null),e(q,ql),e(q,Ss),e(Ss,xl),e(q,Cl),e(q,lo),e(lo,jl),e(lo,jn),e(jn,Pl),e(lo,Sl),e(q,Al),e(q,co),e(co,Ll),e(co,mo),e(mo,Nl),e(co,Dl),e(q,Ol),e(q,po),e(po,Il),e(po,ho),e(ho,Ul),e(po,Rl),e(q,Wl),e(q,C),e(C,Hl),e(C,As),e(As,Kl),e(C,Vl),e(C,Ls),e(Ls,Bl),e(C,Zl),e(C,Ns),e(Ns,Gl),e(C,Jl),e(C,Ds),e(Ds,Ql),e(C,Yl),e(C,Os),e(Os,Xl),e(C,ed),e(C,Is),e(Is,td),e(C,od),e(q,nd),e(q,Y),y(fo,Y,null),e(Y,sd),e(Y,xe),e(xe,ad),e(xe,Pn),e(Pn,rd),e(xe,id),e(xe,Us),e(Us,ld),e(xe,dd),e(Y,cd),y(st,Y,null),e(Y,md),y(at,Y,null),_(t,sr,g),_(t,Ce,g),e(Ce,rt),e(rt,Rs),y(uo,Rs,null),e(Ce,pd),e(Ce,Ws),e(Ws,hd),_(t,ar,g),_(t,P,g),y(go,P,null),e(P,fd),e(P,_o),e(_o,ud),e(_o,Hs),e(Hs,gd),e(_o,_d),e(P,kd),e(P,ko),e(ko,bd),e(ko,Sn),e(Sn,vd),e(ko,Td),e(P,yd),e(P,bo),e(bo,wd),e(bo,vo),e(vo,$d),e(bo,Ed),e(P,Fd),e(P,X),y(To,X,null),e(X,Md),e(X,je),e(je,zd),e(je,An),e(An,qd),e(je,xd),e(je,Ks),e(Ks,Cd),e(je,jd),e(X,Pd),y(it,X,null),e(X,Sd),y(lt,X,null),_(t,rr,g),_(t,Pe,g),e(Pe,dt),e(dt,Vs),y(yo,Vs,null),e(Pe,Ad),e(Pe,Bs),e(Bs,Ld),_(t,ir,g),_(t,S,g),y(wo,S,null),e(S,Nd),e(S,Zs),e(Zs,Dd),e(S,Od),e(S,$o),e($o,Id),e($o,Ln),e(Ln,Ud),e($o,Rd),e(S,Wd),e(S,Eo),e(Eo,Hd),e(Eo,Fo),e(Fo,Kd),e(Eo,Vd),e(S,Bd),e(S,U),y(Mo,U,null),e(U,Zd),e(U,Se),e(Se,Gd),e(Se,Nn),e(Nn,Jd),e(Se,Qd),e(Se,Gs),e(Gs,Yd),e(Se,Xd),e(U,ec),y(ct,U,null),e(U,tc),y(mt,U,null),e(U,oc),y(pt,U,null),_(t,lr,g),_(t,Ae,g),e(Ae,ht),e(ht,Js),y(zo,Js,null),e(Ae,nc),e(Ae,Qs),e(Qs,sc),_(t,dr,g),_(t,A,g),y(qo,A,null),e(A,ac),e(A,Ys),e(Ys,rc),e(A,ic),e(A,xo),e(xo,lc),e(xo,Dn),e(Dn,dc),e(xo,cc),e(A,mc),e(A,Co),e(Co,pc),e(Co,jo),e(jo,hc),e(Co,fc),e(A,uc),e(A,ee),y(Po,ee,null),e(ee,gc),e(ee,Le),e(Le,_c),e(Le,On),e(On,kc),e(Le,bc),e(Le,Xs),e(Xs,vc),e(Le,Tc),e(ee,yc),y(ft,ee,null),e(ee,wc),y(ut,ee,null),_(t,cr,g),_(t,Ne,g),e(Ne,gt),e(gt,ea),y(So,ea,null),e(Ne,$c),e(Ne,ta),e(ta,Ec),_(t,mr,g),_(t,L,g),y(Ao,L,null),e(L,Fc),e(L,oa),e(oa,Mc),e(L,zc),e(L,Lo),e(Lo,qc),e(Lo,In),e(In,xc),e(Lo,Cc),e(L,jc),e(L,No),e(No,Pc),e(No,Do),e(Do,Sc),e(No,Ac),e(L,Lc),e(L,te),y(Oo,te,null),e(te,Nc),e(te,De),e(De,Dc),e(De,Un),e(Un,Oc),e(De,Ic),e(De,na),e(na,Uc),e(De,Rc),e(te,Wc),y(_t,te,null),e(te,Hc),y(kt,te,null),_(t,pr,g),_(t,Oe,g),e(Oe,bt),e(bt,sa),y(Io,sa,null),e(Oe,Kc),e(Oe,aa),e(aa,Vc),_(t,hr,g),_(t,N,g),y(Uo,N,null),e(N,Bc),e(N,ra),e(ra,Zc),e(N,Gc),e(N,Ro),e(Ro,Jc),e(Ro,Rn),e(Rn,Qc),e(Ro,Yc),e(N,Xc),e(N,Wo),e(Wo,em),e(Wo,Ho),e(Ho,tm),e(Wo,om),e(N,nm),e(N,oe),y(Ko,oe,null),e(oe,sm),e(oe,Ie),e(Ie,am),e(Ie,Wn),e(Wn,rm),e(Ie,im),e(Ie,ia),e(ia,lm),e(Ie,dm),e(oe,cm),y(vt,oe,null),e(oe,mm),y(Tt,oe,null),_(t,fr,g),_(t,Ue,g),e(Ue,yt),e(yt,la),y(Vo,la,null),e(Ue,pm),e(Ue,da),e(da,hm),_(t,ur,g),_(t,D,g),y(Bo,D,null),e(D,fm),e(D,Zo),e(Zo,um),e(Zo,ca),e(ca,gm),e(Zo,_m),e(D,km),e(D,Go),e(Go,bm),e(Go,Hn),e(Hn,vm),e(Go,Tm),e(D,ym),e(D,Jo),e(Jo,wm),e(Jo,Qo),e(Qo,$m),e(Jo,Em),e(D,Fm),e(D,R),y(Yo,R,null),e(R,Mm),e(R,Re),e(Re,zm),e(Re,Kn),e(Kn,qm),e(Re,xm),e(Re,ma),e(ma,Cm),e(Re,jm),e(R,Pm),y(wt,R,null),e(R,Sm),y($t,R,null),e(R,Am),y(Et,R,null),_(t,gr,g),_(t,We,g),e(We,Ft),e(Ft,pa),y(Xo,pa,null),e(We,Lm),e(We,ha),e(ha,Nm),_(t,_r,g),_(t,O,g),y(en,O,null),e(O,Dm),e(O,fa),e(fa,Om),e(O,Im),e(O,tn),e(tn,Um),e(tn,Vn),e(Vn,Rm),e(tn,Wm),e(O,Hm),e(O,on),e(on,Km),e(on,nn),e(nn,Vm),e(on,Bm),e(O,Zm),e(O,W),y(sn,W,null),e(W,Gm),e(W,He),e(He,Jm),e(He,Bn),e(Bn,Qm),e(He,Ym),e(He,ua),e(ua,Xm),e(He,ep),e(W,tp),y(Mt,W,null),e(W,op),y(zt,W,null),e(W,np),y(qt,W,null),_(t,kr,g),_(t,Ke,g),e(Ke,xt),e(xt,ga),y(an,ga,null),e(Ke,sp),e(Ke,_a),e(_a,ap),_(t,br,g),_(t,I,g),y(rn,I,null),e(I,rp),e(I,ka),e(ka,ip),e(I,lp),e(I,ln),e(ln,dp),e(ln,Zn),e(Zn,cp),e(ln,mp),e(I,pp),e(I,dn),e(dn,hp),e(dn,cn),e(cn,fp),e(dn,up),e(I,gp),e(I,H),y(mn,H,null),e(H,_p),e(H,Ve),e(Ve,kp),e(Ve,Gn),e(Gn,bp),e(Ve,vp),e(Ve,ba),e(ba,Tp),e(Ve,yp),e(H,wp),y(Ct,H,null),e(H,$p),y(jt,H,null),e(H,Ep),y(Pt,H,null),vr=!0},p(t,[g]){const pn={};g&2&&(pn.$$scope={dirty:g,ctx:t}),Xe.$set(pn);const va={};g&2&&(va.$$scope={dirty:g,ctx:t}),st.$set(va);const Ta={};g&2&&(Ta.$$scope={dirty:g,ctx:t}),at.$set(Ta);const ya={};g&2&&(ya.$$scope={dirty:g,ctx:t}),it.$set(ya);const hn={};g&2&&(hn.$$scope={dirty:g,ctx:t}),lt.$set(hn);const wa={};g&2&&(wa.$$scope={dirty:g,ctx:t}),ct.$set(wa);const $a={};g&2&&($a.$$scope={dirty:g,ctx:t}),mt.$set($a);const Ea={};g&2&&(Ea.$$scope={dirty:g,ctx:t}),pt.$set(Ea);const fn={};g&2&&(fn.$$scope={dirty:g,ctx:t}),ft.$set(fn);const Fa={};g&2&&(Fa.$$scope={dirty:g,ctx:t}),ut.$set(Fa);const un={};g&2&&(un.$$scope={dirty:g,ctx:t}),_t.$set(un);const Ma={};g&2&&(Ma.$$scope={dirty:g,ctx:t}),kt.$set(Ma);const za={};g&2&&(za.$$scope={dirty:g,ctx:t}),vt.$set(za);const qa={};g&2&&(qa.$$scope={dirty:g,ctx:t}),Tt.$set(qa);const xa={};g&2&&(xa.$$scope={dirty:g,ctx:t}),wt.$set(xa);const Ca={};g&2&&(Ca.$$scope={dirty:g,ctx:t}),$t.$set(Ca);const ja={};g&2&&(ja.$$scope={dirty:g,ctx:t}),Et.$set(ja);const Pa={};g&2&&(Pa.$$scope={dirty:g,ctx:t}),Mt.$set(Pa);const Sa={};g&2&&(Sa.$$scope={dirty:g,ctx:t}),zt.$set(Sa);const Aa={};g&2&&(Aa.$$scope={dirty:g,ctx:t}),qt.$set(Aa);const La={};g&2&&(La.$$scope={dirty:g,ctx:t}),Ct.$set(La);const se={};g&2&&(se.$$scope={dirty:g,ctx:t}),jt.$set(se);const Na={};g&2&&(Na.$$scope={dirty:g,ctx:t}),Pt.$set(Na)},i(t){vr||(w(r.$$.fragment,t),w(Ot.$$.fragment,t),w(Zt.$$.fragment,t),w(Gt.$$.fragment,t),w(Jt.$$.fragment,t),w(Xe.$$.fragment,t),w(Yt.$$.fragment,t),w(eo.$$.fragment,t),w(to.$$.fragment,t),w(oo.$$.fragment,t),w(no.$$.fragment,t),w(so.$$.fragment,t),w(ao.$$.fragment,t),w(ro.$$.fragment,t),w(io.$$.fragment,t),w(fo.$$.fragment,t),w(st.$$.fragment,t),w(at.$$.fragment,t),w(uo.$$.fragment,t),w(go.$$.fragment,t),w(To.$$.fragment,t),w(it.$$.fragment,t),w(lt.$$.fragment,t),w(yo.$$.fragment,t),w(wo.$$.fragment,t),w(Mo.$$.fragment,t),w(ct.$$.fragment,t),w(mt.$$.fragment,t),w(pt.$$.fragment,t),w(zo.$$.fragment,t),w(qo.$$.fragment,t),w(Po.$$.fragment,t),w(ft.$$.fragment,t),w(ut.$$.fragment,t),w(So.$$.fragment,t),w(Ao.$$.fragment,t),w(Oo.$$.fragment,t),w(_t.$$.fragment,t),w(kt.$$.fragment,t),w(Io.$$.fragment,t),w(Uo.$$.fragment,t),w(Ko.$$.fragment,t),w(vt.$$.fragment,t),w(Tt.$$.fragment,t),w(Vo.$$.fragment,t),w(Bo.$$.fragment,t),w(Yo.$$.fragment,t),w(wt.$$.fragment,t),w($t.$$.fragment,t),w(Et.$$.fragment,t),w(Xo.$$.fragment,t),w(en.$$.fragment,t),w(sn.$$.fragment,t),w(Mt.$$.fragment,t),w(zt.$$.fragment,t),w(qt.$$.fragment,t),w(an.$$.fragment,t),w(rn.$$.fragment,t),w(mn.$$.fragment,t),w(Ct.$$.fragment,t),w(jt.$$.fragment,t),w(Pt.$$.fragment,t),vr=!0)},o(t){$(r.$$.fragment,t),$(Ot.$$.fragment,t),$(Zt.$$.fragment,t),$(Gt.$$.fragment,t),$(Jt.$$.fragment,t),$(Xe.$$.fragment,t),$(Yt.$$.fragment,t),$(eo.$$.fragment,t),$(to.$$.fragment,t),$(oo.$$.fragment,t),$(no.$$.fragment,t),$(so.$$.fragment,t),$(ao.$$.fragment,t),$(ro.$$.fragment,t),$(io.$$.fragment,t),$(fo.$$.fragment,t),$(st.$$.fragment,t),$(at.$$.fragment,t),$(uo.$$.fragment,t),$(go.$$.fragment,t),$(To.$$.fragment,t),$(it.$$.fragment,t),$(lt.$$.fragment,t),$(yo.$$.fragment,t),$(wo.$$.fragment,t),$(Mo.$$.fragment,t),$(ct.$$.fragment,t),$(mt.$$.fragment,t),$(pt.$$.fragment,t),$(zo.$$.fragment,t),$(qo.$$.fragment,t),$(Po.$$.fragment,t),$(ft.$$.fragment,t),$(ut.$$.fragment,t),$(So.$$.fragment,t),$(Ao.$$.fragment,t),$(Oo.$$.fragment,t),$(_t.$$.fragment,t),$(kt.$$.fragment,t),$(Io.$$.fragment,t),$(Uo.$$.fragment,t),$(Ko.$$.fragment,t),$(vt.$$.fragment,t),$(Tt.$$.fragment,t),$(Vo.$$.fragment,t),$(Bo.$$.fragment,t),$(Yo.$$.fragment,t),$(wt.$$.fragment,t),$($t.$$.fragment,t),$(Et.$$.fragment,t),$(Xo.$$.fragment,t),$(en.$$.fragment,t),$(sn.$$.fragment,t),$(Mt.$$.fragment,t),$(zt.$$.fragment,t),$(qt.$$.fragment,t),$(an.$$.fragment,t),$(rn.$$.fragment,t),$(mn.$$.fragment,t),$(Ct.$$.fragment,t),$(jt.$$.fragment,t),$(Pt.$$.fragment,t),vr=!1},d(t){o(d),t&&o(k),t&&o(c),E(r),t&&o(Da),t&&o(ye),E(Ot),t&&o(Oa),t&&o(Ge),t&&o(Ia),t&&o(Je),t&&o(Ua),t&&o(gn),t&&o(Ra),t&&o(_n),t&&o(Wa),t&&o(kn),t&&o(Ha),t&&o(bn),t&&o(Ka),t&&o(vn),t&&o(Va),t&&o(Tn),t&&o(Ba),t&&o(Q),t&&o(Za),t&&o(ae),t&&o(Ga),t&&o(re),t&&o(Ja),t&&o(we),E(Zt),t&&o(Qa),t&&o(ie),t&&o(Ya),t&&o($e),E(Gt),t&&o(Xa),t&&o(j),E(Jt),E(Xe),E(Yt),t&&o(er),t&&o(Me),E(eo),t&&o(tr),t&&o(x),E(to),E(oo),E(no),E(so),E(ao),t&&o(or),t&&o(qe),E(ro),t&&o(nr),t&&o(q),E(io),E(fo),E(st),E(at),t&&o(sr),t&&o(Ce),E(uo),t&&o(ar),t&&o(P),E(go),E(To),E(it),E(lt),t&&o(rr),t&&o(Pe),E(yo),t&&o(ir),t&&o(S),E(wo),E(Mo),E(ct),E(mt),E(pt),t&&o(lr),t&&o(Ae),E(zo),t&&o(dr),t&&o(A),E(qo),E(Po),E(ft),E(ut),t&&o(cr),t&&o(Ne),E(So),t&&o(mr),t&&o(L),E(Ao),E(Oo),E(_t),E(kt),t&&o(pr),t&&o(Oe),E(Io),t&&o(hr),t&&o(N),E(Uo),E(Ko),E(vt),E(Tt),t&&o(fr),t&&o(Ue),E(Vo),t&&o(ur),t&&o(D),E(Bo),E(Yo),E(wt),E($t),E(Et),t&&o(gr),t&&o(We),E(Xo),t&&o(_r),t&&o(O),E(en),E(sn),E(Mt),E(zt),E(qt),t&&o(kr),t&&o(Ke),E(an),t&&o(br),t&&o(I),E(rn),E(mn),E(Ct),E(jt),E(Pt)}}}const iu={local:"esm",sections:[{local:"overview",title:"Overview"},{local:"documentation-resources",title:"Documentation resources"},{local:"transformers.EsmConfig",title:"EsmConfig"},{local:"transformers.EsmTokenizer",title:"EsmTokenizer"},{local:"transformers.EsmModel",title:"EsmModel"},{local:"transformers.EsmForMaskedLM",title:"EsmForMaskedLM"},{local:"transformers.EsmForSequenceClassification",title:"EsmForSequenceClassification"},{local:"transformers.EsmForTokenClassification",title:"EsmForTokenClassification"},{local:"transformers.EsmForProteinFolding",title:"EsmForProteinFolding"},{local:"transformers.TFEsmModel",title:"TFEsmModel"},{local:"transformers.TFEsmForMaskedLM",title:"TFEsmForMaskedLM"},{local:"transformers.TFEsmForSequenceClassification",title:"TFEsmForSequenceClassification"},{local:"transformers.TFEsmForTokenClassification",title:"TFEsmForTokenClassification"}],title:"ESM"};function lu(F){return Lf(()=>{new URLSearchParams(window.location.search).get("fw")}),[]}class uu extends jf{constructor(d){super();Pf(this,d,lu,ru,Sf,{})}}export{uu as default,iu as metadata};
