Director-AI Lite
director-ai-lite is a standalone, dependency-free LLM streaming-halt guard:
it stops a token stream before a hallucination finishes generating. It installs
with zero heavy dependencies (standard library only) and does not require the
full director-ai package.
pip install director-ai-lite
from director_ai_lite import guard
result = guard(
token_stream,
facts={"capital": "Paris is the capital of France."},
prompt="What is the capital of France?",
)
print(result.output) # surviving text (halted tokens removed)
print(result.halted) # True if the stream was stopped
print(result.halt_reason) # why it was stopped
How it works
The default path is model-free: each accumulated prefix is scored by a
grounding heuristic (content-word overlap against the supplied facts) and the
same calibrated coherence combination the full package uses in its no-model path.
The stream hard-halts on the first token whose coherence drops below threshold
(default 0.5). With no facts, scoring stays neutral and nothing is halted.
Because the grounding heuristic and the coherence calibration match the full package, you can upgrade to model-backed (NLI/RAG) scoring without changing the call site.
Upgrade to model-backed scoring
pip install "director-ai-lite[full]"
Then pass the full package's scorer to StreamGuard:
from director_ai_lite import StreamGuard
guard = StreamGuard(facts=..., scorer=my_nli_scorer) # any review(prompt, text) scorer
Tiers
Director-Lite is the free, standalone entry point. The wider product ladder:
| Tier | What it is |
|---|---|
| Director-Lite | Free. This package — standalone, model-free streaming halt, zero dependencies. |
| Director-AI | The full runtime — model-backed NLI/RAG scoring, REST/gRPC server, framework integrations, sealed evidence packets, tamper-evident audit. |
| Director-AI Pro | Production-tier licence and support on top of the full runtime. |
| Director-AI Full | The complete advanced + labs capability set. |
| Director-Class AI | Separate action-control and evidence product for high-impact agent operations; scoped commercial order. |
Support development ☕
Director-Lite is free forever, including in production. If it helps you, you can support development — entirely optional, and it keeps the free tier moving:
License
Apache-2.0.
Metadata
Release files for director-ai-lite 3.21.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | |
|---|---|---|---|---|
| director_ai_lite-3.21.0.tar.gz | 8.6 kB | With provenance | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| director_ai_lite-3.21.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 16.0 kB
Release files / director_ai_lite-3.21.0.tar.gz
| Download URL | director_ai_lite-3.21.0.tar.gz |
|---|---|
| Size | 8.6 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
732a46624b97837bed5331e43a5902ece0afcb9ec7ebc704d94a9b06f489eae8
|
|
BLAKE2b-256 checksum How to use checksums |
4c9d1dd4578d826d17025a5213c67126ea990bc1597ad584b69b7d1b7283b7ba
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Jul 29, 2026.
Transparency logRelease files / director_ai_lite-3.21.0-py3-none-any.whl
| Download URL | director_ai_lite-3.21.0-py3-none-any.whl |
|---|---|
| Size | 7.4 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
3db53ad06bd0a5020bcf8adbd5b53ad38f8c6350cf7edb324c14c08cded1cc1f
|
|
BLAKE2b-256 checksum How to use checksums |
c06ae6dea12a8acc9e7a57334e6bbfb90428bf6a4336c63e5b0c5ef78b54c2e2
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Jul 29, 2026.
Transparency logSecurity for director-ai-lite 3.21.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
Full provenance
All 2 files in this release have been uploaded with provenance metadata.
Attestation for director_ai_lite-3.21.0.tar.gz
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Jul 29, 2026.
Transparency logA note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.