Skip to main content

Regulatory and audit evidence packaging for Refua campaign decisions.

Project description

refua-regulatory

refua-regulatory is the Refua regulatory workflow and audit package. It helps teams follow drug regulation processes by turning campaign decisions and execution outputs into verifiable evidence bundles with end-to-end lineage across plans, tool calls, models, datasets, and generated artifacts.

What it provides

  • Campaign decision extraction from refua-campaign run outputs.
  • Structured decision records (decisions.jsonl) with deterministic decision IDs.
  • Model and data provenance capture per campaign decision.
  • Lineage graph materialization (lineage.json) for traceability.
  • Evidence bundle packaging with checksums (checksums.sha256).
  • Integrity verification for audit handoff and compliance workflows.
  • Regulatory checklist evaluation with strict and manual-review gates.
  • Automatic comprehensive checklist generation during bundle build.
  • Structured outputs that support internal regulatory readiness reviews before agency submission.

Install

cd refua-regulatory
pip install -e .

CLI

refua-regulatory --help

Build a bundle

refua-regulatory build \
  --campaign-run artifacts/kras_campaign_run.json \
  --output-dir artifacts/evidence/kras_run_001 \
  --data-manifest ~/.cache/refua-data/_meta/parquet/chembl_activity_ki_human/latest/manifest.json \
  --extra-artifact artifacts/candidate_run.json

Output bundle layout:

evidence/
  manifest.json
  decisions.jsonl
  lineage.json
  checksums.sha256
  artifacts/
    campaign_run.json
    data_manifests/
    extras/
  checklists/
    drug_discovery_comprehensive.json
    drug_discovery_comprehensive.md

By default, build auto-generates the drug_discovery_comprehensive checklist.

Build-time checklist controls:

refua-regulatory build \
  --campaign-run artifacts/kras_campaign_run.json \
  --output-dir artifacts/evidence/kras_run_001 \
  --checklist-template core \
  --checklist-template fda_cder_ai_ml \
  --checklist-strict

Disable checklist generation:

refua-regulatory build \
  --campaign-run artifacts/kras_campaign_run.json \
  --output-dir artifacts/evidence/kras_run_001 \
  --no-checklist

Verify a bundle

refua-regulatory verify --bundle-dir artifacts/evidence/kras_run_001

JSON mode:

refua-regulatory verify --bundle-dir artifacts/evidence/kras_run_001 --json

Show bundle summary

refua-regulatory summary --bundle-dir artifacts/evidence/kras_run_001

Run a regulatory checklist

Core automated checklist:

refua-regulatory checklist \
  --bundle-dir artifacts/evidence/kras_run_001 \
  --template drug_discovery_comprehensive \
  --strict

FDA/CDER-oriented template (includes manual-review items):

refua-regulatory checklist \
  --bundle-dir artifacts/evidence/kras_run_001 \
  --template fda_cder_ai_ml \
  --output-json artifacts/evidence/kras_run_001/checklist.json \
  --output-markdown artifacts/evidence/kras_run_001/checklist.md

Python API

from pathlib import Path

from refua_regulatory import build_evidence_bundle, verify_evidence_bundle

manifest = build_evidence_bundle(
    campaign_run_path=Path("artifacts/kras_campaign_run.json"),
    output_dir=Path("artifacts/evidence/kras_run_001"),
)

verification = verify_evidence_bundle(Path("artifacts/evidence/kras_run_001"))
print(manifest["bundle_id"], verification.ok)

Data and model provenance behavior

  • Data provenance is loaded from explicit manifest paths (--data-manifest).
  • refua-data parquet manifests are parsed directly for dataset IDs, versions, source URLs, and SHA256 checksums.
  • Model provenance is inferred from executed tool outputs and optional CLI overrides (--model-name, --model-version).

Test

cd refua-regulatory
python -m pytest -q

Notes

  • This package records reproducibility evidence; it does not claim biological efficacy.
  • Regulatory submission requirements vary by jurisdiction and program type.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

refua_regulatory-0.6.0.tar.gz (26.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

refua_regulatory-0.6.0-py3-none-any.whl (25.9 kB view details)

Uploaded Python 3

File details

Details for the file refua_regulatory-0.6.0.tar.gz.

File metadata

  • Download URL: refua_regulatory-0.6.0.tar.gz
  • Upload date:
  • Size: 26.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.3.2 CPython/3.14.3 Darwin/25.2.0

File hashes

Hashes for refua_regulatory-0.6.0.tar.gz
Algorithm Hash digest
SHA256 fae8a0b3213ea6bbd2f06332abeba8abd723c8611c4e18ff8351acba4659c03c
MD5 729edba968ed9404d19c7da8fe610b47
BLAKE2b-256 57a70aeb6b76ad1b21d76c441fb04bac02d26a1c2b8856e052fa2f59df58bc0b

See more details on using hashes here.

File details

Details for the file refua_regulatory-0.6.0-py3-none-any.whl.

File metadata

  • Download URL: refua_regulatory-0.6.0-py3-none-any.whl
  • Upload date:
  • Size: 25.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.3.2 CPython/3.14.3 Darwin/25.2.0

File hashes

Hashes for refua_regulatory-0.6.0-py3-none-any.whl
Algorithm Hash digest
SHA256 d0b93d7a74569d8fded58f4c6cf9f1a28d47f35a84c46321177a4b8ba512902a
MD5 4492e667597d27115f92d4fc1c3df2c9
BLAKE2b-256 523932f3613c2d79b8fdf5a730e103a85f586d8d218d7db9982bb8fee823f906

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page