nl_meningen / README.md
RaThorat's picture
Update README.md
048efc1
|
raw
history blame
3.14 kB
---
tags:
- spacy
- text-classification
language:
- nl
model-index:
- name: nl_meningen
results: []
license: mit
pipeline_tag: text-classification
---
## Introduction
Als data scientist nam ik deel aan de hackathon georganiseerd door de Ministeries van BZK en VWS.
Ik toelegde mij op Challenge 2: het verbeteren van de gebruikerservaring op de website en
het optimaliseren van relevante informatieverschaffing met behulp van design en data science.
Een belangrijk onderdeel van mijn bijdrage was de implementatie van een text classification model.
Dit model analyseert meningen over de overheidssite en classificeert ze als positief of negatief.
Het biedt een waardevol instrument om de gebruikerservaring te monitoren en te verbeteren.
De hackathon bood een vruchtbare omgeving om innovatieve oplossingen te ontwikkelen die de interactie tussen de overheid en haar burgers verbeteren.
Mijn text classification model draagt bij aan een meer gepersonaliseerde en efficiënte gebruikerservaring op overheidswebsites.
## Prompt with Prodigy
Go to folder envs (home/anaconda3/envs) and open the terminal (Ctl+ALT+T)
run: source prodi-env/bin/activate where prodi-env is the folder of processing
run: prodigy textcat.manual meningen_dataset ./meningen.txt --label Positief,Negatief
run to create model : prodigy train /home/gebruiker/anaconda3/hack_model --textcat meningen_dataset --lang "nl" --label-stats --verbose
or to export data to spacy
Type: prodigy data-to-spacy /home/gebruiker/anaconda3/envs/corpus --textcat meningen_dataset --lang "nl" --eval-split 0.1
To use this data for training with spaCy, you can run:
python -m spacy train --output /home/gebruiker/anaconda3/meningen_model /home/gebruiker/anaconda3/envs/corpus/config.cfg --paths.train /home/gebruiker/anaconda3/envs/corpus/train.spacy --paths.dev /home/gebruiker/anaconda3/envs/corpus/dev.spacy
## Upload model to huggingface
huggingface-cli login
python -m spacy package /home/gebruiker/anaconda3/meningen_model/model-last /home/gebruiker/anaconda3/output --build wheel
cd /home/gebruiker/anaconda3/output/nl_meningen-0.0.0/dist/
python -m spacy huggingface-hub push nl_meningen-0.0.0-py3-none-any.whl
To download the data set from the database
run: python -m prodigy db-out meningen_dataset > meningen_dataset.jsonl
| Feature | Description |
| --- | --- |
| **Name** | `nl_meningen` |
| **Version** | `0.0.0` |
| **spaCy** | `>=3.4.3,<3.5.0` |
| **Default Pipeline** | `textcat` |
| **Components** | `textcat` |
| **Vectors** | 0 keys, 0 unique vectors (0 dimensions) |
| **Sources** | n/a |
| **License** | n/a |
| **Author** | [n/a]() |
### Label Scheme
<details>
<summary>View label scheme (2 labels for 1 components)</summary>
| Component | Labels |
| --- | --- |
| **`textcat`** | `Positief`, `Negatief` |
</details>
### Accuracy
| Type | Score |
| --- | --- |
| `CATS_SCORE` | 96.54 |
| `CATS_MICRO_P` | 96.77 |
| `CATS_MICRO_R` | 96.77 |
| `CATS_MICRO_F` | 96.77 |
| `CATS_MACRO_P` | 95.83 |
| `CATS_MACRO_R` | 97.50 |
| `CATS_MACRO_F` | 96.54 |
| `CATS_MACRO_AUC` | 98.18 |
| `CATS_MACRO_AUC_PER_TYPE` | 0.00 |
| `TEXTCAT_LOSS` | 8.31 |