Sign inSign up

wiseaidev/lmm

By wiseaidev

โ€ขUpdated 5 months ago

๐Ÿฆ€ A pure rust framework for building real autonomous super agents.

Image
Languages & frameworks
Machine learning & AI
Developer tools
0

902

wiseaidev/lmm repository overview

โ ๐Ÿ‘๏ธ LMM ๐Ÿฆ€

LMM

Work In Progress Crates.io Docs.rs Crates.io Downloads PyPI version NPM version made-with-rust Rust License Maintenance

Share On Reddit Share On X Share On Linkedin

LMM (Large Mathematical Model) is a pureโ€‘Rust framework that models higherโ€‘dimensional reality through symbolic mathematics and physics simulation; Inspired by the Pharaonic model of intelligence: compress the world into durable, universal equations. No training. No GPU. No API key.

๐Ÿง Linux (Recommended)๐ŸชŸ Windows๐Ÿณ Docker
lmm-linuxlmm-windowslmm-linux
Download lmm binaryโ Download lmm.exe binaryโ docker pull wiseaidev/lmm
cargo install lmm --features rust-binarycargo install lmm --features rust-binarydocker run -it wiseaidev/lmm
lmm โ† launches CLIlmm โ† launches CLIRead DOCKER.mdโ 

โ ๐ŸŽฌ Demo

The following demonstrates the symbolic prediction engine generating coherent English sentences powered entirely by deterministic mathematical equations and structural Subject-Verb-Object grammar; No neural networks, no statistical models. The engine supports a full suite of CLI subcommands including predict, summarize, sentence, paragraph, essay, and ask, enabling multi-paragraph construction driven entirely by mathematics.

โ ๐Ÿง  What Does LMM Provide?

LMM bridges multimodal perception and actionable scientific discovery through five tightly integrated layers:

LayerModulesPurpose
Perceptionperception.rs, tensor.rsRaw bytes โ†’ normalised tensors
Symbolicequation.rs, symbolic.rs, discovery.rsGP symbolic regression, differentiation, simplification
Physicsphysics.rs, simulation.rsODE models + Euler / RK4 / RK45 / leapfrog integrators
Causalcausal.rsSCM graphs, do-calculus interventions, counterfactuals
Cognitionconsciousness.rs, world.rs, operator.rsFull perceive โ†’ encode โ†’ predict โ†’ act loop
โ โš™๏ธ Architecture
flowchart TD
    A["Raw Input\n(bytes / sensors)"]
    B["MultiModalPerception\n โ†’ Tensor"]
    C["Consciousness Loop\nperceive โ†’ encode โ†’ predict\nevaluate โ†’ plan (lookahead)"]
    D["WorldModel\n(RK4 physics)"]
    E["SymbolicRegression\n(GP equation search)"]
    F["CausalGraph\nintervention / counterfactual"]
    G["Expression AST\ndifferentiate / simplify"]

    A --> B --> C
    C --> D
    C --> E
    E --> G
    G --> F
    D --> F
โ ๐Ÿ”ฌ Key Capabilities
  • ๐Ÿงฌ Genetic Programming: population-based symbolic regression with template seeding (linear, quadratic, periodic) and variable-enforcement guards.
  • ๐Ÿ“ Symbolic Calculus: automatic differentiation (chain rule, product rule, trig) and constant-folding simplification.
  • ๐ŸŒ€ Physics Suite: Harmonic Oscillator, Lorenz Attractor, Pendulum, SIR Epidemic, N-body Gravity; All implement Simulatable.
  • ๐Ÿ”ข Field Calculus: N-D gradient, Laplacian, divergence, and 3-D curl via central differences.
  • ๐Ÿ”— Causal Reasoning: structural causal models, do(X=v) interventions, and counterfactual queries.
  • ๐Ÿงฉ Neural Operators: circular convolution with SGD kernel learning and Fourier spectral operators.
  • ๐Ÿ”ค Text โ†” Equation: losslessly encode any text string into a symbolic equation and recover it exactly via integer residuals.
  • ๐Ÿ”ฎ Symbolic Prediction: equation-native text continuation using sliding-window GP regression and vocabulary anchoring.
  • ๐ŸŽฒ Stochastic Enhancement: synonym-bank word replacement (--stochastic) delivers unique output each run while preserving mathematical sentence structure.
  • ๐ŸŽจ Spectral Image Synthesis: generate procedural PPM images from a text prompt by hashing it into Fourier wave components.

โ ๐Ÿ“ฆ Installation

The lmm crate ships the following Cargo features:

FeatureDescription
rust-binaryEnables the standalone lmm terminal CLI executable
cliCore CLI scaffolding (subsets of rust-binary)
netInternet-aware ask command via DuckDuckGo search
pythonPython extension module via pyo3 / maturin
nodeNode.js native add-on via napi-derive

โ ๐Ÿฆ€ Rust

The lmm library is available on crates.ioโ . For the complete API reference, installation guide, and worked examples, see the Rust usage guideโ .

โ ๐Ÿ’ป Command-Line Interface

The lmm binary supports 15 subcommands spanning simulation, discovery, encoding, prediction, summarisation, and rich text generation: all powered by pure equations.

For the full option reference and usage examples, see the CLI documentationโ  or run lmm --help after installing with cargo install lmm --features rust-binary.

โ ๐Ÿ Python

The Python bindings are published to PyPI as lmm-rs and are installed with pip install lmm-rs. Built with maturinโ , the package ships pre-compiled wheels for major CPython versions and runs a fully embedded Tokio runtime; no asyncio required.

For installation instructions, configuration options, and full method signatures, see the Python usage guideโ .

โ ๐ŸŸฉ Node.js

The Node.js bindings are published to npm as @wiseaidev/lmm and are installed with npm install @wiseaidev/lmm. Built with napi-rsโ , the package ships a pre-compiled .node add-on with TypeScript type definitions.

For installation instructions, type definitions, and examples, see the Node.js usage guideโ .

โ ๐ŸŒ WebAssembly (WASM)

LMM natively targets wasm32-unknown-unknown. Because reqwest switches to the browser fetch API automatically, you can deploy LMM inside Rust frontend frameworks such as Yew, Dioxus, and Leptos without any additional glue code.

For CORS considerations, build steps, and usage details, see the WASM usage guideโ .

โ ๐Ÿค– Agent Framework

The lmm-agent crate extends LMM with a fully autonomous, equation-based agent layer; no LLM, no API key, no training data.

DocumentDescription
AGENT.mdโ Architecture, quick-start, types, and async API reference
DERIVE.mdโ #[derive(Auto)] macro: generated traits and field contract
lmm-agent READMEโ Crate-level API reference, builder, and example
lmm-derive READMEโ Macro crate details and field rules

โ ๐Ÿ“ฐ Publications & Research

The architecture, formal mathematics, and paradigm are fully documented in the official whitepaper: Read the Whitepaper (PDF)โ .

โ Blog Posts

โ ๐Ÿ“ Citation

If you use LMM in your research, please cite our whitepaper:

@article{harmouch2026lmm,
  author  = {Mahmoud Harmouch},
  title   = {Mathematics Is All You Need: Training-Free Language Generation via
             Symbolic Regression and Stochastic Determinism},
  year    = {2026},
  url     = {https://github.com/wiseaidotdev/lmm}
}

โ ๐Ÿค Contributing

Contributions are welcome! Feel free to open issues or pull requests on GitHubโ .

โ ๐Ÿ“„ License

Licensed under the MIT Licenseโ .

โ โญ Star Us

If you use or enjoy LMM, please leave us a star on GitHubโ ! It helps others discover the project and keeps the momentum going โ˜•.

Star History Chart

Tag summary

Content type

Image

Digest

sha256:bf174e09cโ€ฆ

Size

8.3 MB

Last updated

5 months ago

docker pull wiseaidev/lmm