Foundational industrial AI model for real-time telemetry, IoT, and time-series
Project description
VULGARIS is an open-source foundational model for industrial time-series data — built from scratch in pure NumPy with a custom reverse-mode autograd engine. No PyTorch. No TensorFlow. No CUDA required.
It is designed for real-world deployments in telecom networks, IoT sensor grids, SCADA systems, and edge hardware where data is streaming, multimodal, and non-stationary.
Architecture
Input (B, C, T)
│
▼
┌──────────────────────────────────────────────────────┐
│ ASE — Adaptive Signal Embedding (Morlet wavelets) │
│ HTD — Hierarchical Timescale Decomposition (4×SSM) │
│ SSSR — Selective State-Space Recurrence (diag ZOH) │
│ DAH — Domain-Adaptive Hypernetwork (LoRA) │
│ CRG — Causal Routing Graph (NOTEARS DAG) │
│ HMB — Hierarchical Memory Bank (VAE slots) │
│ Safety — Control Barrier Function head │
│ ESE — Explainability Engine (CART rules) │
└──────────────────────────────────────────────────────┘
│
▼
Output + Aux losses (DAG penalty, memory loss, CBF)
Installation
# Core (numpy only — no optional deps)
pip install vulgaris
# With inference server
pip install "vulgaris[serve]"
# Full install
pip install "vulgaris[all]"
Quick Start
import numpy as np
from vulgaris import Vulgaris, ModelConfig
# Configure
config = ModelConfig(
input_dim=9, # number of input channels
n_classes=5, # set 0 for regression
output_dim=1,
)
# Build model
model = Vulgaris(config)
# Forward pass
x = np.random.randn(8, 9, 64).astype(np.float32) # (batch, channels, time)
from vulgaris import Tensor
output, aux = model(Tensor(x))
print(output.data.shape) # (8, 5)
# Streaming single-step inference
state = model.init_state(batch_size=1)
x_t = Tensor(np.random.randn(1, 9).astype(np.float32))
out_t, state = model.step(x_t, state)
Training
from vulgaris import (
Vulgaris, ModelConfig,
TrainingPipeline, VulgarisLoss,
SpectralAdamW, CosineSchedule,
)
config = ModelConfig(input_dim=9, n_classes=5)
model = Vulgaris(config)
loss_fn = VulgarisLoss(config)
optimizer = SpectralAdamW(model.parameters(), lr=3e-4)
scheduler = CosineSchedule(optimizer, warmup_steps=1000,
max_steps=50_000, min_lr=1e-6)
pipeline = TrainingPipeline(model, config, loss_fn, optimizer, scheduler)
# Train
x_np = np.random.randn(32, 9, 64).astype(np.float32)
y_np = np.zeros(32, dtype=np.float32)
metrics = pipeline.train_step(x_np, y_np)
print(metrics)
From Environment (production)
export VULGARIS_INPUT_DIM=9
export VULGARIS_N_CLASSES=5
export VULGARIS_D_MODEL=256
from vulgaris import ModelConfig, Vulgaris
config = ModelConfig.from_env()
model = Vulgaris(config)
Serve via REST API
pip install "vulgaris[serve]"
export VULGARIS_INPUT_DIM=9
export VULGARIS_N_CLASSES=5
vulgaris-serve
# → http://localhost:8000
# → http://localhost:8000/docs
# → http://localhost:8000/metrics
Docker
docker compose up
Key Features
| Feature | Description |
|---|---|
| Pure NumPy | No PyTorch/TF/JAX — runs anywhere Python runs |
| Custom Autograd | Tape-based reverse-mode with graph freeing |
| State-Space Core | Diagonal ZOH SSM, sub-quadratic in sequence length |
| Causal Discovery | NOTEARS DAG learns causal structure online |
| Domain Adaptation | LoRA hypernetwork, switch domains at inference time |
| Explainability | CART rule extraction from latent representations |
| Safety | Control Barrier Function output head |
| Conformal Prediction | Non-stationary coverage guarantees |
| Streaming | Single-step .step() API for edge deployment |
| Multi-modal | InfoNCE cross-modal alignment (CMLA) |
| Federated | Differential privacy + federated continual learning |
| Drift Detection | KS, MMD, Wasserstein-1D drift monitoring |
Repository Structure
vulgaris-ai/
├── vulgaris/ ← Public API entry point
├── engine/ ← Autograd engine (Tensor, Module, Layers)
├── modules/ ← Model building blocks
├── model/ ← Full Vulgaris model
├── training/ ← Loss, optimizer, pipeline, self-supervised
├── inference/ ← FastAPI server + streaming
├── serve/ ← Auth, metrics, degradation, versioning
├── monitoring/ ← Drift detection
├── federated/ ← Federated continual learning
├── benchmarks/ ← Baselines + dataset loaders
├── tests/ ← Unit + integration tests
└── config.py ← All configuration dataclasses
Citation
@software{vulgaris2026,
title = {VULGARIS: Foundational Industrial AI Model},
year = {2026},
url = {https://github.com/vulgaris-ai/vulgaris},
license = {Apache-2.0},
}
License
Apache License 2.0 — see LICENSE.
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file vulgaris-0.1.1.tar.gz.
File metadata
- Download URL: vulgaris-0.1.1.tar.gz
- Upload date:
- Size: 101.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.14.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
e7e992eadff2bef10e7475cf83b1d710e5cbd35d0d2b1c3b1fa5d08ebc04d313
|
|
| MD5 |
80ddb6955285cf52db29998a3c3dc575
|
|
| BLAKE2b-256 |
7d70e0e2ce4efc5ee27b7148bde95e685ae2d524a67d3d7b0d464a9ade4cd5d6
|
File details
Details for the file vulgaris-0.1.1-py3-none-any.whl.
File metadata
- Download URL: vulgaris-0.1.1-py3-none-any.whl
- Upload date:
- Size: 114.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.14.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
bef90d5420ecdfebc4177b3ccf6b5e2d285bbb64e2f2099df9fd17721d38499e
|
|
| MD5 |
f9473fe88ff585fb4fd16028bd13d9c4
|
|
| BLAKE2b-256 |
0c7030af6e4585b35d6fde6ac93e23861ff50782ab9010fdbbba475a8c7d2722
|