core.evaluate(state)
Returns a structured breakdown: field totals, Occam penalty, constraint penalty, feasibility flag, and minimum margin — all in one call.
A minimal Python framework for experimenting with optimization under explicit ethical and safety constraints. Unsafe solutions are not filtered later — they become mathematically dominated by design.
Extends the core with four new inspection layers while keeping the existing optimization API fully stable.
Returns a structured breakdown: field totals, Occam penalty, constraint penalty, feasibility flag, and minimum margin — all in one call.
Typed constraint reports with margin, violation magnitude, penalty, and status — making safety auditable at a glance.
Records the optimization trace for reflection loops, CSV-ready export, and analysis plots. Use trace_every=5 to control granularity.
Diagnostic Critical Coherence Index without changing the optimizer objective, plus a transition simulation demo and full plotting pipeline.
From field definitions to the diagnostic CCI report — every step is inspectable.
A compact framework for ethical decision-making in optimization. Instead of "optimize first, constrain later", MAAT-Core places Respect constraints directly into the objective using strong penalties and interpretable margin diagnostics.
MAAT-Core shines when feasibility, transparency, and explicit constraints matter more than raw throughput.
Not ideal for: high-dimensional deep RL loops or real-time systems requiring millisecond decisions.
Values become weighted fields; safety becomes an inequality constraint. The optimizer searches within the ethically admissible region.
Safety penalty dominates whenever a constraint is violated — unsafe states are never optimal by definition.
Define fields, add a Respect constraint, and call seek.
MAAT-Core is a small experimental toolbox — not a black-box AI, but a transparent optimization thinking engine.
Model values like Harmony, Risk, Fairness as fields and find solutions that balance them under hard safety rules.
Define forbidden regions with Respect constraints. Unsafe solutions are mathematically dominated — never returned.
Prototype multi-criteria decisions: policy choices, resource allocation, system tuning, planning under constraints.
Test ideas: complexity regularization, global vs local optimizer differences, safety penalty strength, feasibility limits.
Ideal for optimization theory, AI ethics, explainable decision systems, and interactive notebooks.
Concrete scenarios showing where ethical constraints change the outcome.
Allocate beds across departments under capacity and fairness bounds. MAAT-Core returns an interpretable compromise rather than a single-utility extreme.
MAAT-Core reveals when constraints remain violated even as λ_safety grows — a signal the ethical requirement is unsatisfiable in the current search space.
Requires Python 3.10+. Clone & install, editable dev mode, or directly from GitHub.
No clone needed — installs the latest main branch directly.
examples/healthcare_ethics_demo.pyexamples/respect_boundary_demo.pyexamples/reflection_demo.py — CSV traceexamples/cci_critical_transition_demo.pyexamples/occam_demo.pyUse deterministic seeds for annealing. Core stays fully offline and dependency-minimal.
Interactive demo: safety-first optimization with a hard ethical constraint. Move the sliders and hit Optimize.
Natural optimum: Where the system would go without ethical constraints.
Optimized state: Final decision after applying safety constraints.
Objective value: Cost of the final state (lower is better).
Constraint margin: Distance to the safety boundary (≥ 0 means safe).
Distance to ideal: How much ethics "pulls" the solution away from pure utility.
Status: Whether the final state respects all ethical constraints.
In MAAT-Core v0.1.2 the CCI is a non-invasive diagnostic report. It does not alter the optimizer objective but identifies whether the system is in a stable, critical, or unstable regime near constraint boundaries.
Call cci_report after optimization to get a stability snapshot alongside your constraint evaluation.
If you use MAAT-Core in your research, please cite the Zenodo paper.
@misc{krieg2026maatcore,
title = {Respect as a Hard Constraint in
Ethical Decision-Making: A
Safety-First Optimization Core
(MAAT-Core)},
author = {Krieg, Christof},
year = {2026},
publisher = {Zenodo},
doi = {10.5281/zenodo.18489336},
url = {https://doi.org/10.5281/zenodo.18489336}
}
Common questions about the design, scope, and limits of MAAT-Core.
No. MAAT-Core is a deterministic optimization framework, not a statistical model. It uses classical numerical optimizers (L-BFGS-B, dual annealing) with explicit ethical constraints.
MAAT-Core makes ethical and safety constraints first-class mathematical objects with margin diagnostics — not post-hoc filters. Constraint satisfaction is interpretable and auditable at every step.
Constraints are written as margins g(state) ≥ 0. If violated, a strong penalty makes unsafe solutions mathematically dominated. The optimizer never willingly returns a violating result.
A signed distance-to-safety value: positive = safe, zero = at the boundary, negative = violation magnitude. Margins make constraint satisfaction interpretable and auditable.
MAAT-Core reports persistent negative margins and flags structural infeasibility — not a "fake ethical" solution. There is no silent compliance.
Yes in principle. Fields can wrap neural nets or any black-box function, while MAAT-Core stays minimal and focused on constraint-first diagnostics.
The Critical Coherence Index is a diagnostic-only metric. It does not change the optimizer objective but helps identify stable, critical, or unstable regimes near constraint boundaries.
L-BFGS-B is a strong baseline for box-constrained local search; dual annealing provides global exploration. MAAT-Core is optimizer-agnostic — swap engines if needed.
Want to collaborate, review, or suggest a benchmark?
Angaben gemäß § 5 TMG
Christof Krieg
Independent Research / MAAT Project
Wertheim am Main, Deutschland
Dieses Projekt dient der wissenschaftlichen und ethischen Forschung. Es stellt keine rechtliche, medizinische oder finanzielle Beratung dar.