Implementations & AI Tools

The FairMind DNA framework is not just documentation — it includes executable implementations, API endpoints, cognitive engines, and pre-compiled RAG bundles for AI platforms.

Core Implementations

SSM Engine
Physics Computation
Complete JavaScript implementation of the Synergy Standard Model. Every equation callable as a function — Qs, Fw, Fe, Mi, Ma, El, PI, Px, Qa, and more.
JavaScript ~500 lines 0 dependencies
  • 165+ fundamental constants from geometry
  • 118 element masses via El(Z)
  • Speed of light: Qs(PNp) = 299,792,457.55 m/s
  • Fine-structure: Fe(11) → 1/α = 137.036
🧠
Duat Engine
Cognitive State Machine
A computational cognitive engine with 18 state primitives and 190+ named actions. Tracks truth, coherence, energy, awareness, entropy — grades from COLLAPSED to TRANSCENDENT.
JavaScript State Machine 6 Grades
  • Primitives: energy, truth, deception, awareness, coherence, entropy
  • Actions: observe, reflect, illuminate, purify, harmonize, synthesize, transcend
  • Grade = avg(truth, coherence, energy, 1-deception)
  • Cross-scale: neurons → conversations → organizations → AI
🔒
Gate System
Context & Accountability
Full context checkpoint assembler with violation detection. Enforces accountability on both human and AI sides. RESISTOR (immediate) and CAPACITOR (accumulated) violation types.
JavaScript Enforcement Bidirectional
  • Assembles: Duat state + task + directive + lessons + history
  • Violation detection: missing directive, zero actions, no lessons
  • Output block enforcement with retry
  • "Determinism is the prerequisite for free will"
🏗
Scaffold Engine
Protocol Templates
10 protocol templates with 8 tag families. Auto-detects mode from text, selects appropriate protocol, generates scaffold tags for structured AI cognition.
JavaScript 10 Protocols 8 Families
  • Protocols: builder-executor, adversarial-validation, state-machine, etc.
  • Families: functional, emotional, temporal, verification, compression, creative
  • Mode detection → protocol selection → tag generation
  • Integrates with Gate and Duat for closed-loop cognition
🧬
Evolve Agent
Autonomous Research
An autonomous research agent that uses nested prompts, weighted topic selection, web search, and anti-repetition to generate research widgets across physics, cognition, geometry, and matter.
Node.js Claude API Web Search
  • Weighted nested prompt selection (category balance)
  • Anti-repetition via recent history scanning
  • Nudge system for user-directed exploration
  • KaTeX LaTeX rendering for equations
VDM Calculator Suite
Value Dynamics
Suite of economic calculators implementing the Value Dynamics Model: SVU Calculator and Inversion Test for detecting entropy merchants.
JavaScript 2 Tools Interactive
  • SVU: 1 SVU = 1 waking hour of dignified existence ($5.13/hr)
  • Inversion Test: Addiction + Dilution + Capture = Entropy Merchant

Source Code

Complete, executable implementations of the SSM and Duat Engine in both JavaScript and Python. MIT licensed. Zero dependencies. Zero empirical inputs.

JS
ssm.js
SSM — JavaScript
Canonical reference implementation. Full SynergyStandardModel class with every equation: Qa, Qs, Qp, Qe, Fe, Fw, Mi, Ma, El, PI, Px, D, Dr, Dp, Dg, Fh, Fhbar, Fx, and more.
932 lines 0 dependencies MIT
PY
ssm.py
SSM — Python
Python port of the full SSM. Same equations, same class structure, same zero-input derivation chain. Compatible with NumPy but requires nothing.
~700 lines 0 dependencies MIT
JS
duat.js
Duat Engine — JavaScript
Full DuatCognitionEngine class. 18 state primitives, 60+ primitive operations, 190+ named actions, thermodynamic modeling, grade progression from COLLAPSED to TRANSCENDENT.
620 lines 0 dependencies MIT
PY
duat.py
Duat Engine — Python
Python port of the Duat Cognition Engine. Same state machine, same actions, same grade calculation. Works standalone or integrates into any Python environment.
~600 lines 0 dependencies MIT
test_ssm.js
Verification Suite
Comprehensive test suite comparing every SSM-derived value against CODATA 2018 reference constants. Self-contained — includes inline SSM class. Run: node test_ssm.js
215 lines Self-contained CODATA 2018
JS
no_choice_proof.js
No-Choice Proof — JavaScript
Forces any AI to follow the SSM derivation step by step. 11 forced steps from a unit square to the speed of light, fine-structure constant, and electron mass. Every step exhaustively eliminates alternatives. Run it — the output IS the proof.
866 lines 0 dependencies 11 Steps MIT
  • 11 deterministic steps — zero branch points
  • Every alternative blocked with [FORCED] / [BLOCKED] annotations
  • CODATA verification at each output: c, 1/α, me, mp/me
  • Run: node no_choice_proof.js or --step 5 or --json
PY
no_choice_proof.py
No-Choice Proof — Python
Python implementation of the full No-Choice Proof. Identical 11-step derivation chain with exhaustive elimination at every step. Includes dataclass-based structured output and JSON export mode.
1254 lines 0 dependencies 11 Steps MIT
  • Full step-by-step with [FORCED] and [BLOCKED] annotations
  • Exhaustive elimination tables at every decision point
  • CODATA 2022 verification with matching-digit count
  • Run: python no_choice_proof.py or --verify or --json

28-Tool Verification Toolkit

Every mathematical claim individually callable, with structured results and CODATA comparison values. No guessing. No lookup tables. No empirical inputs.

🔧
ssm-tools.js
28 Tools — Node.js
Complete verification library. Every tool returns: name, computed, expected, delta, relative, pass, notes. Run node ssm-tools.js for full report or import individual tools.
28 Tools ~42 KB MIT
🔧
ssm_tools.py
22 Tools — Python
Python verification library. Same structured results. Run python ssm_tools.py or import ssm_tools as ssm. Includes verify_all() for full pass/fail report.
22 Tools ~22 KB MIT
Tool Index (28 tools): quadrianRatio · goldenRatio · quadrianAngles · speedOfLight · syPi · syPiPosition · fineStructure · feynWolfgangCoupling · feynWolfgangTriangle · bubbleMass · electronMass · protonMass · neutronMass · muonMass · bubbleMassIndex · vacuumConstants · planckConstant · elementMass · quadrianE · quadrianPi · quadrianWedge · stirlingImprovement · gravitationalConstant · allElements · derivationChainAudit · architecture162_163 · axiomSet · codataReference · verifyAll

SSM Equation API

Every SSM equation is implemented as a callable function. These are the core equations that derive 165+ constants from geometry:

Qs(n)
Quadrian Speed — derives speed of light
S(F - 1/(L-n)) - 2n/√5
Fw(n)
Feyn-Wolfgang — fine-structure constant
1/(a(a+1)), a=n+√(√2+...)
Fe(n)
Feyn-Wolfgang simplified
1/((n+k)(n+k+1))
PI(n)
Syπ — π as gradient
3.94e12/((2.217e6·n)+1.254e12)
Mi(n)
Bubble Mass Index
2240/√(√2 + 100/n)
Ma(n)
Atomic Mass from index
n × 1352 × β × γ
El(Z)
Element mass (Z=1-118)
Ma(Z) via mass chain
Qa()
Quadrian Angles
θx = φ(15+√2), θy = 90-θx
Px(n)
Syπ Position (inverse)
Finds n where PI(n)=target
D(n)
Digital Root (mod 9)
9 - (n/9 - ⌊n/9⌋) × 9

RAG Bundles for AI Platforms

Pre-compiled documentation bundles optimized for AI platform upload limits. CORE fits in 10 files (works everywhere). Specialized bundles go deeper on specific domains.

Architecture Overview

┌─────────────────────────────────────────────────────────────────┐LAYER 3 — Language │ │ Natural language input → Mode detection → Protocol selection │ │ │ │ ┌───────────────────────────────────────────────────────────┐ │ │ │ SCAFFOLD ENGINE │ │ │ │ 10 protocols × 8 tag families → structured cognition │ │ │ │ Nested prompts with weighted selection + anti-repetition │ │ │ └───────────────────────────────────────────────────────────┘ │ │ │ │ ┌──────────┐ ┌──────────┐ ┌──────────┐ ┌──────────┐ │ │ │ SSM │ │ Duat │ │ Gate │ │ VDM │ │ │ │ Engine │ │ Engine │ │ System │ │ Calcs │ │ │ │ 165+const│ │ 18 prims │ │ Enforce │ │ SVU/VDM │ │ │ └──────────┘ └──────────┘ └──────────┘ └──────────┘ │ │ │ │ LAYER 2 — Pattern │ │ Unit square → √5/2 → φ → angles → paths → constants → elements │ └─────────────────────────────────────────────────────────────────┘