Metadata-Version: 2.4
Name: mb8
Version: 0.1.0a0
Summary: Mathematical Brain 8-Level architecture — full training library
Author: MB-8 Team
License: MIT
Project-URL: Homepage, https://github.com/anomalyco/mb8
Project-URL: Source, https://github.com/anomalyco/mb8
Project-URL: BugTracker, https://github.com/anomalyco/mb8/issues
Keywords: deep-learning,transformer,ssm,language-model,pytorch
Classifier: Development Status :: 3 - Alpha
Classifier: Intended Audience :: Science/Research
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Topic :: Scientific/Engineering :: Artificial Intelligence
Classifier: Topic :: Software Development :: Libraries :: Python Modules
Requires-Python: >=3.11
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: torch>=2.4.0
Requires-Dist: numpy>=1.26
Requires-Dist: einops>=0.7
Requires-Dist: safetensors>=0.4
Requires-Dist: pyyaml>=6.0
Requires-Dist: scipy>=1.13
Requires-Dist: rich>=13
Requires-Dist: transformers>=4.44
Requires-Dist: datasets>=2.19
Requires-Dist: huggingface-hub>=0.23
Requires-Dist: tqdm>=4.66
Requires-Dist: tensorboard>=2.17
Requires-Dist: wandb>=0.17
Provides-Extra: dev
Requires-Dist: pytest>=8; extra == "dev"
Requires-Dist: pytest-cov; extra == "dev"
Requires-Dist: mypy>=1.10; extra == "dev"
Requires-Dist: ruff>=0.4; extra == "dev"
Dynamic: license-file

# MB-8: Mathematical Brain 8-Level Architecture

**MB-8** — full-training library for a novel 8-level neural architecture combining SSM, Hopfield networks, working memory, predictive coding, and plasticity mechanisms.

## Features

- **8 architectural levels**: Membrane → Synapse → Dendrites → SSM → Hopfield/Phase → Working Memory → Error → Plasticity/Consolidation
- **Multiple model variants**: SingleStream, DualStream, MB8ForCausalLM (full 8-level)
- **Training modes**: Pretrain (CLM), SFT (chat-style), GRPO (RL)
- **Notebook API**: Transformers-style `Trainer` + `TrainingArguments` for Jupyter/Colab
- **CLI tools**: `mb8-train`, `mb8-sft`, `mb8-grpo`, `mb8-eval`, `mb8-inspect`
- **Epistemic framework**: Hypothesis-driven development with go/no-go criteria

## Quickstart

```python
from mb8 import MB8Config, MB8ForCausalLM, TrainingArguments, Trainer

model = MB8ForCausalLM(MB8Config.from_preset("tiny_10m"))
trainer = Trainer(
    model=model,
    args=TrainingArguments(output_dir="outputs", max_steps=100),
    train_dataset=...,
)
trainer.train()
```

## Installation

```bash
pip install mb8
```

## Documentation

See `api-docs/` for full reference and quickstart guide.

## License

MIT
