HuggingFace — Named Entity Recognition
hf_inference.nlp.nerExtract named entities — people (PER), locations (LOC), organizations (ORG), and miscellaneous (MISC) — from text using a BERT-based NER model via HuggingFace Inference API. Returns each detected entity with its type, confidence score, and character positions in the original text. Default model: dbmdz/bert-large-cased-finetuned-conll03-english (CoNLL-2003, English). Useful for document parsing, contact extraction, and knowledge graph construction.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| text | Yes | Input text to process. Maximum ~10,000 characters depending on model context window. | |
| model | No | HuggingFace model ID to use for named entity recognition. Default: "dbmdz/bert-large-cased-finetuned-conll03-english" (English NER: PER, LOC, ORG, MISC). Alternatives: "dslim/bert-base-NER" (lightweight English NER), "Jean-Baptiste/roberta-large-ner-english" (higher accuracy English NER). |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| error | No | Present only when the call failed. Includes error code, message, request_id, and any provider-specific extras. | |
| result | No | Tool response payload. Shape varies per tool — consult the tool description and inputSchema. May be an object, array, string, or number depending on the upstream provider response. |