A model's edit reaches the working tree before anyone has read it.

Left to run, an agent edits a file and keeps going. The check, if it comes, comes later: at review, at commit, at the moment a leaked credential is already in the history. By then the model has moved three steps past the mistake, and the operator is reading diffs instead of building.

hux closes the gap in time. It is the binary Claude Code invokes on every lifecycle event, and it runs synchronously against the file the model just touched, the instant it is touched. Violations go back into the conversation while the model is still on the same thought, not into a report read after the fact. A final pass fires when the session tries to stop, so a session cannot end with unresolved violations sitting in the tree.

hux is installed and driven by the ae-sys orchestrator, one of three binaries in the harness. This page is about the one that does the checking.

One executor over a layer of focused checkers.

hux is a single Rust binary. The work is split into a layer of small internal crates, each owning one kind of check; one shared crate underneath carries the config, the audit trail, and the machine-checked event schema every other crate reads from. The binary is the dispatcher. The crates are where the checking lives.

Anatomy hux
01 Executor
a single Rust binary; the one entry Claude Code calls
02 Dispatcher
reads the event, routes it by type to a focused handler
03 Substrate
one shared layer under every checker: config, audit trail, machine-checked event schema
04 Structure
file, function, parameter, and naming limits, per language
05 Security
credential and footgun scanning, baselined per agent
06 Steering
bash footgun blocking, project-runtime redirection

Event in, verdict out, one shape both ways.

A lifecycle event arrives at one router. The router decides where it runs: on a desktop it hands the event to the native executor; in the remote runtime, where the binary does not exist, it falls back to a small per-event bash subset. Either way the handler returns the same verdict shape, so the model sees one contract.

event to verdict hux
Lifecycle event the model edits, runs, or finishes a tool call
Native executor
01 Router
full runtime present
02 Dispatch
read the event, route by type to its handler
03 Check
run the matching checker on the touched file
04 Feedback
a violation is written back into the conversation
Remote fallback
Router
no native binary in the runtime
Subset
a small per-event bash script covers the core lifecycle
Passthrough
an unrecognised event passes through clean
Verdict one shape both paths: continue · block · approve

What runs on the file, and on the command before it runs.

The checker layer covers what goes wrong in an agentic session. Each edit is held to the project's per-language limits, then swept for credential leaks and injection-shaped code; the commands around it are read before they run, timed, and steered toward the runtime the project actually uses. The moments that matter come back as native alerts.

What it runs hux
Validation
Every edit held to the project's shape, the instant it lands.
Security
Credentials and footguns, flagged.
Steering
Footguns denied, commands redirected.
Profiling
Every command timed, overruns ended.
Notifications
The moments that matter, surfaced live.
In conversation
Violations return on the same thought.
Stop gate
No session ends with violations in the tree.

A check that comes later is a check that comes too late.

Before / after hux
Without it
The violation surfaces at review, after the model has moved on and the operator is reading diffs.
With hux
The same violation comes back in-conversation at edit time, and the session cannot stop until the tree is clean.
work