Skip to main content

East Data Science - ML/optimization platform functions for East Python runtime

Project description

East Data Science

Data science and ML platform functions for the East language

TypeScript: AGPL-3.0 Python: BSL 1.1 Node Version

East Data Science provides machine learning and optimization platform functions for the East language.

Installation

npm install @elaraai/east-py-datascience @elaraai/east

Python Optional Dependencies

Each module has its own optional Python dependencies to avoid installing unnecessary packages. Install only the extras you need:

# Single extra
pip install "east-py-datascience[scipy]"

# Multiple extras
pip install "east-py-datascience[scipy,sklearn,xgboost]"

# All extras
pip install "east-py-datascience[all]"

When using a git dependency in pyproject.toml:

"east-py-datascience[scipy] @ git+https://github.com/elaraai/east-workspace@main#subdirectory=libs/east-py/packages/east-py-datascience"
Module Extra Python Packages
MADS mads PyNomadBBO
Optuna optuna optuna
SimAnneal simanneal simanneal
Scipy scipy scipy, cloudpickle
Optimization (none) (core only — numpy)
GoogleOr google-or ortools
Sklearn sklearn scikit-learn, skl2onnx, onnxruntime, cloudpickle
XGBoost xgboost xgboost, cloudpickle
LightGBM lightgbm lightgbm, cloudpickle
NGBoost ngboost ngboost, cloudpickle
Torch torch torch, cloudpickle
GP gp scikit-learn, cloudpickle
Lightning lightning torch, pytorch-lightning, cloudpickle
Shap shap shap, cloudpickle
MAPIE mapie mapie, cloudpickle
ALNS alns alns
PyMC pymc pymc, cloudpickle
Simulation (none) (core only — numpy)
Causal causal dowhy, econml, PyALE, pandas, matplotlib, scikit-learn, cloudpickle

Quick Start

import { East, FloatType, variant } from "@elaraai/east";
import { MADS } from "@elaraai/east-py-datascience";

// Define objective function: minimize sum of squares
const objective = East.function([MADS.Types.VectorType], FloatType, ($, x) => {
    const x0 = $.let(x.get(0n));
    const x1 = $.let(x.get(1n));
    return $.return(x0.multiply(x0).add(x1.multiply(x1)));
});

// Optimize
const optimize = East.function([], MADS.Types.ResultType, $ => {
    const x0 = $.let([0.5, 0.5]);
    const bounds = $.let({
        lower: [-1.0, -1.0],
        upper: [1.0, 1.0],
    });
    const config = $.let({
        max_bb_eval: variant('some', 100n),
        display_degree: variant('some', 0n),
        direction_type: variant('none', null),
        initial_mesh_size: variant('none', null),
        min_mesh_size: variant('none', null),
        seed: variant('some', 42n),
    });

    return $.return(MADS.optimize(objective, x0, bounds, variant('none', null), config));
});

Modules

Optimization

Module Description Use Cases
MADS Derivative-free blackbox optimization using NOMAD algorithm Functions without derivatives, expensive evaluations, noisy/discontinuous objectives
Optuna Bayesian optimization with TPE sampler Hyperparameter tuning, mixed-type parameters, efficient search with few evaluations
SimAnneal Simulated annealing for discrete optimization TSP, scheduling, subset selection, knapsack, assignment problems
Scipy Scientific optimization and curve fitting Gradient-based minimization, curve fitting, interpolation, statistics
Optimization Iterative coordinate descent optimization Parameter tuning, sequential optimization across parameter groups
GoogleOr Google OR-Tools constraint programming, routing, LP, and graph algorithms CP-SAT, vehicle routing (TSP/VRP), linear/mixed-integer programming, min-cost flow, max flow, assignment

Machine Learning

Module Description Use Cases
Sklearn Core ML utilities from scikit-learn N-way splits, preprocessing (Standard/MinMax/RobustScaler), encoding (Label/Ordinal), metrics, GMM clustering, multi-target regression
XGBoost Gradient boosting with XGBoost Regression, classification, feature importance, fast training
LightGBM Fast gradient boosting with leaf-wise growth Large datasets, high cardinality features, faster than XGBoost on big data
NGBoost Natural gradient boosting with uncertainty Probabilistic predictions, confidence intervals, uncertainty quantification
Torch Neural networks with PyTorch MLP regression/classification, deep learning, custom architectures
Lightning PyTorch Lightning neural networks MLP, autoencoder, conv1d, sequential, transformer architectures
GP Gaussian Process regression Small datasets, uncertainty quantification, Bayesian optimization surrogate
MAPIE Conformal prediction intervals Prediction intervals, prediction sets, uncertainty quantification

Bayesian Inference

Module Description Use Cases
PyMC Bayesian inference with PyMC Bayesian linear regression, hierarchical models, multi-layer joint estimation, posterior analysis

Causal Inference

Module Description Use Cases
Causal One declarative causal experiment (Causal.experiment) over DoWhy / EconML / PyALE internals, plus Causal.designValidation (statsmodels power) Naive vs adjusted effect, confounder balance, propensity overlap, placebo/E-value robustness, and an honesty verdict (refuses when the data can't support an answer); and the real controlled-trial recipe that would confirm it — sample size, split, match-on categories, and a power curve

Simulation

Module Description Use Cases
Simulation Economic ontology simulation via DES Simulating economic resources, events, and processes; single deterministic runs, Monte Carlo trajectories

Explainability

Module Description Use Cases
Shap SHAP values for model interpretation Feature importance, model explanations, debugging predictions

Documentation

See USAGE.md for detailed API reference with examples.

Development

npm run build     # Compile TypeScript
npm run test      # Run test suite
npm run lint      # Check code quality

Claude Code plugin

The East ecosystem also ships a Claude Code plugin — East language skills, example search, and preemptive diagnostics for East code — installed separately from the elaraai marketplace:

# Inside Claude Code
/plugin marketplace add elaraai/east-workspace
/plugin install east@elaraai
# From a terminal
claude plugin marketplace add elaraai/east-workspace
claude plugin install east@elaraai

License

This package has different licenses for TypeScript and Python code:

TypeScript (type definitions): Dual AGPL-3.0 / Commercial

Python (runtime implementations): BSL 1.1 (Business Source License)

  • Non-production use (evaluation, testing, development) is free
  • Production use by or on behalf of for-profit entities requires a commercial license
  • Code becomes AGPL-3.0 four years after each release

See LICENSE.md for full details.

Commercial licensing: support@elara.ai

Ecosystem

  • East: Statically typed, expression-based language with serializable IR. Run portable logic across TypeScript, Python, C, and other runtimes.

    • @elaraai/east: Core language SDK with type system, expressions, and reference JS compiler
  • East Node: Node.js platform functions for I/O, databases, and system operations.

  • East C: C11 native runtime for executing East IR. Distributed via npm (launcher + per-platform optional dependencies) and as tarballs on each GitHub Release.

    • @elaraai/east-c-cli: npm launcher — installs the matching native binary as an optional dependency
    • east-c: Core runtime — type system, IR interpreter, builtins, serialization (Beast2, JSON, CSV, East text)
    • east-c-std: Console, FileSystem, Fetch, Crypto, Time, Path, Random
    • east-c-cli: CLI for running East IR programs natively
  • East Python: Python runtime, standard platform, I/O, and data-science platform functions. Published to PyPI.

    • east-py: Core Python runtime — type system, IR compiler, 212+ builtins, Cython-accelerated hot paths
    • east-py-std: Console, FileSystem, Fetch, Crypto, Time, Path, Random
    • east-py-io: SQLite, PostgreSQL, MySQL, MongoDB, Redis, S3, FTP, SFTP, XLSX, XML, compression
    • east-py-cli: CLI for running East IR programs in Python
    • east-py-datascience (PyPI) + @elaraai/east-py-datascience (npm): Optimization (MADS, Optuna, ALNS, GoogleOR), ML (XGBoost, LightGBM, NGBoost, PyTorch, Lightning, GP), Bayesian inference (PyMC), explainability (SHAP), conformal prediction (MAPIE)
  • East UI: Typed UI component definitions and React renderer, plus VS Code preview.

  • e3 — East Execution Engine: Durable execution engine for running East pipelines at scale. Git-like content-addressable storage, automatic memoization, reactive dataflow, real-time monitoring.

Links

About Elara

East is developed by Elara AI Pty Ltd, an AI-powered platform that creates economic digital twins of businesses that optimize performance. Elara combines business objectives, decisions and data to help organizations make data-driven decisions across operations, purchasing, sales and customer engagement, and project and investment planning. East powers the computational layer of Elara solutions, enabling the expression of complex business logic and data in a simple, type-safe and portable language.


Developed by Elara AI Pty Ltd.


Developed by Elara AI Pty Ltd

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

elaraai_east_py_datascience-1.0.20.tar.gz (558.6 kB view details)

Uploaded Source

Built Distributions

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

elaraai_east_py_datascience-1.0.20-cp313-cp313-win_amd64.whl (239.0 kB view details)

Uploaded CPython 3.13Windows x86-64

elaraai_east_py_datascience-1.0.20-cp313-cp313-win32.whl (236.7 kB view details)

Uploaded CPython 3.13Windows x86

elaraai_east_py_datascience-1.0.20-cp313-cp313-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl (236.8 kB view details)

Uploaded CPython 3.13manylinux: glibc 2.17+ x86-64manylinux: glibc 2.28+ x86-64

elaraai_east_py_datascience-1.0.20-cp313-cp313-macosx_11_0_arm64.whl (234.9 kB view details)

Uploaded CPython 3.13macOS 11.0+ ARM64

elaraai_east_py_datascience-1.0.20-cp313-cp313-macosx_10_13_x86_64.whl (235.6 kB view details)

Uploaded CPython 3.13macOS 10.13+ x86-64

elaraai_east_py_datascience-1.0.20-cp312-cp312-win_amd64.whl (239.1 kB view details)

Uploaded CPython 3.12Windows x86-64

elaraai_east_py_datascience-1.0.20-cp312-cp312-win32.whl (236.7 kB view details)

Uploaded CPython 3.12Windows x86

elaraai_east_py_datascience-1.0.20-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl (236.9 kB view details)

Uploaded CPython 3.12manylinux: glibc 2.17+ x86-64manylinux: glibc 2.28+ x86-64

elaraai_east_py_datascience-1.0.20-cp312-cp312-macosx_11_0_arm64.whl (234.9 kB view details)

Uploaded CPython 3.12macOS 11.0+ ARM64

elaraai_east_py_datascience-1.0.20-cp312-cp312-macosx_10_13_x86_64.whl (235.7 kB view details)

Uploaded CPython 3.12macOS 10.13+ x86-64

elaraai_east_py_datascience-1.0.20-cp311-cp311-win_amd64.whl (238.7 kB view details)

Uploaded CPython 3.11Windows x86-64

elaraai_east_py_datascience-1.0.20-cp311-cp311-win32.whl (236.3 kB view details)

Uploaded CPython 3.11Windows x86

elaraai_east_py_datascience-1.0.20-cp311-cp311-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl (236.7 kB view details)

Uploaded CPython 3.11manylinux: glibc 2.17+ x86-64manylinux: glibc 2.28+ x86-64

elaraai_east_py_datascience-1.0.20-cp311-cp311-macosx_11_0_arm64.whl (234.7 kB view details)

Uploaded CPython 3.11macOS 11.0+ ARM64

elaraai_east_py_datascience-1.0.20-cp311-cp311-macosx_10_9_x86_64.whl (235.5 kB view details)

Uploaded CPython 3.11macOS 10.9+ x86-64

File details

Details for the file elaraai_east_py_datascience-1.0.20.tar.gz.

File metadata

File hashes

Hashes for elaraai_east_py_datascience-1.0.20.tar.gz
Algorithm Hash digest
SHA256 c4622db6f068aa69a8a17119633d0b642032d851d6231800f4c28c8c2ee4bb34
MD5 320338e43ec9f2409cfaa179219ce275
BLAKE2b-256 aaf5170de3b7048adc9ee5ce90edea600703d1291b73ee6d52d187c5f0d9c818

See more details on using hashes here.

File details

Details for the file elaraai_east_py_datascience-1.0.20-cp313-cp313-win_amd64.whl.

File metadata

File hashes

Hashes for elaraai_east_py_datascience-1.0.20-cp313-cp313-win_amd64.whl
Algorithm Hash digest
SHA256 0074052f04d4d9b829f6c53ca6086326000bfa407a24d6afff05da152d488e57
MD5 566eba18b58714d64e978f0eabfdd03e
BLAKE2b-256 7fa7244cf47a7e5796a052685d3f9f9c5376ea4f225ae204d25c122605c9d9fd

See more details on using hashes here.

File details

Details for the file elaraai_east_py_datascience-1.0.20-cp313-cp313-win32.whl.

File metadata

File hashes

Hashes for elaraai_east_py_datascience-1.0.20-cp313-cp313-win32.whl
Algorithm Hash digest
SHA256 ca029f4f8038c6179019020c4a2b21190289cd8383be73ee99951ec249a32de8
MD5 f3c89a087da7d49c538d1f902fab2247
BLAKE2b-256 8923469f80b74f6456cf80a4c78063ae79b039044b5c11862184b91976e37f8a

See more details on using hashes here.

File details

Details for the file elaraai_east_py_datascience-1.0.20-cp313-cp313-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for elaraai_east_py_datascience-1.0.20-cp313-cp313-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 520ecc433d80ddaa765ec87d8562a7b2767dc03d4327ce1d23137924fb171a8e
MD5 1168974f86b2b81104281c0a54b33d3e
BLAKE2b-256 57cec22fa2405bfa00b7348332a5d510dce17247a01d77cc16cfae3aa23e5729

See more details on using hashes here.

File details

Details for the file elaraai_east_py_datascience-1.0.20-cp313-cp313-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for elaraai_east_py_datascience-1.0.20-cp313-cp313-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 60ec406e795851ddb15d56255a8d0ae428ca945101fb7a54b7fd642043120b56
MD5 f8c663778846863a17db96a600dc8ebb
BLAKE2b-256 ed299414b1f3a861c0156cd85fa495b980b180bc0a41425f5255303b98f6aebf

See more details on using hashes here.

File details

Details for the file elaraai_east_py_datascience-1.0.20-cp313-cp313-macosx_10_13_x86_64.whl.

File metadata

File hashes

Hashes for elaraai_east_py_datascience-1.0.20-cp313-cp313-macosx_10_13_x86_64.whl
Algorithm Hash digest
SHA256 b071ee2f325aaec87e76e19b7da2d13d7609b72279319fd6e78be2e367410851
MD5 d7a61b6f366cd11b83484aecafda2a33
BLAKE2b-256 d9ef94eff4d179d0aae94afd2cd9ce708970a602eb2090835529907697e07cff

See more details on using hashes here.

File details

Details for the file elaraai_east_py_datascience-1.0.20-cp312-cp312-win_amd64.whl.

File metadata

File hashes

Hashes for elaraai_east_py_datascience-1.0.20-cp312-cp312-win_amd64.whl
Algorithm Hash digest
SHA256 027bad89dbd662bd8982e6108b8c3c2c2cbd841b318d1a1ea66a0466cdc7e57d
MD5 b30f65ed4f17fa43c3f9c049b56439cb
BLAKE2b-256 dcfb8eb05c9b40aa83c0eca10c8b0ea55af01b38c532384a00f19458d57d6ffd

See more details on using hashes here.

File details

Details for the file elaraai_east_py_datascience-1.0.20-cp312-cp312-win32.whl.

File metadata

File hashes

Hashes for elaraai_east_py_datascience-1.0.20-cp312-cp312-win32.whl
Algorithm Hash digest
SHA256 810c44de0d5756317e0ba8845bebed0e4458fe57833ed32747056056293863a5
MD5 f0779c5f43bac10ac344c2269bda0ad6
BLAKE2b-256 a1ad0307267f4720c4479461b6cc4d0df60913d232b6a6062d400f7e08250293

See more details on using hashes here.

File details

Details for the file elaraai_east_py_datascience-1.0.20-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for elaraai_east_py_datascience-1.0.20-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 329429feb664312e15e5e8591e9c63cb713c69048fcf3930881e326d6f8dbb2b
MD5 7a6f857ea568e0927bb121893c2db69e
BLAKE2b-256 a137dc9c50ebf017afdb71e27c58a085b15cf49c53da3ec6db14b70f48e09d9d

See more details on using hashes here.

File details

Details for the file elaraai_east_py_datascience-1.0.20-cp312-cp312-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for elaraai_east_py_datascience-1.0.20-cp312-cp312-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 3b03b66516b1efa09cc0760245d0d3c67bff1ac06cc16beba0549552470962e3
MD5 abb889522be7c5c20a74a5bfd74f7726
BLAKE2b-256 217d62529e0ab6af4c94a7b0a89e020cfe3102473d342e4c1f4b08819feaa984

See more details on using hashes here.

File details

Details for the file elaraai_east_py_datascience-1.0.20-cp312-cp312-macosx_10_13_x86_64.whl.

File metadata

File hashes

Hashes for elaraai_east_py_datascience-1.0.20-cp312-cp312-macosx_10_13_x86_64.whl
Algorithm Hash digest
SHA256 55c90c43abaa7207d4057442c54d78cc25b75351e7515c9d1857f2f62c43fe5e
MD5 81d7f22d1cd0dd9cc7264cd7992ddc01
BLAKE2b-256 497666ee66c99cd7b57b29419db0948c6fa30b754481d588ab2ed0b86e4c211a

See more details on using hashes here.

File details

Details for the file elaraai_east_py_datascience-1.0.20-cp311-cp311-win_amd64.whl.

File metadata

File hashes

Hashes for elaraai_east_py_datascience-1.0.20-cp311-cp311-win_amd64.whl
Algorithm Hash digest
SHA256 a84594362e4b78fc7d7adc20fce4e6ea3a643bf597432387edd2774b1fc697b5
MD5 9aa93fe4afaab480196d4eadfe3c55c0
BLAKE2b-256 41e330df119fd31f4b3e0fb13110ea2f52d7edd831333db1b6145536387a5166

See more details on using hashes here.

File details

Details for the file elaraai_east_py_datascience-1.0.20-cp311-cp311-win32.whl.

File metadata

File hashes

Hashes for elaraai_east_py_datascience-1.0.20-cp311-cp311-win32.whl
Algorithm Hash digest
SHA256 8c4742ecbc02eddf68375f72bc20e8caa2ed900c53427319ab0fb02a297da9d4
MD5 ab93c7c5299bb1ada91e4d9b0292ebcc
BLAKE2b-256 e5c2c92532f40c9e08c01f5a74baa94efa768ee19f30dd6713f88f4d716da8d1

See more details on using hashes here.

File details

Details for the file elaraai_east_py_datascience-1.0.20-cp311-cp311-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for elaraai_east_py_datascience-1.0.20-cp311-cp311-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 d4fae1504d6e5c5c251500d2ab4923b6bc167650f7d2be1fc6489dd608366c18
MD5 3ff175abb519c591ee905fe43493241d
BLAKE2b-256 0d5284ba154365751e8bbe67d2725d5b1bf6510b51a2dc1bf891b6fbdb615b32

See more details on using hashes here.

File details

Details for the file elaraai_east_py_datascience-1.0.20-cp311-cp311-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for elaraai_east_py_datascience-1.0.20-cp311-cp311-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 ee415d39e60bbe5e80d313443091496e02d5304120969598349d42733d67768f
MD5 e622a2d72545b04c68a0bf43345fba99
BLAKE2b-256 d93c01868ed919ea13213a65cbcaed5cc165507743c2222dae8851cad9980dd0

See more details on using hashes here.

File details

Details for the file elaraai_east_py_datascience-1.0.20-cp311-cp311-macosx_10_9_x86_64.whl.

File metadata

File hashes

Hashes for elaraai_east_py_datascience-1.0.20-cp311-cp311-macosx_10_9_x86_64.whl
Algorithm Hash digest
SHA256 2bebb02355c739fc0c5d190d22f01187fbf400c9896d3839f56b38daa17623ee
MD5 6ad0bac0b449f28ce174fbd93f7c5c84
BLAKE2b-256 c99a5a47f7474662a0928848137bb0468562243dcc04c47d0a2dc8aaa3398723

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