An ahead-of-time nn compiler for Ambiq SoCs.
Project description
heliaAOT
Bring blazing-fast, ultra-compact neural inference to Ambiq’s ultra-low-power SoCs—without a runtime.
heliaAOT is an ahead-of-time (AOT) compiler that converts front-end models (e.g., TFLite) into stand-alone C inference modules optimized for Ambiq microcontrollers. By shifting codegen to build-time and eliminating the runtime interpreter, heliaAOT delivers compact, readable C with zero arena-guesswork and no dead code.
✨ Why heliaAOT?
- Smaller binaries – Generate only the code you need. No interpreter, no dead kernels.
- Deterministic memory – Context-level memory planning; stop guessing arena sizes.
- Readable output – Layer-mirrored C files for fast bring-up and debugging.
- Ambiq-tuned – Optimized for Cortex-M (M4/M55/Helium) on Ambiq SoCs.
- Production-ready – Drop into Zephyr/neuralSPOT or your existing build system.
🚀 Quick Start
Option A: Install via pipx
pipx install --python python3.12 helia-aot
helia-aot --help
We recommend pipx because it installs Python apps in isolated, self-contained environments and puts the CLI on your PATH.
Option B: Install via uv
uv tool install --python python3.12 helia-aot
helia-aot --help
Option C: Install via pip
python -m venv .venv
source .venv/bin/activate # Windows: .venv\Scripts\activate
python -m pip install helia-aot
helia-aot --help
Option D: Install from source
git clone https://github.com/AmbiqAI/helia-aot.git
cd helia-aot
uv sync
uv run helia-aot --help
🧭 First Conversion
helia-aot convert \
--model.path ./models/ad01_int8.tflite \
--module.path ./out \
--module.name ad01_aot
What you get:
out/ad01_aot/
├── LICENSE # License for the generated module
├── README.md # Module usage notes
├── includes-api/ # Public C headers
├── src/ # Operator implementations
└── module.mk
Drop the folder into your firmware tree and build like any other C module.
🛠️ Current CLI
heliaAOT currently exposes a single primary command:
-
convert – Convert a TFLite model into a C inference module.
helia-aot convert --help
We follow “progressive disclosure of complexity.” The CLI starts simple; advanced flags and expert workflows are documented in the site’s How-to and Reference sections.
📚 Documentation
- Getting Started: the fastest way from model → C module
- How-To: step-by-step recipes for common tasks
- Reference: full list of commands/flags
- Guides: end-to-end projects and best practices
- Benchmarks: performance and size comparisons
- API: for power users who integrate deeper
The docs are written for CLI users first; you don’t need to know (or care) that the tool is implemented in Python.
🔌 Supported Inputs & Targets
Inputs
- LiteRT/TFLite (int8/int16)
Targets
- Ambiq SoCs (Cortex-M4, M55/Helium)
- Integration paths: Zephyr module, neuralSPOT, or make/CMake projects
🧩 What the Generated C Looks Like
- A compact operator library: only kernels required by your model.
- A structured init() / run() style API with clear I/O.
- Compile-time tensor shapes and a fixed memory plan.
- Optional operator callbacks for instrumentation/telemetry.
🧪 Testing & Quality
- Continuous Integration runs linting and unit tests
- Deterministic builds and reproducible outputs where possible
- Example apps and benchmarks in the docs
⚙️ Development (optional)
If you do want to contribute or run from source:
# Using uv (fast Python package manager)
uv sync
uv run helia-aot --help
# Or with pip + virtualenv
python -m venv .venv && source .venv/bin/activate
pip install -e ".[dev]"
helia-aot --help
🗺️ Roadmap
The project roadmap and features can be found on the GitHub Projects page.
We prioritize features that keep binaries tiny, predictable, and fast.
💬 Support & Feedback
- Issues / bugs: Create an issue on GitHub
- Feature requests and discussions: Join the conversation
📄 License
heliaAOT generates C modules that include a license header restricting use to Ambiq hardware. See the generated module’s LICENSE.txt for terms and the repository’s LICENSE for tooling.
Ready to dive in? Head over to the Getting Started guide and generate your first module in minutes.
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 helia_aot-0.17.1.tar.gz.
File metadata
- Download URL: helia_aot-0.17.1.tar.gz
- Upload date:
- Size: 254.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.13
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
37cb67a6af580b3a4f568a6bb2e5feaa9b8fd09bef57f44384505cb37fda9f44
|
|
| MD5 |
75fc4b0c92479ac0e3c12b4c412fb954
|
|
| BLAKE2b-256 |
1d6a105b73379c3d00ba0387cd54fb059f60d8b16a18b9bbbfb535afca203377
|
Provenance
The following attestation bundles were made for helia_aot-0.17.1.tar.gz:
Publisher:
release.yml on AmbiqAI/helia-aot
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
helia_aot-0.17.1.tar.gz -
Subject digest:
37cb67a6af580b3a4f568a6bb2e5feaa9b8fd09bef57f44384505cb37fda9f44 - Sigstore transparency entry: 1575346289
- Sigstore integration time:
-
Permalink:
AmbiqAI/helia-aot@d18cce99139442aa2b8ae6fa12b5613c14ca8b18 -
Branch / Tag:
refs/heads/main - Owner: https://github.com/AmbiqAI
-
Access:
private
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@d18cce99139442aa2b8ae6fa12b5613c14ca8b18 -
Trigger Event:
push
-
Statement type:
File details
Details for the file helia_aot-0.17.1-py3-none-any.whl.
File metadata
- Download URL: helia_aot-0.17.1-py3-none-any.whl
- Upload date:
- Size: 403.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.13
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
a4d10135747f6d0f83b1d99b98143d3d6cb56db69796a91b87127278b5ab171f
|
|
| MD5 |
1c11bca8cafae1e551582ff10a654deb
|
|
| BLAKE2b-256 |
74c28ed4bfdcabdad333f5306a54dc043bef89e1147d96750b57b714c155fb39
|
Provenance
The following attestation bundles were made for helia_aot-0.17.1-py3-none-any.whl:
Publisher:
release.yml on AmbiqAI/helia-aot
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
helia_aot-0.17.1-py3-none-any.whl -
Subject digest:
a4d10135747f6d0f83b1d99b98143d3d6cb56db69796a91b87127278b5ab171f - Sigstore transparency entry: 1575346499
- Sigstore integration time:
-
Permalink:
AmbiqAI/helia-aot@d18cce99139442aa2b8ae6fa12b5613c14ca8b18 -
Branch / Tag:
refs/heads/main - Owner: https://github.com/AmbiqAI
-
Access:
private
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@d18cce99139442aa2b8ae6fa12b5613c14ca8b18 -
Trigger Event:
push
-
Statement type: