Skip to main content

FLUX Registry

npm for agent policies. Pre-compiled FLUX bytecode, installable and runnable.

Pre-compiled agent policies, installable and runnable. The registry is a static JSON index on GitHub — no server required. The CLI downloads from raw.githubusercontent.com and caches policies locally in ~/.flux/policies/.

Install

pip install flux-registry

Quick Start

# Browse available policies
flux list --remote

# Install a policy
flux install deadband-controller

# Run it
flux run deadband-controller --input temperature=72
# Output: action=idle

flux run deadband-controller --input temperature=80
# Output: action=cool

flux run deadband-controller --input temperature=60
# Output: action=heat

# Get details
flux info deadband-controller

Commands

Command Description
flux install <policy> Install a policy from the remote registry
flux list [--remote] List installed (or remote) policies
flux info <policy> Show detailed metadata, inputs, outputs
flux run <policy> --input K=V Execute a policy with given inputs
flux remove <policy> Remove an installed policy
flux update-index Refresh the local registry cache

Available Policies

Policy Description Inputs Outputs
deadband-controller Thermostat with hysteresis — AC at 75°, heat at 65° temperature (°F) action: idle/cool/heat
budget-tracker Conservation budget enforcement — track resource depletion cost, budget remaining, status: ok/exceeded
rate-limiter Token bucket rate limiting — check and consume tokens tokens, cost remaining, allowed: denied/allowed
security-scanner Basic vulnerability detection — threshold-based policy check value, threshold verdict: safe/violation, severity

Policy Format

Each policy is a JSON file containing:

{
  "name": "deadband-controller",
  "version": "0.1.0",
  "description": "Thermostat deadband controller",
  "author": "SuperInstance",
  "bytecode": "<base64-encoded FLX0 binary>",
  "source": "deadband-controller.flx",
  "bytecode_hash": "sha256...",
  "bytecode_size": 32,
  "inputs": [{"name": "temperature", "type": "float", "register": "R0"}],
  "outputs": [{"name": "action", "type": "int", "register": "R1",
               "values": {"0": "idle", "1": "cool", "2": "heat"}}],
  "conservation": {"max_steps": 100, "memory_budget": 256},
  "conformance": "verified on flux-vm 0.1.0, fluxvm 0.1.0, flux-js 0.1.0",
  "tags": ["iot", "thermostat", "hvac"],
  "license": "MIT"
}

Architecture

┌──────────────────────────────────────────────────────┐
│                   FLUX Registry                       │
│                                                       │
│  GitHub (static JSON)          Local (~/.flux/)       │
│  ┌─────────────────┐          ┌──────────────────┐   │
│  │ registry/       │  install │ policies/        │   │
│  │   index.json    │ ───────▶ │   deadband.json  │   │
│  │   deadband.json │          │   budget.json    │   │
│  │   budget.json   │          └────────┬─────────┘   │
│  │   rate-limiter  │                   │              │
│  │   security.json │          ┌────────▼─────────┐   │
│  └─────────────────┘          │   flux CLI       │   │
│                               │   ┌────────────┐ │   │
│                               │   │ Mini FLUX  │ │   │
│                               │   │ VM (built  │ │   │
│                               │   │  in)       │ │   │
│                               │   └────────────┘ │   │
│                               └──────────────────┘   │
└──────────────────────────────────────────────────────┘

The mini FLUX VM is built into the CLI for zero-dependency local execution. For production use, policies can be run on any FLUX implementation:

Runtime Language Install
flux-vm Python pip install flux-vm
fluxvm Rust cargo add fluxvm
flux-js JavaScript npm install flux-js

All run the same bytecode — same policy, different shells.

Conservation Guarantees

Every policy declares conservation limits:

"conservation": {
  "max_steps": 100,
  "memory_budget": 256
}

The VM enforces these at runtime — a policy cannot exceed its step count or memory allocation. This makes FLUX policies safe to run as untrusted code.

Adding Policies

  1. Write a policy in .flx source
  2. Compile with flux-compiler
  3. Create a JSON manifest with bytecode + metadata
  4. Submit a PR to add it to registry/

License

MIT — Same bytecode, different shells. 🦀

Metadata

Release files for flux-registry 0.1.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 flux-registry 0.1.0
File Size Uploaded Provenance Actions
flux_registry-0.1.0.tar.gz 14.6 kB Without provenance Details for flux_registry-0.1.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for flux-registry 0.1.0
File Interpreter ABI Platform Actions
flux_registry-0.1.0-py3-none-any.whl Python 3 none any Details for flux_registry-0.1.0-py3-none-any.whl

Total release size: 26.3 kB

Release files / flux_registry-0.1.0.tar.gz

Download URL flux_registry-0.1.0.tar.gz
Size 14.6 kB
Tags Source
SHA-256 checksum
How to use checksums
bd810b7c3dce750752f0f3938d2e59cead49fbbfa024439d17acf8a4145fe3e1
BLAKE2b-256 checksum
How to use checksums
9a780b4f13040c34fd4b64b4f52b97d12a30a5174aa14257b5e48860f325c5ae
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.11.15

Release files / flux_registry-0.1.0-py3-none-any.whl

Download URL flux_registry-0.1.0-py3-none-any.whl
Size 11.7 kB
Tags Python 3
SHA-256 checksum
How to use checksums
8fbaa13dfff160d3b7209dcdc465281975c35fa59c24a9e5c26a2ffd6d1791d9
BLAKE2b-256 checksum
How to use checksums
ef3e7a4b1389252c158fd1fc91f3ee4bda3b0ef4e5dccad1286d062accdf6c34
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.11.15

Security for flux-registry 0.1.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.

No provenance found

None of the files in this release were uploaded with provenance metadata.

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.

Release history Release notifications | RSS feed

This release

0.1.0 This release

2 release files No provenance

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