Instructions to use juusopi/grocery-fi-ner with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- spaCy
How to use juusopi/grocery-fi-ner with spaCy:
!pip install https://huggingface.co/juusopi/grocery-fi-ner/resolve/main/grocery-fi-ner-any-py3-none-any.whl # Using spacy.load(). import spacy nlp = spacy.load("grocery-fi-ner") # Importing as module. import grocery-fi-ner nlp = grocery-fi-ner.load() - Notebooks
- Google Colab
- Kaggle
Finnish Grocery NER
spaCy named-entity recognition for Finnish grocery text โ quantities, units, products, and notes.
Backed by TurkuNLP/bert-base-finnish-cased-v1; the pipeline is
transformer โ ner.
This repository holds the ner model only. NER and text classification are
trained and published separately, so the matching textcat model lives in its
own repository and is versioned independently of this one.
Labels
Entity labels: NOTE, PRODUCT, QUANTITY, UNIT
Performance (dev set)
| Metric | Score |
|---|---|
| F1 | 0.993 |
| Precision | 0.991 |
| Recall | 0.995 |
Per-label:
| Label | Precision | Recall | F1 |
|---|---|---|---|
| PRODUCT | 0.989 | 0.989 | 0.989 |
| QUANTITY | 0.995 | 1.000 | 0.998 |
| NOTE | 0.975 | 0.997 | 0.986 |
| UNIT | 0.999 | 1.000 | 1.000 |
Note that the development set is generated from the same vocabulary as the training set, so these figures measure fit rather than generalisation. Held-out performance is measured against a hand-labelled probe set in the training repository.
Usage
import spacy
nlp = spacy.load("juusopi/grocery-fi-ner")
doc = nlp("500 g omenaa")
for ent in doc.ents:
print(ent.text, ent.label_)
# 500 QUANTITY
# g UNIT
# omenaa PRODUCT
Model details
- Base model: TurkuNLP/bert-base-finnish-cased-v1
- spaCy version: >=3.8.11,<3.9.0
- Version: 1.2.0
Versions are semantic and describe the output contract: a major bump means the label set changed and consumers mapping those labels must be updated.
- Downloads last month
- -