EngineReadiness#
- class scikitplot.cleanprompt.EngineReadiness(name, installed, language_supported, assets_checked, assets_ready, ready, status, reason, remedy, model=None, missing=(), version=None)[source]#
Whether one engine can run here, now, and if not, the one step that fixes it.
- Parameters:
- namestr
Engine name, as used by
--ner-engine.- installedbool
Whether the engine’s capability tier reports
AVAILABLE: the package is installed, inside the declared range, and importable according to its metadata.- language_supportedbool
Whether the engine handles the language asked for.
- assets_checkedbool
Whether the engine’s data was looked at.
Falseonly for NLTK when the caller chose not to import it (see the notes).- assets_readybool or None
Whether the model or data packages are present;
Nonewhen they were not checked.- readybool
installed and language_supported and assets_ready is not False— nothing known stands in the way of running.- statusstr
A
CapabilityStatusvalue describing the first obstacle, or"AVAILABLE".- reasonstr
One sentence saying what was found.
- remedystr
The command or flag that removes the first obstacle; empty when ready.
- modelstr or None
For spaCy, the model this configuration loads; otherwise
None.- missingtuple of str
For NLTK, the data packages that were not found.
- versionstr or None
The installed distribution version, when known.
- Parameters:
Notes
User notes. Read
readyto decide, andremedyto act.reasonis for a person: it says which of the three conditions failed.Developer notes — why NLTK’s data may be unchecked. spaCy models are ordinary installed distributions, so their presence is read from metadata without importing anything. NLTK’s data packages live in directories that only
nltk.data.findcan resolve — the search path depends on environment variables, the interpreter prefix and the platform, and copying that logic here would be a guess about NLTK’s internals. So the check imports NLTK, and it runs only where the caller is about to load NLTK anyway: an explicit request,doctor, or the web app with entity detection switched on. Everywhere else the field saysNonerather than pretending to know.