Skip to main content
Pre-release

This release is a pre-release and may not be stable for production use.

AI2Apps

The Edge Supermodel Ecosystem — local-first Fusion and Cache-MoE inference for Apple Silicon.

AI2Apps is an independent inference product built on the open-source oMLX runtime. It adds scope selection, cache-aware routed experts, SSD expert storage, optional lossy acceleration, session-safe KV reuse, and AI2Apps-specific observability for very large MoE models such as DeepSeek V4 Flesh.

AI2Apps is not affiliated with, sponsored by, or endorsed by the oMLX project or its maintainers. The oMLX name is used only to identify the origin of the runtime. See NOTICE for attribution.

中文说明 · Architecture · Flesh engine · Benchmark records · Release gate

What AI2Apps adds

  • Configurable flat or hierarchical scope catalogs.
  • Shared-expert scope probing, 16 layers by default and configurable to 43.
  • Per-scope static expert banks with device-side Top-K routing.
  • Exact, conservative, tail1, tail2, and aggressive head2 policies.
  • Expert-major SSD storage and cache-aware fallback loading.
  • Multi-turn sessions and scope-namespaced KV-cache reuse.
  • OpenAI-compatible endpoints, CLI, chat UI, and live scope/cache status.
  • Reproducible prefill/decode, miss handling, I/O, and scope benchmarks.

The inherited oMLX runtime continues to provide model loading, attention, fused MoE kernels, continuous batching, paged KV caching, audio/VLM engines, MCP integration, and the original administration capabilities.

Repository layout

ai2apps/                 AI2Apps product package and public CLI
omlx/                    Embedded, modified oMLX runtime
  engine/flesh.py        DeepSeek V4 Flesh request orchestration
  cache/                 KV and MoE expert storage
  patches/deepseek_v4/   Scope router, banks, policies and kernels
  admin/                 AI2Apps WebUI served by the runtime
configs/                 Scope catalogs and profiles
scripts/                 Conversion, profiling and benchmark tools
docs/                    Architecture and experiment records
artifacts/               Local experiment output

The omlx Python namespace and OMLX_* environment variables are retained as runtime compatibility interfaces. New consumers should use the ai2apps command and import product engines from ai2apps.runtime.

Install

Requirements: Apple Silicon Mac, Python 3.11–3.13, and macOS with Metal support.

brew install uv
uv sync --dev
source .venv/bin/activate

Alternatively, create a Python 3.11–3.13 virtual environment and install the project with python -m pip install -e '.[dev]'.

Verify the product and embedded runtime:

ai2apps --version
ai2apps info

Runtime data currently remains under ~/.omlx so existing models, settings, and KV cache data are not orphaned during migration.

Start the server

ai2apps serve --model-dir ~/models --port 8000

Example:

curl http://127.0.0.1:8000/v1/chat/completions \
  -H 'Content-Type: application/json' \
  -d '{"model":"source","messages":[{"role":"user","content":"Hello"}]}'

The legacy omlx executable remains available as a temporary compatibility alias, but documentation and integrations should use ai2apps.

DeepSeek V4 Flesh

Models installed from the AI2Apps Download source use the verified Scope Pack shipped in the release automatically.

The standalone hf CLI is not required. Release installs include huggingface-hub>=1.19.0; the AI2Apps Download page checks the installed version, shared-cache writability, downloader initialization and non-secret authentication state before enabling Download & Prepare. Public catalog models work anonymously. A completely missing dependency is reported by the ai2apps CLI with the exact pip install repair command before startup exits.

Manual research checkouts can still override the profile and expert store before starting:

export AI2APPS_DEEPSEEK_V4_EXPERT_STORE=/path/to/expert-store
export AI2APPS_DEEPSEEK_V4_SCOPE_PROFILE=/path/to/scope-profile.json
export AI2APPS_DEEPSEEK_V4_SCOPE_NAME=general
export AI2APPS_DEEPSEEK_V4_SCOPE_PROBE_DEPTH=16
export AI2APPS_DEEPSEEK_V4_SCOPE_LOSSY_MODE=exact

ai2apps serve --model-dir /path/to/models

The ai2apps entry point translates AI2APPS_* variables to the retained OMLX_* runtime interface; legacy deployment files therefore continue to work. The profile override is not required for models prepared by AI2Apps. Lossy mode is opt-in. Use exact for quality-sensitive serving; benchmark conservative, tail1, tail2, or head2 against representative prompts before deployment. The dashboard reports the active scope, probe depth, lossy mode, scope switches, and fallback count without introducing a GPU sync.

Development and performance gate

The experimental branch is experiment/moe-cache. Preserve oMLX model, attention, router, and fused MoE behavior unless a AI2Apps feature explicitly requires a small isolated patch. Benchmark changes with identical prompts and generated tokens and record memory, cold TPS, and steady TPS.

pytest -q
python scripts/bench_scope_once.py --help
python scripts/bench_moe_expert_store.py --help
ai2apps-release-gate --mode preflight --run-tests

Before dynamic replacement is considered production-ready, the static oracle bank must retain exact Top-10 parity, have zero runtime misses, reduce resident memory, and preserve at least 85% of full-resident steady-state TPS.

Origin, license, and trademarks

AI2Apps is based on oMLX commit 49ec271 and retains upstream copyright and attribution notices. Modified files and the repository history identify the AI2Apps changes.

This project is licensed under the Apache License 2.0. Copyright 2025 oMLX contributors; Copyright 2026 AI2Apps contributors. Apache-2.0 does not grant broad rights to upstream trade names or marks. AI2Apps does not use the oMLX name or logo as its product identity and makes no claim of upstream affiliation, sponsorship, certification, or endorsement.

Metadata

Release files for ai2apps 0.1.0.dev3

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for ai2apps 0.1.0.dev3
File Size Uploaded
ai2apps-0.1.0.dev3.tar.gz 48.0 MB Details

Built distributions (wheels)

Table of built distributions (wheels) for ai2apps 0.1.0.dev3
File Interpreter ABI Platform
ai2apps-0.1.0.dev3-cp313-cp313-macosx_15_0_universal2.whl CPython 3.13 CPython 3.13 macOS 15.0+ universal2 (ARM64, x86-64) Details
ai2apps-0.1.0.dev3-cp312-cp312-macosx_15_0_universal2.whl CPython 3.12 CPython 3.12 macOS 15.0+ universal2 (ARM64, x86-64) Details
ai2apps-0.1.0.dev3-cp311-cp311-macosx_15_0_universal2.whl CPython 3.11 CPython 3.11 macOS 15.0+ universal2 (ARM64, x86-64) Details

Total release size: 196.6 MB

Release files / ai2apps-0.1.0.dev3.tar.gz

Download URL ai2apps-0.1.0.dev3.tar.gz
Size 48.0 MB
Tags Source
SHA-256 checksum
How to use checksums
2f0ce90d9be9bcca30e33d14be4407bd054e1009b22742d9397fba25dac7c4ca
BLAKE2b-256 checksum
How to use checksums
ae2ac29b8bf2b495bc549c0460645c13270e99bc71ec7519b82d9cf246e0ebf5
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Aug 15, 2026.

Transparency log

Release files / ai2apps-0.1.0.dev3-cp313-cp313-macosx_15_0_universal2.whl

Download URL ai2apps-0.1.0.dev3-cp313-cp313-macosx_15_0_universal2.whl
Size 49.5 MB
Tags CPython 3.13 macOS 15.0+ universal2 (ARM64, x86-64)
SHA-256 checksum
How to use checksums
d0c657356156a6a03d3877f4b0b874000569def2b465ba69770c5ff805619f70
BLAKE2b-256 checksum
How to use checksums
256a62debd6b04e201973228f82edb190126b68a8645e93ea79a3d3fd43b5aa6
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Aug 15, 2026.

Transparency log

Release files / ai2apps-0.1.0.dev3-cp312-cp312-macosx_15_0_universal2.whl

Download URL ai2apps-0.1.0.dev3-cp312-cp312-macosx_15_0_universal2.whl
Size 49.5 MB
Tags CPython 3.12 macOS 15.0+ universal2 (ARM64, x86-64)
SHA-256 checksum
How to use checksums
3031d25d55ac2d15ed96aca63fe0b1cd8df05920d58f36689fc0f7826ed1d254
BLAKE2b-256 checksum
How to use checksums
56722478cac541a1e53656e3a583ebb9a7035cea4bdcee950c3cbd036f9e0b29
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Aug 15, 2026.

Transparency log

Release files / ai2apps-0.1.0.dev3-cp311-cp311-macosx_15_0_universal2.whl

Download URL ai2apps-0.1.0.dev3-cp311-cp311-macosx_15_0_universal2.whl
Size 49.5 MB
Tags CPython 3.11 macOS 15.0+ universal2 (ARM64, x86-64)
SHA-256 checksum
How to use checksums
8dc9f19d02e8c581bf2f17d94546107a3e3a4f3395277f56431df4d706d4c72a
BLAKE2b-256 checksum
How to use checksums
8425cfb9d6292ed6e523bdc45bdadff6a8f51d5bf362a0a35d6c2d9f0f0c936a
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Aug 15, 2026.

Transparency log
Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page