A demo NER project that updates the NER component in an existing pretrained pipeline. All other pipeline components are preserved and frozen during training.
The project.yml
defines the data assets required by the
project, as well as the available commands and workflows. For details, see the
spaCy projects documentation.
The following commands are defined by the project. They
can be executed using spacy project run [name]
.
Commands are only re-run if their inputs have changed.
Command | Description |
---|---|
download |
Download the pretrained pipeline |
convert |
Convert the data to spaCy's binary format |
create-config |
Create a config for updating only NER from an existing pipeline |
train |
Update the NER model |
evaluate |
Evaluate the model and export metrics |
package |
Package the trained model as a pip package |
visualize-model |
Visualize the model's output interactively using Streamlit |
The following workflows are defined by the project. They
can be executed using spacy project run [name]
and will run the specified commands in order. Commands are only re-run if their
inputs have changed.
Workflow | Steps |
---|---|
all |
convert → create-config → train → evaluate |
The following assets are defined by the project. They can
be fetched by running spacy project assets
in the project directory.
File | Source | Description |
---|---|---|
assets/train.json |
Local | Demo training data converted from the v2 example scripts with srsly.write_json("train.json", TRAIN_DATA) |
assets/dev.json |
Local | Demo development data |