Skip to main content

accuraCy

It's pronounced "accura-see". For spaCy models.

The goal of this project is to generate reports for spaCy models.

what it does

The goal of accuraCy is to offer static reports for spaCy models that help users make better decisions on how the models can be used. At the moment the project supports reports for threshold values for classification.

Here's a preview of what to expect:

There are two kinds of charts.

  1. The first kind is a density chart. This chart shows the distribution of confidence scores for a given class. The blue area represents documents that had the tag assigned to the class. The orange area represents documents that didn't.
  2. The second kind is a line chart that demonstrates the accuracy, precision and recall values for a given confidence threshold. It's an interactive chart and you can explore the values by hovering over the chart.

install

You can install the latest version from git.

python -m pip install "accuracy @ git+https://github.com/koaning/accuracy.git"

usage

The accuracy project provides a command line interface that can generate reports. The full CLI can also be explored via the --help flag.

> python -m accuracy --help

Usage: python -m accuracy [OPTIONS] COMMAND [ARGS]...

  It's pronounced 'accura-see'. For spaCy models.

Options:
  --help  Show this message and exit.

Commands:
  report   Generate a model report.
  version  Show version number.

accuracy report

The most important command is the report command. You'd typically use it via a command similar to:

> python -m accuracy report training/model-best/ corpus/train.spacy corpus/dev.spacy

Loading model at training/model-best
Running model on training data...
Running model on development data...
Generating Charts ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 100% 0:00:00
Done! You can view the report via;

python -m http.server --directory reports PORT 

This will generate a folder, typically called "reports", that contains a full dashboard for the trained spaCy model found in training/model-best.

The CLI has a few configurable settings:

Arguments:
  [MODEL_PATH]  Path to spaCy model
  [TRAIN_PATH]  Path to training data
  [DEV_PATH]    Path to development data
  [FOLDER_OUT]  Output folder for reports  [default: reports]

Options:
  --classes TEXT  Comma-separated string of classes to use
  --help          Show this message and exit.

Release files for accuracy 0.1.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for accuracy 0.1.1
File Size Uploaded
accuracy-0.1.1.tar.gz 6.7 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for accuracy 0.1.1
File Interpreter ABI Platform
accuracy-0.1.1-py2.py3-none-any.whl Python 2, Python 3 none any Details

Total release size: 14.5 kB

Release files / accuracy-0.1.1.tar.gz

Download URL accuracy-0.1.1.tar.gz
Size 6.7 kB
Tags Source
SHA-256 checksum
How to use checksums
afbaa8c2632465111a5ebc56018b7153aebc62d20cb6aff3c27d06096c1c5ed0
BLAKE2b-256 checksum
How to use checksums
849a46afb5d8639fac951df4d3236efe427437a121061021186ca81049bd2470
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.0 CPython/3.8.6

Release files / accuracy-0.1.1-py2.py3-none-any.whl

Download URL accuracy-0.1.1-py2.py3-none-any.whl
Size 7.8 kB
Tags Python 2 Python 3
SHA-256 checksum
How to use checksums
570d5793e978295cb17e5c5fc5fa9c66e94ad7ef6439e1fa7426d23ce2969cf1
BLAKE2b-256 checksum
How to use checksums
5d3c490ea37952dbd03ef9a91077481dcbcfa07c76a669bf0f3e53e7da0dd725
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.0 CPython/3.8.6

Release history Release notifications | RSS feed

This release

0.1.1 This release

2 release files

0.1.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page