{"_id":"axiomize","name":"axiomize","dist-tags":{"latest":"1.12.2"},"versions":{"1.12.2":{"name":"axiomize","version":"1.12.2","description":"Rigorous scientific modeling engine and agent skill pack","main":"index.js","bin":{"axiomize":"bin/axiomize.js"},"scripts":{"test":"echo \"Error: no test specified\" && exit 1"},"keywords":["modeling","simulation","scientific-computing","agent-skills","bayesian","causal-inference"],"author":{"name":"Furox-Art"},"license":"MIT","repository":{"type":"git","url":"git+https://github.com/Furox-Art/axiomize.git"},"bugs":{"url":"https://github.com/Furox-Art/axiomize/issues"},"homepage":"https://github.com/Furox-Art/axiomize#readme","_id":"axiomize@1.12.2","gitHead":"fd0c9c9c6954e765df582bcfbb0e001ee5c00d36","_nodeVersion":"22.23.2","_npmVersion":"10.9.8","dist":{"integrity":"sha512-jUPhQsfE/8H+Bqi6O6eqh0i5RMYiRV4f0tRnq9eRUfBN5/HRY96j8N06XCbaJg/y7xqMFmCmHeCDMft8TwhraQ==","shasum":"0c0d490bb36eeff06020553496120df41d6b78d7","tarball":"https://registry.npmjs.org/axiomize/-/axiomize-1.12.2.tgz","fileCount":258,"unpackedSize":1847409,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEUCIGXQhwfRLX25q3Wx8l4TKQyiHf06X4yROD8DUjYzHAKcAiEAzWEDL/1WgIuZQdfi40HaHTrvdBhV8UooR/n9AOUzhew="}]},"_npmUser":{"name":"furox-art","email":"real.furkannn@gmail.com"},"directories":{},"maintainers":[{"name":"furox-art","email":"real.furkannn@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/axiomize_1.12.2_1790629560963_0.7127129967952732"},"_hasShrinkwrap":false}},"time":{"created":"2026-09-28T21:06:00.738Z","1.12.2":"2026-09-28T21:06:01.113Z","modified":"2026-09-28T21:06:01.241Z"},"maintainers":[{"name":"furox-art","email":"real.furkannn@gmail.com"}],"description":"Rigorous scientific modeling engine and agent skill pack","homepage":"https://github.com/Furox-Art/axiomize#readme","keywords":["modeling","simulation","scientific-computing","agent-skills","bayesian","causal-inference"],"repository":{"type":"git","url":"git+https://github.com/Furox-Art/axiomize.git"},"author":{"name":"Furox-Art"},"bugs":{"url":"https://github.com/Furox-Art/axiomize/issues"},"license":"MIT","readme":"# Axiomize\n\n![License](https://img.shields.io/badge/license-MIT-blue)\n![Python](https://img.shields.io/badge/python-3.10%2B-informational)\n![CI](https://github.com/Furox-Art/axiomize/actions/workflows/ci.yml/badge.svg)\n[![PyPI](https://img.shields.io/pypi/v/axiomize)](https://pypi.org/project/axiomize/)\n[![Downloads](https://img.shields.io/pypi/dm/axiomize)](https://pypi.org/project/axiomize/)\n\n**A versioned scientific modeling engine and Agent Skill for turning an idea into explicit, testable, reproducible mathematical models.**\n\nAxiomize combines a machine-readable Model IR with native scientific executors, validation, fitting, uncertainty analysis, causal/Bayesian inference, formal/numerical checks, portable export, and an adaptive modeling workflow. It is designed to make assumptions, solver choices, uncertainty and failure modes visible rather than burying them in generated prose.\n\nCurrent package line: **1.12.2**. Version **1.11.2** was the repository-wide security/runtime hardening release; 1.12.0 added the full scientific stress matrix, Causal Engine 2.0, Bayesian convergence/PPC diagnostics, real optional FEniCS FEM execution, family-wide numerical verification and broader export. Version 1.12.1 fixed DOLFINx-aware PDE solver selection; 1.12.2 tightens release/documentation consistency and exact numeric/run-integrity boundaries after a follow-up repository audit.\n\n## Install\n\n```bash\npip install -U axiomize\n```\n\nOptional PyMC/JAX support:\n\n```bash\npip install -U \"axiomize[full]\"\n```\n\nFEniCS/DOLFINx is intentionally an external optional backend because its installation is platform/HPC dependent. When present, Axiomize probes the real runtime before advertising it.\n\n## Core contract\n\nAxiomize uses a versioned **Model IR** as the single source of truth for solve/simulate/fit/validate/export. A model can describe:\n\n- variables, parameters and units;\n- equations and equation roles;\n- initial and boundary conditions;\n- scientific assumptions and validity domain;\n- solver settings and fallbacks;\n- causal-identification metadata;\n- provenance and migration history.\n\nSchema migration is never silent: unsupported/newer schemas are rejected and supported migrations require explicit approval with a visible preview.\n\n## Native model families\n\nThe Model IR supports native execution contracts for:\n\n| Family | Native path |\n|---|---|\n| algebraic | SymPy nonlinear solve |\n| ODE | SciPy IVP with solver fallbacks |\n| PDE | bounded method-of-lines reaction/diffusion |\n| DAE | semi-explicit index-1 solve |\n| stochastic | Euler-Maruyama / stochastic executors |\n| optimization | bounded nonlinear optimization |\n| control | state-space simulation/stability |\n| network | graph-coupled dynamics |\n| Bayesian | bounded multi-chain Metropolis inference |\n| agent-based | per-agent trajectories |\n| discrete-event | bounded event queue/Gillespie-style execution |\n| hybrid | event-driven piecewise ODE |\n| multiphysics | approval-gated partitioned co-simulation |\n| causal | identified treatment-effect estimation |\n\nNo unsupported family is silently replaced with a toy reference model.\n\n## Causal Engine 2.0\n\nCausal conclusions require identification evidence. Fit/correlation alone is not treated as causality.\n\nThe 1.12 engine adds:\n\n- acyclic DAG validation;\n- explicit or DAG-derived backdoor adjustment sets;\n- rejection of post-treatment adjustment variables;\n- AIPW doubly-robust estimation for binary treatment;\n- IPW and outcome-regression estimates alongside AIPW;\n- robust linear backdoor adjustment for continuous treatment;\n- propensity overlap/positivity diagnostics;\n- effective sample size under weighting;\n- standardized mean-difference balance before/after weighting;\n- intervention/counterfactual mean predictions;\n- explicit causal scope and assumptions in every result.\n\nIf identification is insufficient, the engine returns `INSUFFICIENT_CAUSAL_EVIDENCE` and states what evidence is missing.\n\n## Bayesian diagnostics and posterior predictive checks\n\nThe package-native Bayesian engine now runs bounded multi-chain random-walk Metropolis sampling and reports:\n\n- split R-hat;\n- bulk effective sample size;\n- Monte Carlo standard error of the mean;\n- 95% posterior interval/HDI-style summary;\n- per-chain acceptance rate;\n- posterior predictive RMSE;\n- 90%/95% predictive coverage;\n- Bayesian p-values for replicated mean and standard deviation.\n\nSampling remains approval-gated when the compute estimate is material, and hard likelihood/allocation ceilings cannot be bypassed with an approval flag.\n\n## Numerical verification for every family\n\nNumerical/discretization uncertainty is reported separately from parameter, data, aleatoric and structural uncertainty.\n\nDedicated studies:\n\n- ODE: tolerance refinement;\n- DAE: tolerance refinement;\n- PDE: mesh refinement with observed-order/Richardson-style estimates.\n\nOther executable families receive an explicit bounded verification contract using either output-resolution refinement or deterministic same-seed replay, whichever is scientifically meaningful. For stochastic/Bayesian/agent/event models, same-seed replay checks implementation/numerical reproducibility; **between-seed variation is not mislabeled as numerical error**.\n\nRepeated refinement multiplies solver work, so it requires explicit approval.\n\n## Real optional FEniCS FEM executor\n\n`FEniCSAdapter` no longer claims availability merely because an import exists. In 1.12 it contains a real, structured FEM path for scalar Poisson problems using:\n\n- DOLFINx + UFL + PETSc when available; or\n- legacy FEniCS when available.\n\nThe bounded contract currently supports P1 Lagrange elements on a unit interval or unit square with constant source and Dirichlet boundary data. It deliberately does **not** execute arbitrary user-supplied Python/UFL strings.\n\nCheck availability:\n\n```bash\naxiomize tools\naxiomize capabilities\n```\n\n## Scientific benchmark and stress gates\n\nAxiomize has two complementary regression layers:\n\n1. package/reference benchmark cases for correctness and model-selection behavior;\n2. an **all-family scientific stress matrix** that executes every Model IR family through the installed wheel, checks adversarial parser boundaries, verifies the numerical-verification approval contract, exercises extended exports, and enforces per-case/total runtime budgets.\n\nThe scientific stress matrix is a permanent exact-wheel CI and release prerequisite. A PyPI release cannot proceed unless it passes together with the ordinary tests, dependency/security audit, import graph checks, installed CLI checks and cross-platform wheel smoke tests.\n\n## Export\n\nPortable/native formats include:\n\n- JSON Model IR;\n- generated Python;\n- Jupyter notebook (`ipynb` / nbformat 4);\n- SBML Level 3 Version 2 for the conservative supported subset;\n- CellML 2.0 for the conservative supported subset;\n- Modelica 3.6 textual models for supported algebraic/ODE/DAE equations;\n- GraphML for network models;\n- Graphviz DOT for causal DAGs;\n- `axiomize.portable-bundle.v1`, containing canonical Model IR, assumptions, provenance and SHA-256 integrity metadata;\n- YAML when the optional YAML dependency is available.\n\nStandards adapters fail honestly with `ADAPTER_REQUIRED` when a model cannot be represented without changing its meaning.\n\n## Scientific tool stack\n\nCore runtime dependencies include NumPy, SciPy, SymPy, statsmodels, NetworkX, Matplotlib, Z3, python-control, CVXPY and CasADi. Optional integrations include PyMC, JAX, Lean and FEniCS/DOLFINx.\n\nThe router only selects a backend whose availability probe actually passes. Optional-backend absence is surfaced explicitly instead of being disguised as a successful tool call.\n\n## Data, fitting and model criticism\n\nThe engine supports:\n\n- conservative data cleaning with original-data preservation and an audit trail;\n- SIR/logistic reference fitting and generic ODE fitting;\n- identifiability and residual diagnostics;\n- AIC/BIC comparison and simplest-sufficient-model preference;\n- sensitivity and validity scans;\n- local stability analysis;\n- sparse dynamics/SINDy-style discovery;\n- experiment-time ranking by a Fisher-information proxy;\n- validated polynomial surrogate/reduced-order models with untouched holdout data and extrapolation blocking.\n\nConstraint violations are visible PASS/FAIL records. Rebuild/refit after a failed scientific constraint requires approval and preserves the failed model/result.\n\n## Security and trust boundaries\n\nThe 1.11.2 hardening line remains part of the 1.12 contract:\n\n- AST-whitelisted mathematical expressions translated without arbitrary Python evaluation;\n- hard expression, array, graph, draw, event, process and solver ceilings;\n- arbitrary Python/Lean execution disabled by default and explicitly marked as not being an OS sandbox;\n- REST request/concurrency/read-time limits, loopback-by-default binding and auth for remote binding;\n- run-root path confinement and run-state integrity hashes;\n- provider URL/redirect/response limits;\n- LaTeX macro allow-list and `-no-shell-escape` compilation;\n- Z3 timeout/domain guards;\n- immutable-SHA GitHub Actions dependencies;\n- dependency vulnerability audit and security-contract CI.\n\nSee [SECURITY.md](SECURITY.md) and [docs/security.md](docs/security.md).\n\n## Release integrity\n\nEvery package release must pass:\n\n- Python 3.10 / 3.11 / 3.12 / 3.13 validation;\n- security contract and dependency audit;\n- source and installed import-graph checks;\n- exact built-wheel install and full CLI contract;\n- Model IR, advanced-family, export, surrogate and LaTeX release smokes;\n- all-family scientific stress matrix;\n- exact-wheel CLI smoke on **Ubuntu/Linux, Windows and macOS**;\n- Trusted Publishing-first PyPI publication and post-publication verification.\n\n## Adaptive workflow\n\nThe Agent Skill can clarify a vague idea, recommend weak/medium/strong depth, construct multiple defensible candidate models, compare the best candidates, expose conflicts, quantify uncertainty, and produce falsifiers/experiment plans.\n\nExpensive work is not silently multiplied. Large Monte Carlo runs, broad sweeps, Bayesian sampling, multiphysics co-simulation, repeated numerical refinement, extra paid model calls and whole-analysis reruns are approval-gated.\n\n## Interfaces\n\nThe same application-service layer is available through:\n\n- Python;\n- CLI;\n- REST API v1;\n- MCP over stdio.\n\n```bash\naxiomize capabilities\naxiomize serve --port 8765\naxiomize mcp\n```\n\nREST binds to loopback by default. Remote binding requires explicit opt-in plus authentication.\n\n## Reference checks\n\n```bash\n# package-native benchmark\naxiomize benchmark\n\n# deterministic SIR reference validation\naxiomize-validate --model sir --beta 0.3 --gamma 0.1\n\n# stochastic validation\naxiomize-validate --model gillespie --N 10000 --I0 1 --runs 300\n\n# report conversion\naxiomize-to-latex --input report.md --output report.tex\n```\n\n## Reproducibility\n\nAxiomize records the information needed to explain and reproduce a run: Model IR/schema version, parameters, solver/method, tool/package versions, seeds, data hashes, preprocessing, assumptions, validation results and outputs. Run-state persistence uses atomic writes and integrity verification.\n\n## Design rules\n\n1. No undefined model symbols.\n2. Units/dimensional consistency are checked where defined.\n3. Mechanism uncertainty is explicit.\n4. Multiple plausible models are compared when evidence permits.\n5. Causal claims require identification, not correlation.\n6. Numerical error is not conflated with scientific uncertainty.\n7. Original data and failed models are preserved.\n8. Tool/solver conflicts are shown, not hidden.\n9. Expensive or paid work is approval-gated.\n10. Release claims must be demonstrated on the exact wheel that is published.\n\nSee [skills/axiomize/adaptive-workflow.md](skills/axiomize/adaptive-workflow.md), [ROADMAP.md](ROADMAP.md), and [CONTRIBUTING.md](CONTRIBUTING.md).\n\n## License\n\nMIT\n","readmeFilename":"README.md","_rev":"1-fc35c97d3cbfd5e5b64f05b2b088da95"}