Audited witnesses
--
Maniflood
Unified category-theoretic audit of the trading pipeline (branches A · B · C)
Categorical Audit
Unified audit · branches A · B · C
Three independent structural audits run over the same engine: the
tesseract sign-series as a confluent rewrite graph (A), the
adaptive-meta stage as an indexed natural transformation
ηd (B), and the trade ledger as a category with
an associative composition and a monotone sizing functor (C). Each emits falsifiable
witnesses, all reproducible from scripts/categorical_audit_all.py.
--
--
--
--
The curvature sign-state series as a rewrite graph, checked for confluence.
Each curvature sample lands on a sign-pattern vertex (e.g. +-+-); consecutive
samples induce directed edges. The audit checks two-path redundancy
(a Church–Rosser / confluence condition): any two rewrite routes between the same
endpoints must agree, so the series has a well-defined terminal state.
+-+-
Two-path redundancy: ok — max intermediate count 0, no ambiguous
pairs. The dominant edge +-+- → +-+- fires 95×, i.e. the regime is a
stable fixed point over this window.
What objects, morphisms, and indices the audit assigns to the adaptive-meta stage.
The audit changes no trading semantics. It centralizes the adaptive-meta math and exposes falsifiable witnesses for the structural laws below.
For a pipeline morphism f, applying ηd should commute with f.
The residual is the commutation error measured on the scalar projections (score, alpha, confidence) plus an action-match flag. Identity morphisms commute exactly; nonlinear pipeline morphisms leave a measured residual, which is exactly what the audit surfaces.
Synthetic signal battery checked at drawdown d = 0.25 (from the CLI audit).
| Signal | Fibration monotone | η & identity | η & score-scale | action @ d=0.25 | section flips→hold |
|---|
"commutes" means residual within tolerance (1e-6); "residual" means the morphism is nonlinear enough to leave a measured commutation gap. Hover a cell for its score residual.
Move along the fibration base B and watch ηd re-weight a signal live.
| d | score penalty ↑ | alpha scale ↓ | score | alpha | action |
|---|
Fibration consistency requires score penalty to be non-decreasing and alpha scale non-increasing along d. A ▲ marks any violation; the math is computed in your browser from the same coefficients as the live engine.
ηd commuted against the live pipeline morphisms on the curvature base.
| Morphism f | Verdict | |Δscore| | |Δalpha| | |Δconfidence| | action match |
|---|---|---|---|---|---|
| flow-hybrid | residual | 0.0872 | 0.0143 | 0.0403 | yes |
| de Rham | residual | 0.0572 | 0.0109 | 0.0218 | no |
| full pipeline | residual | 0.1129 | 0.0192 | 0.0532 | yes |
These morphisms act on the curvature-realized base, so they are audited once for the pipeline rather than per instrument. The de Rham square breaks action match: at d = 0.25 the adaptive-meta order vs. de Rham order disagree on the discrete action, which is exactly the kind of ordering defect the audit is built to expose.
Closed trades as composable morphisms on equity, with a sizing functor.
Objects are equity states; each closed trade is a morphism between them, and composing the whole chain must be associative — the realized equity path may not depend on how trades are bracketed. The position-sizing rule is audited as a functor whose multiplier must not jump up after a drawdown.
Prefix multipliers stay flat at 1.0 across all 7 trades and the full-window multiplier is
1.0 (reason: insufficient_closed_trades to scale up), so the sizing functor is
trivially monotone here — conservative by construction on a short ledger.
Structural guarantees that a pile of if-statements cannot give you.
scripts/categorical_audit_all.py --branch all --synthetic.