Skip to main content

AfterAI Runner — AIS signal emission and agent evaluation on customer infrastructure

Project description

AfterAI Runner v0

Runner v0 collects pre-aggregated D1–W5 metrics from customer-controlled artifact files and emits AIS payloads to the AfterAI API. It does not manage baselines, evaluate thresholds, or trigger ACE.

  • Manifest-driven: you provide a JSON or YAML manifest listing system + local artifact paths.
  • Artifact contract: each artifact file is one signal (required: signal_key, cadence, window, metrics).
  • Stateless: no local state; duplicate sends are allowed. Always sends external_id.
  • Local filesystem only (v0): artifact paths must be local; no S3, GCS, or HTTPS.

Install

pip install afterai-runner

Or from source:

cd afterai-runner && pip install -e .

Config

Env Required Default
AFTERAI_API_KEY Yes
AFTERAI_BASE_URL No https://api.useafter.ai

Usage

# Run ingestion from a manifest
afterai-runner run --manifest manifest.yaml

# Print payloads without sending
afterai-runner run --manifest manifest.yaml --dry-run

# Optional: ACE-from-AIS rule (out-of-band). Reads GET /signals/debug, applies threshold, POSTs inferred ACE.
afterai-runner ace-from-ais --min-signals 2 --hours 24
afterai-runner ace-from-ais --min-signals 2 --severity high,critical --dry-run

Manifest example

manifest.yaml (or .json):

version: "2026-02"
artifacts:
  - system: my-system-01
    path: /path/to/D1-2026-02-03.json
  - system: my-system-01
    path: /path/to/W1-2026-W05.json

path must be a local filesystem path (no remote URIs in v0).

Artifact example

One file = one signal. D1-2026-02-03.json:

{
  "signal_key": "D1",
  "cadence": "daily",
  "window": {
    "start": "2026-02-03T00:00:00Z",
    "end": "2026-02-03T23:59:59Z"
  },
  "metrics": {
    "score_mean": 0.87,
    "fail_rate": 0.03
  }
}

Optional passthrough: severity, confidence, tags, source, evidence_refs, baseline_ref, created_at.
Runner adds: system, external_id, type: "ais", and created_at if missing; defaults severity="low", confidence=0.8 if missing.

external_id format

  • Daily: {system}:{signal_key}:{YYYY-MM-DD}
  • Weekly: {system}:{signal_key}:{YYYY-Www} (ISO week from window.end)

Docs

License

MIT

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

afterai_runner-0.1.0.tar.gz (20.7 kB view details)

Uploaded Source

Built Distribution

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

afterai_runner-0.1.0-py3-none-any.whl (22.1 kB view details)

Uploaded Python 3

File details

Details for the file afterai_runner-0.1.0.tar.gz.

File metadata

  • Download URL: afterai_runner-0.1.0.tar.gz
  • Upload date:
  • Size: 20.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.11.7

File hashes

Hashes for afterai_runner-0.1.0.tar.gz
Algorithm Hash digest
SHA256 50640577a38df261bbf07459b7bbb781bf4628f7be8b0a6437e2f2b7d849dc69
MD5 9efa18003bf5bb7af3a38e43068c6f98
BLAKE2b-256 943fafbbe99157936b5cd235c900ac3cca80ffbaf2cd054a9a765f5115bd54ef

See more details on using hashes here.

File details

Details for the file afterai_runner-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: afterai_runner-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 22.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.11.7

File hashes

Hashes for afterai_runner-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 e9b10084d867e3dbce37ca91a23327625ed0e4113d797daeeed9d344fd9cb70e
MD5 010a2cf291331fc1edfba507e7cabf96
BLAKE2b-256 6eba252961cfa2484c3687e2d6c9ab1ed98019cf24881a1fee5c31aeed0368eb

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