Skip to main content

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:

Buy Me a Coffee

License

Apache-2.0.

Metadata

Release files for director-ai-lite 4.0.0

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

Source distribution (sdist)

Source distribution for director-ai-lite 4.0.0
File Size Uploaded Provenance Actions
director_ai_lite-4.0.0.tar.gz 10.0 kB With provenance Details for director_ai_lite-4.0.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for director-ai-lite 4.0.0
File Interpreter ABI Platform Actions
director_ai_lite-4.0.0-py3-none-any.whl Python 3 none any Details for director_ai_lite-4.0.0-py3-none-any.whl

Total release size: 18.1 kB

Release files / director_ai_lite-4.0.0.tar.gz

Download URL director_ai_lite-4.0.0.tar.gz
Size 10.0 kB
Tags Source
SHA-256 checksum
How to use checksums
fd284322262fed6f283f0fa46b587b99a268e60a4f2ad5f07576755b00740b84
BLAKE2b-256 checksum
How to use checksums
770c7bcfb8735e74627eaa94572609aa35640dc3e23831bc2cdf1fc0c814ccb6
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

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 Dec 5, 2026.

Transparency log

Release files / director_ai_lite-4.0.0-py3-none-any.whl

Download URL director_ai_lite-4.0.0-py3-none-any.whl
Size 8.0 kB
Tags Python 3
SHA-256 checksum
How to use checksums
e190eb930ba066959dca2cc3b192591c7d43506e9eaadef099fdbacef8504ff5
BLAKE2b-256 checksum
How to use checksums
d2659ecbda286d8e8c760be669a72b5d200d291a2e78bcf1bbbdf515e0091494
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

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 Dec 5, 2026.

Transparency log

Security for director-ai-lite 4.0.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

Both files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for director_ai_lite-4.0.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 Dec 5, 2026.

Transparency log

A 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.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

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