Skip to main content

OIKAN: Optimized Interpretable Kolmogorov-Arnold Networks

Project description

OIKAN Logo

OIKAN: Optimized Interpretable Kolmogorov-Arnold Networks

Overview

OIKAN (Optimized Interpretable Kolmogorov-Arnold Networks) is a neuro-symbolic ML framework that combines modern neural networks with classical Kolmogorov-Arnold representation theory. It provides interpretable machine learning solutions through automatic extraction of symbolic mathematical formulas from trained models.

PyPI version PyPI Downloads per month PyPI Total Downloads License GitHub issues Docs

Key Features

  • 🧠 Neuro-Symbolic ML: Combines neural network learning with symbolic mathematics
  • 📊 Automatic Formula Extraction: Generates human-readable mathematical expressions
  • 🎯 Scikit-learn Compatible: Familiar .fit() and .predict() interface
  • 🚀 Production-Ready: Export symbolic formulas for lightweight deployment
  • 📈 Multi-Task: Supports both regression and classification problems

Scientific Foundation

OIKAN is based on Kolmogorov's superposition theorem, which states that any multivariate continuous function can be represented as a composition of single-variable functions. We leverage this theory by:

  1. Using neural networks to learn optimal basis functions
  2. Employing SVD projection for dimensionality reduction
  3. Applying symbolic regression to extract interpretable formulas

Quick Start

Installation

Method 1: Via PyPI (Recommended)

pip install -qU oikan

Method 2: Local Development

git clone https://github.com/silvermete0r/OIKAN.git
cd OIKAN
pip install -e .  # Install in development mode

Regression Example

from oikan.model import OIKANRegressor
from sklearn.model_selection import train_test_split

# Initialize model with optimal architecture
model = OIKANRegressor(
    hidden_dims=[16, 8],  # Network architecture
    num_basis=10,         # Number of basis functions
    degree=3,             # Polynomial degree
    dropout=0.1           # Regularization
)

# Fit model (sklearn-style)
model.fit(X_train, y_train, epochs=200, lr=0.01)

# Get predictions
y_pred = model.predict(X_test)

# Save interpretable formula to file with auto-generated guidelines
# The output file will contain:
# - Detailed symbolic formulas for each feature
# - Instructions for practical implementation
# - Recommendations for production deployment
model.save_symbolic_formula("regression_formula.txt")

Example of the saved symbolic formula instructions: outputs/regression_symbolic_formula.txt

Classification Example

from oikan.model import OIKANClassifier

# Similar sklearn-style interface for classification
model = OIKANClassifier(hidden_dims=[16, 8])
model.fit(X_train, y_train)
probas = model.predict_proba(X_test)

# Save classification formulas with implementation guidelines
# The output file will contain:
# - Decision boundary formulas for each class
# - Softmax application instructions
# - Production deployment recommendations
model.save_symbolic_formula("classification_formula.txt")

Example of the saved symbolic formula instructions: outputs/classification_symbolic_formula.txt

Architecture Details

OIKAN's architecture consists of three main components:

  1. Basis Function Layer: Learns optimal single-variable transformations

    • B-spline bases for smooth function approximation
    • Trigonometric bases for periodic patterns
    • Polynomial bases for algebraic relationships
  2. Neural Composition Layer: Combines transformed features

    • SVD projection for dimensionality reduction
    • Dropout for regularization
    • Skip connections for gradient flow
  3. Symbolic Extraction Layer: Generates interpretable formulas

    • L1 regularization for sparse representations
    • Symbolic regression for formula extraction
    • LaTeX export for documentation

Contributing

We welcome contributions! Key areas of interest:

  • Model architecture improvements
  • Novel basis function implementations
  • Improved symbolic extraction algorithms
  • Real-world case studies and applications
  • Performance optimizations

Please see CONTRIBUTING.md for guidelines.

Citation

If you use OIKAN in your research, please cite:

@software{oikan2025,
  title = {OIKAN: Optimized Interpretable Kolmogorov-Arnold Networks},
  author = {Zhalgasbayev, Arman},
  year = {2025},
  url = {https://github.com/silvermete0r/OIKAN}
}

License

This project is licensed under the MIT License - see the LICENSE file for details.

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

oikan-0.0.2.1.tar.gz (12.2 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

oikan-0.0.2.1-py3-none-any.whl (11.1 kB view details)

Uploaded Python 3

File details

Details for the file oikan-0.0.2.1.tar.gz.

File metadata

  • Download URL: oikan-0.0.2.1.tar.gz
  • Upload date:
  • Size: 12.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.10.13

File hashes

Hashes for oikan-0.0.2.1.tar.gz
Algorithm Hash digest
SHA256 db2835360ecf9a0f0593a697e0982206b870ba1059888a1855fc984ed168f5c0
MD5 e683344c1e6dd17a5f269595db55549d
BLAKE2b-256 80053f9d3fbd2e9ed1ec584d97c769456675c013105bcfcf89dc6a928d88fea4

See more details on using hashes here.

File details

Details for the file oikan-0.0.2.1-py3-none-any.whl.

File metadata

  • Download URL: oikan-0.0.2.1-py3-none-any.whl
  • Upload date:
  • Size: 11.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.10.13

File hashes

Hashes for oikan-0.0.2.1-py3-none-any.whl
Algorithm Hash digest
SHA256 a02c9debdf087ec43147adbcdf40419e2025288451161918ccce2ab72ce03da0
MD5 dc3a1b5a8b6209bdceb10dc2ad32c64c
BLAKE2b-256 f00a3c966b34948f23b79b5253bbd4ae8b23a0ffd29ed13023f4dd80050f90b3

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page