Skip to main content

Grammarticle spaCy pipeline

Project description

Grammarticle

GrammArticle Logo

GrammArticle is a RoBERTa-based grammar checker for English article usage. It detects three types of article errors:

  1. Missing – when an article is absent but required
  2. Wrong – when an incorrect article is used (e.g., "a apple" instead of "an apple", or "the" instead of "a/an")
  3. Redundant – when an article is unnecessary (e.g., "the furniture")

Installation

GrammArticle is trained on publicly available GEC datasets with synthetic augmentation and is available as a SpaCy pipeline.

pip install grammarticle

or

pip install spacy-transformers
python -m spacy download en_core_web_trf
pip install https://huggingface.co/iproskurina/en_grammarticle/resolve/main/en_grammarticle-1-py3-none-any.whl

Usage

import spacy
import en_grammarticle
nlp = en_grammarticle.load()
text = "Some text"
doc = nlp(text)
for span in doc.spans.get("sc", []): 
    print(f"[{span.label_}] {span.text}")

Example Output


Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

grammarticle-1.0.2.tar.gz (3.4 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

grammarticle-1.0.2-py3-none-any.whl (3.6 kB view details)

Uploaded Python 3

File details

Details for the file grammarticle-1.0.2.tar.gz.

File metadata

  • Download URL: grammarticle-1.0.2.tar.gz
  • Upload date:
  • Size: 3.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.11.12

File hashes

Hashes for grammarticle-1.0.2.tar.gz
Algorithm Hash digest
SHA256 9bd79063539692134d6f7e4ef69adc1ad5db053b54e66f9f83e288f6c2de464c
MD5 040fd417fc996887626b8cbbc61d95ab
BLAKE2b-256 34d14768be59a0063a4c8b374e66bd4f238625255dfbab3d894a407a90fed4a7

See more details on using hashes here.

File details

Details for the file grammarticle-1.0.2-py3-none-any.whl.

File metadata

  • Download URL: grammarticle-1.0.2-py3-none-any.whl
  • Upload date:
  • Size: 3.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.11.12

File hashes

Hashes for grammarticle-1.0.2-py3-none-any.whl
Algorithm Hash digest
SHA256 4c660f7011d34481844cfc0b5a9b8c195f9cba9f85f5a6678f698a6ad505be2a
MD5 36f5ff76e7edb53f5201df8cd7208b72
BLAKE2b-256 4b59c053a9d1b70caedb740a02b60d42dfbc6e18cf3b412df073091617d8ea70

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page