Skip to main content

Installation

Requirements

  • Python 3.9 or higher
  • No OPA binary — evaluation is in-process via regopy

Core package

pip install comply54

This installs the evaluation engine, all 21 policy packs, and the sector packs for Nigeria (fintech, healthcare, insurance), Kenya, and Pan-African coverage.

Framework adapters

Install the adapter for your AI framework alongside the core:

pip install comply54 langchain-core langgraph
from comply54.langchain import Comply54Guard, comply54_route, compliance_node, comply54_tool

Verify installation

import comply54

# Check package version
print(comply54.__version__) # 0.2.4

# List all available packs
from comply54 import list_packs
for pack in list_packs():
print(f"{pack.id} ({pack.jurisdiction}) — {pack.regulation}")

Expected output:

nigeria/ndpa        (NG)  — NDPA 2023
nigeria/cbn (NG) — CBN Transaction Controls
nigeria/bvn-nin (NG) — CBN BVN Framework, NIBSS BVN Scheme Rules & NIMC Act 2026
nigeria/nfiu-aml (NG) — NFIU/MLPPA 2022
nigeria/nha (NG) — National Health Act 2014
nigeria/naicom (NG) — Insurance Act 2003 / NAICOM Guidelines
kenya/kdpa (KE) — Kenya Data Protection Act 2019
south-africa/popia (ZA) — POPIA
ghana/dpa (GH) — Ghana Data Protection Act 2012
rwanda/dpa (RW) — Law No. 058/2021
egypt/pdpl (EG) — Egypt PDPL No. 151/2020
ethiopia/pdp (ET) — Ethiopia PDP Proclamation 1321/2024
mauritius/dpa (MU) — Mauritius DPA 2017
tanzania/pdpa (TZ) — Tanzania PDPA 2022
uganda/dppa (UG) — Uganda DPPA 2019
universal/pii-leakage — OWASP LLM01
universal/prompt-injection — OWASP LLM01
universal/tool-permissions — OWASP LLM08
universal/human-approval — OWASP LLM08
universal/model-routing — OWASP LLM09

Environment variables

comply54 requires no mandatory environment variables. Optional configuration:

VariableDefaultDescription
COMPLY54_AUDIT_BACKENDnoneAudit log destination: none, stdout, file, or a URL
COMPLY54_AUDIT_FILEcomply54-audit.jsonlPath when AUDIT_BACKEND=file
COMPLY54_STRICT_MODEfalseTreat escalate decisions as deny

Docker / Lambda

comply54 works in any Python environment — no system dependencies:

FROM python:3.12-slim
RUN pip install comply54

The regopy wheel ships with a pre-compiled Go OPA binary embedded as a shared object — no apt-get or brew install opa required.