OPEN-SOURCE ALPHA · v0.2.0

Keep the coding agent
inside the reviewed intent.

Melampus runs beside an AI coding session. When generated code drifts, it turns fresh local evidence into an immediate gate: repair can continue; unrelated work waits.

15
contract evaluations in the demo
0.84s
observed drift detection
1
agent edit to restore the contract

One recorded 0.1.0 local run; timing is illustrative, not a performance claim. The decorator example remains supported in 0.2.0.

THE CONTROL LOOP

Evidence reaches the agent while the code is still being written.

Melampus owns a companion process and a synchronous gate inside the coding session.

01

Agent edits

The model changes watched implementation files in its normal terminal.

02

Melampus executes

A separate local process reruns approved scenarios and records fresh evidence.

03

Gate decides

Healthy work proceeds. Drift or missing evidence returns the session to repair.

TERMINAL A · SUPERVISOR
cd examples/sdk-registration
melampus session
TERMINAL B · CODING AGENT
cd examples/sdk-registration
claude
# Codex or another agent can use the same gate

WATCH THE PROTOCOL

Two short demonstrations. One honest boundary.

See drift and repair first, then see exactly where unit tests and Melampus overlap.

22 SECONDS

Drift → block → repair

A generated pricing change breaks reviewed bounds. The gate blocks progression until fresh execution passes.

COMPARISON

Unit tests and session evidence

Good tests still catch behavior defects. Melampus adds change-triggered execution, evidence freshness, and an agent gate.

WHAT CHANGES

The oracle is familiar. The control point is different.

Keep pytest and CI. Melampus packages them into a local protocol the coding agent cannot silently step around.

CapabilityUnit tests / CIMelampus session
Assert expected behaviorYesYes — reuses executable checks
Run immediately after watched editsOnly with a watcher or agent disciplineBuilt into the supervisor
Prove evidence belongs to this revisionUsually a CI commit or test invocationRevision-bound session evidence
Distinguish failed from missing evidenceRequires custom orchestrationHealthy, drift, and incomplete states
Block the agent's next unrelated actionUsually after push or on requestSynchronous coding-agent gate

TRY THE ALPHA

Decorate a function. Register an existing service.

Version 0.2.0 lets business methods stay plain: register selected class methods or grouped functions once at application setup. Native decorators remain a familiar option for a few functions.

Download the validated wheel or sdist from the GitHub alpha release. PyPI publication uses a separate Trusted Publisher workflow. The local pilot compares integration styles; human preference remains unmeasured.

git clone https://github.com/melampus-org/melampus-python.git
cd melampus-python
uv sync --locked --all-extras
make demo-registration
make demo-pilot  # synthetic collection walkthrough