agentlans / flan-t5-small-ner

huggingface.co
Total runs: 18
24-hour runs: -1
7-day runs: -2
30-day runs: 11
Model's Last Updated: January 09 2025
text-generation

Introduction of flan-t5-small-ner

Model Details of flan-t5-small-ner

flan-t5-small-ner

This model is a fine-tuned version of google/flan-t5-small on the pile_ner dataset . It achieves a loss of 0.5738 on the evaluation set and has processed 199 397 272 input tokens during training.

Model Description

flan-t5-small-ner can extract entities of specific types or definitions from text such as person, company, school, technology, and many more. It builds upon the FLAN-T5 architecture, which has strong performance across natural language processing tasks.

Example:

from transformers import AutoModelForSeq2SeqLM, AutoTokenizer
import torch

model_path = "agentlans/flan-t5-small-ner"
model = AutoModelForSeq2SeqLM.from_pretrained(model_path).to("cuda" if torch.cuda.is_available() else "cpu")
tokenizer = AutoTokenizer.from_pretrained(model_path)

def find_entities(input_text, entity_type):
    txt = entity_type + "[SEP]" + input_text
    inputs = tokenizer(txt, return_tensors="pt").to(model.device)
    outputs = model.generate(**inputs, max_new_tokens=100)
    decoded = tokenizer.decode(outputs[0], skip_special_tokens=False)
    raw_list = decoded.split("[SEP]")
    clean_list = [item.replace("<pad>", "").replace("[END]", "").replace("</s>", "").strip() for item in raw_list]
    return [item for item in clean_list if item]

# Example usage
input_text = "In the bustling metropolis of New York City, Apple Inc. sponsored a conference where Dr. Elena Rodriguez presented groundbreaking research."
print(find_entities(input_text, "person")) # ['Dr. Elena Rodriguez']
print(find_entities(input_text, "company")) # ['Apple Inc.']
print(find_entities(input_text, "fruit")) # []
Limitations
  • False positives and negatives are possible.
  • May struggle with specialized knowledge or fine distinctions.
  • Performance may vary for very short or long texts.
  • English language only.
  • Consider privacy when processing sensitive text.
Training Procedure
Training Hyperparameters
  • Learning rate: 5e-05
  • Train batch size: 8
  • Eval batch size: 8
  • Seed: 42
  • Optimizer: AdamW with betas=(0.9, 0.999) and epsilon=1e-08
  • LR scheduler type: linear
  • Number of epochs: 5.0
Training Results
Epoch Training Loss Validation Loss Input Tokens Seen
1.0 0.9726 0.6884 39,838,795
2.0 0.8089 0.6063 79,763,480
3.0 0.7025 0.5936 119,640,207
4.0 0.6962 0.5762 159,526,037
5.0 0.616 0.5738 199,397,272
Framework Versions
  • Transformers: 4.46.3
  • PyTorch: 2.5.1+cu124
  • Datasets: 3.2.0
  • Tokenizers: 0.20.3

Runs of agentlans flan-t5-small-ner on huggingface.co

18
Total runs
-1
24-hour runs
-2
3-day runs
-2
7-day runs
11
30-day runs

More Information About flan-t5-small-ner huggingface.co Model

More flan-t5-small-ner license Visit here:

https://choosealicense.com/licenses/apache-2.0

flan-t5-small-ner huggingface.co

flan-t5-small-ner huggingface.co is an AI model on huggingface.co that provides flan-t5-small-ner's model effect (), which can be used instantly with this agentlans flan-t5-small-ner model. huggingface.co supports a free trial of the flan-t5-small-ner model, and also provides paid use of the flan-t5-small-ner. Support call flan-t5-small-ner model through api, including Node.js, Python, http.

flan-t5-small-ner huggingface.co Url

https://huggingface.co/agentlans/flan-t5-small-ner

agentlans flan-t5-small-ner online free

flan-t5-small-ner huggingface.co is an online trial and call api platform, which integrates flan-t5-small-ner's modeling effects, including api services, and provides a free online trial of flan-t5-small-ner, you can try flan-t5-small-ner online for free by clicking the link below.

agentlans flan-t5-small-ner online free url in huggingface.co:

https://huggingface.co/agentlans/flan-t5-small-ner

flan-t5-small-ner install

flan-t5-small-ner is an open source model from GitHub that offers a free installation service, and any user can find flan-t5-small-ner on GitHub to install. At the same time, huggingface.co provides the effect of flan-t5-small-ner install, users can directly use flan-t5-small-ner installed effect in huggingface.co for debugging and trial. It also supports api for free installation.

flan-t5-small-ner install url in huggingface.co:

https://huggingface.co/agentlans/flan-t5-small-ner

Url of flan-t5-small-ner

flan-t5-small-ner huggingface.co Url

Provider of flan-t5-small-ner huggingface.co

agentlans
ORGANIZATIONS

Other API from agentlans

huggingface.co

Total runs: 42
Run Growth: 18
Growth Rate: 42.86%
Updated:July 18 2025
huggingface.co

Total runs: 12
Run Growth: -2
Growth Rate: -18.18%
Updated:March 25 2025