Skip to main content

watchlight-engine

The in-process authorization engine behind Watchlight Developer Edition.

watchlight-engine lets a Python agent make a real authorization decision — ALLOW / DENY — for a tool call, in-process, with zero infrastructure: no database, no network, no sidecar. It ships as a prebuilt, self-contained compiled wheel.

Most developers want the watchlight package, the Developer Edition with an ergonomic decorator API. This watchlight-engine package is the lower-level engine it embeds — install it directly only if you are building on the engine yourself.

Install

pip install watchlight-engine

Prebuilt wheels are provided for Linux (x86_64, aarch64), macOS (Apple Silicon and Intel), and Windows (x64), for CPython 3.9 and newer. No Rust toolchain is required.

Quickstart

import watchlight_engine

engine = watchlight_engine.PolicyEngine()
assert engine.ready()

# Load a policy, then authorize a request — a real decision, in-process.
engine.add_policy(policy_json)
decision = engine.authorize(request_json)
print(decision)   # -> Allow / Deny with the governing reason

When a policy is refused

add_policy refuses a policy whose @enforcement_effect annotation the engine cannot honour: an effect value it does not implement, or an annotation name that is a near miss for enforcement_effect (such as @enforcement_efect). It raises watchlight_engine.PolicyAnnotationError, which is a ValueError, and does not load the policy. The exception has a .code, which is one of watchlight_engine.POLICY_ANNOTATION_ERROR_CODES (UNRECOGNISED_ENFORCEMENT_EFFECT or ENFORCEMENT_EFFECT_NAME_NEAR_MISS), and a .policy_id naming the refused policy. Any other refusal raises a different exception.

try:
    engine.add_policy(policy_json)
except watchlight_engine.PolicyAnnotationError as err:
    print(err.code, err.policy_id)

See the Watchlight documentation for policy and request shapes, and the Developer Edition guide for the full workflow.

What you get

  • A real, in-process policy decision — the same authorization engine that powers the Watchlight platform, embedded so you can enforce governance without standing up any services.
  • Fail-closed by design: ambiguity denies.
  • A single prebuilt wheel per platform — install and go.

Developer Edition vs. Enterprise

The Developer Edition is for building and evaluating locally. The full Watchlight platform adds the governed control plane — centralized policy, tamper-evident lineage and audit, runtime enforcement across your fleet, drift and anomaly detection, secrets brokering, and the operator dashboard. See watchlight.ai to learn more.

License

Proprietary — licensed software, not open source. Copyright © Watchlight AI, LLC. All rights reserved.

The Developer Edition license lets you install and use watchlight-engine free of charge, including in production and commercially. A commercial license is required only to provide the engine itself to third parties as a hosted, managed, or embedded authorization service — contact legal@watchlight.ai. Redistribution, reverse-engineering, and sublicensing are not permitted. See the bundled LICENSE for the full terms.

Metadata

Release files for watchlight-engine 0.2.4

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

Built distributions (wheels)

Table of built distributions (wheels) for watchlight-engine 0.2.4
File Actions
watchlight_engine-0.2.4-cp39-abi3-win_amd64.whl CPython 3.9 abi3 Windows x86-64 Details for watchlight_engine-0.2.4-cp39-abi3-win_amd64.whl
watchlight_engine-0.2.4-cp39-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl CPython 3.9 abi3 Linux glibc 2.17+ x86-64 Details for watchlight_engine-0.2.4-cp39-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
watchlight_engine-0.2.4-cp39-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl CPython 3.9 abi3 Linux glibc 2.17+ ARM64 Details for watchlight_engine-0.2.4-cp39-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
watchlight_engine-0.2.4-cp39-abi3-macosx_11_0_arm64.whl CPython 3.9 abi3 macOS 11.0+ ARM64 Details for watchlight_engine-0.2.4-cp39-abi3-macosx_11_0_arm64.whl
watchlight_engine-0.2.4-cp39-abi3-macosx_10_12_x86_64.whl CPython 3.9 abi3 macOS 10.12+ x86-64 Details for watchlight_engine-0.2.4-cp39-abi3-macosx_10_12_x86_64.whl

Total release size: 14.6 MB

Release files / watchlight_engine-0.2.4-cp39-abi3-win_amd64.whl

Download URL watchlight_engine-0.2.4-cp39-abi3-win_amd64.whl
Size 3.1 MB
Tags CPython 3.9 Windows x86-64 abi3
SHA-256 checksum
How to use checksums
f8911bc2daea63c2e2a841b3d9a71dd3a6a7f4791600fb97f7e6366755fa48f3
BLAKE2b-256 checksum
How to use checksums
4a49edbc9e490af728c1aa80e4a70b8e762cca2a52459f1c8d0e40714e54fd29
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 Oct 25, 2026.

Transparency log

Release files / watchlight_engine-0.2.4-cp39-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl

Download URL watchlight_engine-0.2.4-cp39-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Size 3.0 MB
Tags CPython 3.9 Linux glibc 2.17+ x86-64 abi3
SHA-256 checksum
How to use checksums
4243b80f5cc665741b6087e3402f69c5b4486b5f52d1961bb6c05de4ac4d8fdf
BLAKE2b-256 checksum
How to use checksums
73d0e3f2d4ef43c99f2212c71911f2161783be9f949e3622a01e5da15eb5a01a
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 Oct 25, 2026.

Transparency log

Release files / watchlight_engine-0.2.4-cp39-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl

Download URL watchlight_engine-0.2.4-cp39-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
Size 2.8 MB
Tags CPython 3.9 Linux glibc 2.17+ ARM64 abi3
SHA-256 checksum
How to use checksums
49c4d895e551ff662ac12866682bf1fdbe5fcf6db06daac199c9c62b7cafe559
BLAKE2b-256 checksum
How to use checksums
87cb964b83b043214b786af84f32b6b9c6202ec6058be5a72461488ba0239445
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 Oct 25, 2026.

Transparency log

Release files / watchlight_engine-0.2.4-cp39-abi3-macosx_11_0_arm64.whl

Download URL watchlight_engine-0.2.4-cp39-abi3-macosx_11_0_arm64.whl
Size 2.7 MB
Tags CPython 3.9 abi3 macOS 11.0+ ARM64
SHA-256 checksum
How to use checksums
252efbd03bdc7dd78f8421cb86f5d9e7057d7b50d57b22e6b3bc92087e7440e2
BLAKE2b-256 checksum
How to use checksums
9f3aad31df90cab5d3967013897d853e0d483def52152829701d5b556e76e56f
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 Oct 25, 2026.

Transparency log

Release files / watchlight_engine-0.2.4-cp39-abi3-macosx_10_12_x86_64.whl

Download URL watchlight_engine-0.2.4-cp39-abi3-macosx_10_12_x86_64.whl
Size 2.9 MB
Tags CPython 3.9 abi3 macOS 10.12+ x86-64
SHA-256 checksum
How to use checksums
2c4a1b7cd4c948ed9b93828ecd04a7be9965408d0a210bcdf4b61735913cf8bc
BLAKE2b-256 checksum
How to use checksums
f1f931ef2047480b6fe424ec0edd404d1120275b50ef6ae6a1bd1b290f069899
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 Oct 25, 2026.

Transparency log

Security for watchlight-engine 0.2.4

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 5 files in this release have been uploaded with provenance metadata.

Select from 5 files

Attestation for watchlight_engine-0.2.4-cp39-abi3-win_amd64.whl

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 Oct 25, 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