Skip to main content

AMEVA-Runtime (Python)

PyPI Python License

모바일 및 엣지 환경을 위한 차세대 통합 온디바이스 하드웨어 오케스트레이션 및 6대 멀티모달 가속 런타임
Next-Gen Unified On-Device Hardware Orchestration & 6-Modality AI Acceleration Runtime for Mobile & Edge

Installation

pip install ameva-runtime

Quickstart

import ameva_runtime as ameva
from ameva_runtime import vulkan

# 1. Execute LLM inference directly with optimal on-device hardware dispatch
result = ameva.run(
    model="qwen2.5-0.5b",
    prompt="Space in Korean is:",
    max_tokens=32
)
print(f"Generated text: {result.text}")
print(f"Hardware backend: {result.backend_used} ({result.tokens_per_second:.2f} t/s)")

# 2. Hardware diagnostic inspection via Vulkan engine
doc = vulkan.Doctor()
report = doc.run_self_test(verbose=False)
print(f"GPU Target: {report.device_name} (Passed: {report.passed_stages}/{report.total_stages})")

Description

AMEVA Runtime is a unified on-device hardware orchestration and AI acceleration engine engineered for mobile and edge systems. It dynamically inspects SoC topology and driver environments, routing compute graphs between Qualcomm Adreno, ARM Mali, and ARM Cortex CPU-NEON.

1. Empirical Real-Device LLM Benchmarks (Qwen2.5-0.5B-Instruct, GGUF Q4_K_M)

Device & Processor GPU Architecture Active Backend Layers in VRAM Generation Speed (t/s) Prompt Speed (t/s) UI Freeze Acceleration
Galaxy S25 (Snapdragon 8 Elite) Qualcomm Adreno 830 (Vulkan 1.3) VULKAN 25/25 (100%) 35.80 t/s (27.9 ms/t) 4.53 t/s 0% (Stable) 35.8x (vs CPU)
Galaxy A35 (Exynos 1380) ARM Mali-G68 MP5 (Vulkan 1.3) VULKAN (Medium MatMul) 25/25 (100%) 4.44 t/s (225 ms/t) 6.12 t/s 0% (Stable) +26.9% (vs NEON)
Galaxy A35 (Exynos 1380) Cortex-A78 CPU-NEON (3 Threads) CPU-NEON 0/25 3.55 t/s (281 ms/t) 8.05 t/s 0% (Stable) Baseline

2. Empirical Real-Device STT Benchmarks (Whisper Large-v3-Turbo Q5_0, 548MB)

  • Test Device: Samsung Galaxy A35 5G (Exynos 1380, ARM Mali-G68 MP5, 8GB RAM, Android 16 Termux)
  • Audio Source: John F. Kennedy 1-minute speech sample (jfk_1min.wav)
Execution Mode Target Hardware Elapsed Time GPU Clock / Load CPU Utilization Accuracy Speedup
CPU NEON Mode (-dev -1, 4 threads) Cortex-A78 x4 cores 816.48s (13m 36s) 0% (Idle) 291% (Active) Standard Baseline
Vulkan GPU Mode (-dev 0, Mali Quirk) Mali-G68 MP5 360.60s (6m 00s) 949 MHz (100%) 20~30% (Low) Standard 2.26x (56% time reduction)
  • Galaxy S25 (Adreno 830) STT: Completed 4,401 ms inference on speech input (JIT compiler bug resolved).

3. Root-Cause Defect Resolution (Ground Truth)

(1) ARM Mali-G68 Valhall Integer Truncation Infinite Loop Elimination

  • Defect: Executing mul_mm.comp on Mali-G68 (subgroup size 16) caused GPU hangs and hardware watchdog TDR resets (VK_ERROR_DEVICE_LOST).
  • Root Cause: The stride calculation loadstride_b = gl_WorkGroupSize.x * LOAD_VEC_B / BK = 16 * 1 / 32 = 0 truncated to zero in integer division, producing an infinite loop for (uint l = 0; l < BN; l += 0).
  • Resolution: Enforced Medium MatMul kernels (_m, workgroup size 128, loadstride_b = 4 > 0) via enforce_medium_matmul: true, enabling stable 25/25 layer GPU offloading.

(2) Qualcomm Adreno 830 JIT Compiler Bug Isolation

  • Defect: Whisper STT pipeline compilation failed on Snapdragon 8 Elite with VK_ERROR_UNKNOWN (-13) during mul_mat_vec dispatch.
  • Root Cause: Qualcomm's Adreno JIT compiler failed register allocation when Specialization Constant NUM_COLS >= 3.
  • Resolution: Bound mul_mat_vec_max_cols = 2 for Adreno 830, achieving stable GPU inference in 4,401 ms on speech input.

4. 6-Modality Acceleration Roadmap

Modality Engine & Architecture Status Hardware Acceleration Mechanism
1. LLM (Text) Llama.cpp (Qwen2.5, Llama 3.2) [v2.0.0 Stable] Vulkan 25/25 layer full VRAM offload (Adreno 35.8 t/s, Mali 4.44 t/s)
2. STT (Speech) Whisper.cpp (Large-v3-Turbo) [v2.0.0 Stable] Vulkan on-device STT acceleration (Adreno 4.4s, Mali 2.26x speedup)
3. Vision (VLM) CLIP, MobileVLM, LLaVA [v2.1.0 WIP] GGML Vulkan image encoder tensor engine binding
4. Diffusion (Image) Stable Diffusion v1.5 / FLUX.1 [v2.2.0 WIP] On-device Vulkan UNet & DiT tensor offload engine
5. TTS (Audio) Piper / Sherpa-ONNX / Kokoro [v2.3.0 WIP] Real-time low-latency neural TTS streaming pipeline via Vulkan/NPU
6. Train (Training) On-Device LoRA / QLoRA [v2.4.0 WIP] Smartphone local Vulkan gradient descent backpropagation engine

5. Architectural Principles

  • Fail-Fast & Zero-Silent-Fallback: Never disguise GPU failures as CPU success. If a hardware backend fails, immediate explicit exceptions and telemetry are raised.
  • Consolidated Single Package: Distributed cleanly via pip install ameva-runtime and npm install @ameva/runtime.

Documentation

License

Apache-2.0 License. Copyright (c) 2026 Eunho Kim (@uno-km).

Release files for ameva-runtime 2.0.0

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

Source distribution (sdist)

Source distribution for ameva-runtime 2.0.0
File Size Uploaded
ameva_runtime-2.0.0.tar.gz 67.6 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for ameva-runtime 2.0.0
File Interpreter ABI Platform
ameva_runtime-2.0.0-py3-none-any.whl Python 3 none any Details

Total release size: 139.4 kB

Release files / ameva_runtime-2.0.0.tar.gz

Download URL ameva_runtime-2.0.0.tar.gz
Size 67.6 kB
Tags Source
SHA-256 checksum
How to use checksums
9530cf2dacfdbd1e8d2567064eaa8328fe88ad9f573d270fbd82eeeeaa66c11b
BLAKE2b-256 checksum
How to use checksums
16241695adfab6291516b1975b3cc51ffa59af23ef64e18628861367903cbed3
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.0

Release files / ameva_runtime-2.0.0-py3-none-any.whl

Download URL ameva_runtime-2.0.0-py3-none-any.whl
Size 71.8 kB
Tags Python 3
SHA-256 checksum
How to use checksums
c3371a45ca3538129fcf2e6605ef5b0e5eb4524a2db7498b1c92aa4a77df9d44
BLAKE2b-256 checksum
How to use checksums
bb9cfe5742874abe72d9bd3a935523ea53e2946a7f350e5f5a1c52ae1656c363
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.0

Release history Release notifications | RSS feed

2.7.2

2 release files

2.7.1

2 release files

2.7.0

2 release files

2.6.3

2 release files

2.6.2

2 release files

2.6.1

2 release files

2.6.0

2 release files

2.5.1

2 release files

2.5.0

2 release files

2.4.0

2 release files

2.3.4

2 release files

2.3.3

2 release files

2.3.2

2 release files

2.3.1

2 release files

2.3.0

2 release files

2.2.4

2 release files

2.2.3

2 release files

2.2.2

2 release files

2.2.1

2 release files

2.2.0

2 release files

2.1.0

1 release file

2.0.2

2 release files

This release

2.0.0 This release

2 release files

1.0.1

2 release files

1.0.0

2 release files

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