This is T5-base model fine-tuned on SQuAD1.1 for QA using text-to-text approach
Model training
This model was trained on colab TPU with 35GB RAM for 4 epochs
Results:
Metric
#Value
Exact Match
81.5610
F1
89.9601
Model in Action 🚀
from transformers import AutoModelWithLMHead, AutoTokenizer
tokenizer = AutoTokenizer.from_pretrained("valhalla/t5-base-squad")
model = AutoModelWithLMHead.from_pretrained("valhalla/t5-base-squad")
def get_answer(question, context):
input_text = "question: %s context: %s </s>" % (question, context)
features = tokenizer([input_text], return_tensors='pt')
out = model.generate(input_ids=features['input_ids'],
attention_mask=features['attention_mask'])
return tokenizer.decode(out[0])
context = "In Norse mythology, Valhalla is a majestic, enormous hall located in Asgard, ruled over by the god Odin."
question = "What is Valhalla ?"
get_answer(question, context)
# output: 'a majestic, enormous hall located in Asgard, ruled over by the god Odin'
Play with this model
Created by Suraj Patil
Runs of valhalla t5-base-squad on huggingface.co
698
Total runs
0
24-hour runs
0
3-day runs
0
7-day runs
194
30-day runs
More Information About t5-base-squad huggingface.co Model
t5-base-squad huggingface.co
t5-base-squad huggingface.co is an AI model on huggingface.co that provides t5-base-squad's model effect (), which can be used instantly with this valhalla t5-base-squad model. huggingface.co supports a free trial of the t5-base-squad model, and also provides paid use of the t5-base-squad. Support call t5-base-squad model through api, including Node.js, Python, http.
t5-base-squad huggingface.co is an online trial and call api platform, which integrates t5-base-squad's modeling effects, including api services, and provides a free online trial of t5-base-squad, you can try t5-base-squad online for free by clicking the link below.
valhalla t5-base-squad online free url in huggingface.co:
t5-base-squad is an open source model from GitHub that offers a free installation service, and any user can find t5-base-squad on GitHub to install. At the same time, huggingface.co provides the effect of t5-base-squad install, users can directly use t5-base-squad installed effect in huggingface.co for debugging and trial. It also supports api for free installation.