Skip to main content

ste100-checker

Rule-based ASD-STE100 (Simplified Technical English) compliance checker for procedural and descriptive technical text. It analyzes files with spaCy and reports writing-rule violations together with approved-alternative suggestions.

STE is a controlled natural language: a restricted vocabulary, one meaning per word, short simple sentences. No public labeled STE corpus exists, so all compliance logic is rule-based on top of spaCy's statistical tokenizer, POS tagger, dependency parser, and lemmatizer.

Features

  • Ten automatable STE rules: vocabulary, part of speech, spelling, noun clusters, verb tense, passive voice, sentence length, semicolons, phrasal verbs
  • Approved-alternative suggestion with every violation
  • Text output for humans, JSON output for pipelines
  • Curated, extensible JSON dictionary (approved, unapproved, technical)

Installation

Requires Python 3.14.

python -m venv .venv && source .venv/bin/activate
pip install -e ".[dev]"
python -m spacy download en_core_web_sm

Usage

ste100 <file.txt> [--format text|json]
Option Alias Description Default
path Text file to check required
--format -f Output format: text or json text
--help Show help and exit

Text output:

$ ste100 samples/non_compliant.txt
Words: 45
Sentences: 3
Violations: 20

1. [1.1] "Utilize" is not an approved word (57-64)
   suggestion: use
2. [1.1] "colour" is not in the approved or technical dictionary (69-75)
...

JSON output:

{
  "words": 45,
  "sentences": 3,
  "total": 20,
  "violations": [
    {
      "rule": "1.1",
      "start": 57,
      "end": 64,
      "text": "Utilize",
      "message": "\"Utilize\" is not an approved word",
      "suggestion": "use"
    }
  ]
}

Each violation carries the rule id, character offsets into the source text, the offending span, a message, and an approved alternative when one exists. Exit status is 0 whether or not violations are found; parse the JSON and branch on total if you need a nonzero signal.

Rule coverage

STE rule Check spaCy technique
1.1 Unapproved or unknown word (with approved alternative) dictionary lookup on token.lower_ / lemma
1.2 Approved word used with wrong part of speech compare token.pos_ to dictionary POS
1.14 British spelling (-ise, colour, centre) regex + replacement map
2.1 Noun cluster with more than 3 nouns consecutive NOUN/PROPN runs
3.2 / 3.4 Complex tenses (perfect, progressive, modal + be + VBN, "is to be + VBN") Matcher on LEMMA / TAG
3.5 -ing form used as a verb VBG that is ROOT/conj
3.6 Passive voice nsubjpass -> auxpass -> VBN
5.1 / 6.3 Sentence longer than 20 (procedural) / 25 (descriptive) words doc.sents + token count
8.1 Semicolon usage token text ;
9.3 Phrasal verbs (curated) phrase list on lemma

Non-automatable rules (approved meanings, topic sentences, comprehension) are documented as out of scope; checkers are aids, not proofs.

Extending the dictionary

data/ holds the vocabulary as JSON. technical.json stores the domain words you add under rules 1.5 / 1.12:

{
  "nouns": ["actuator", "alternator", "antenna", "duct", "nozzle", "piston"],
  "verbs": ["bond", "drill", "weld"]
}

Append your own terms and rules 1.1 and 1.2 accept them automatically. approved.json maps approved words to their one allowed part of speech; unapproved.json maps unapproved words to their approved alternatives.

Evaluation

samples/eval.json is a 16-sentence annotated suite. Run the harness:

python -m src.evaluate

Current results: precision 0.941, recall 1.000, F1 0.970 (one false positive: rule 1.1 flags generator, a legitimate technical noun absent from the small curated dictionary). For context, Boeing BSEC reports 79%/89% and SECC 87%/93% on their much larger suites.

Development

ruff check .
ruff format --check .
python -m pytest

Project layout

├─ data/          curated approved / unapproved / technical dictionaries
├─ src/           package root: dictionary, pipeline, engine, rules, report, cli, evaluate
├─ src/rules/     one module per rule family
├─ samples/       compliant / non-compliant examples + annotated eval suite
├─ tests/         per-rule unit tests and CLI/eval tests
├─ case-study/    college case-study report (Typst)
└─ .github/       CI and release workflows

License

MIT. See LICENSE.

Download files

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

Source Distribution

ste100_checker-0.1.0.tar.gz (18.4 kB view details)

Uploaded Source

Built Distribution

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

ste100_checker-0.1.0-py3-none-any.whl (16.7 kB view details)

Uploaded Python 3

File details

Details for the file ste100_checker-0.1.0.tar.gz.

File metadata

  • Download URL: ste100_checker-0.1.0.tar.gz
  • Upload date:
  • Size: 18.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for ste100_checker-0.1.0.tar.gz
Algorithm Hash digest
SHA256 17babd30b098322a792e30df8525b4620584d57ee1792636f4b7feab46331925
MD5 9dcaa1c2fd17c27eea8523803c571a24
BLAKE2b-256 2ea1a5125d28198b62a62612d020e6e4f94e976a2c4420f49e7650053d621848

See more details on using hashes here.

Provenance

The following attestation bundles were made for ste100_checker-0.1.0.tar.gz:

Publisher: release.yml on swarooppatilx/ste100

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file ste100_checker-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: ste100_checker-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 16.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for ste100_checker-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 8b7d8fb64dc1b6bae8a84aba2588f25cb624b836d28d826e8a7f6fe093467b23
MD5 32b686fd8c177e8831cececf6895213a
BLAKE2b-256 bae158ca662bbc3dd45c1faa1f84867c6977437e802606e2aadcec11ac653614

See more details on using hashes here.

Provenance

The following attestation bundles were made for ste100_checker-0.1.0-py3-none-any.whl:

Publisher: release.yml on swarooppatilx/ste100

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

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