ONNX Runtime

Cross-platform, high-performance ML inference and training accelerator for ONNX models

Library
PyPI
v1.29.0
21,773stars
MIT License

Repository Health

Pre-computed score based on development activity, maintenance, community, maturity, and trend momentum.How we score it →
95/100Excellent
Development Activity100
Maintenance96
Community84
Maturity60
Momentum40

Technical Analysis

AI-assessed by reading the actual repository — architecture, code quality, innovation, and documentation.How we score it →
81/100Excellent
Architecture92
Code Quality88
Innovation85
Learning Curve60

ONNX Runtime is a cross-platform machine-learning inference and training accelerator maintained by Microsoft. It executes models exported to the ONNX (Open Neural Network Exchange) format regardless of which framework trained them — PyTorch, TensorFlow/Keras, scikit-learn, LightGBM, XGBoost, and others all export to ONNX and can then be served by the same runtime. Rather than re-implementing a training framework, ONNX Runtime focuses on making inference (and, via ONNX Runtime Training, gradient-based training) fast and portable across wildly different hardware and operating systems.

The engine’s core abstraction is the Execution Provider (EP): a pluggable backend that maps ONNX graph operators onto specific hardware — CUDA and TensorRT for NVIDIA GPUs, DirectML and WinML for Windows, CoreML for Apple hardware, OpenVINO for Intel, QNN for Qualcomm NPUs, WebGPU/WASM for the browser, and a portable CPU fallback. At load time the runtime partitions the model graph across whichever providers are registered, applies graph-level optimizations (operator fusion, constant folding, layout transforms), and dispatches each subgraph to the fastest available provider. Bindings are published for Python, C/C++, C#, Java, JavaScript/TypeScript (Node and browser), Objective-C, and Rust, making it one of the few inference engines usable natively from nearly every major application platform.

What You Get

  • A single InferenceSession API (mirrored across Python, C++, C#, Java, JS, Rust, Objective-C) for loading and running ONNX models
  • A pluggable Execution Provider architecture spanning CUDA/TensorRT, DirectML, CoreML, OpenVINO, QNN, WebGPU/WASM, and a portable CPU backend
  • Graph-level optimizations — operator fusion, constant folding, layout transforms — applied automatically at model load time
  • ONNX Runtime Training, adding gradient computation on top of the same graph/EP infrastructure for accelerating PyTorch training loops
  • Companion tooling for quantization, model conversion, and packaging, plus dedicated example repos for inferencing and training

Common Use Cases

  • Serving a PyTorch or TensorFlow model in production without carrying the full training framework as a runtime dependency
  • Deploying the same model consistently across CPU, GPU, mobile, and browser targets by switching Execution Providers rather than rewriting inference code
  • Accelerating classical ML pipelines (scikit-learn, LightGBM, XGBoost) exported to ONNX for lower-latency serving
  • Speeding up large transformer model training on multi-node NVIDIA GPUs via ONNX Runtime Training with minimal changes to an existing PyTorch script

Under The Hood

Architecture - At the center of the codebase is a graph-based inference engine (onnxruntime/core/) that loads an ONNX protobuf model, builds an in-memory graph representation, and partitions it across one or more registered Execution Providers before running the fused, hardware-specific subgraphs. Each EP (CUDA, TensorRT, DirectML, CoreML, OpenVINO, QNN, WebGPU, and the default CPU provider) implements a common kernel-registration interface so the same graph can be split across heterogeneous hardware transparently to the caller. Language bindings (onnxruntime/python, csharp/, java/, js/, objectivec/, rust/) wrap the C API rather than reimplementing engine logic, keeping behavior consistent across languages. orttraining/ extends the same graph infrastructure with automatic differentiation for training scenarios. Tech Stack - The engine core is C++ (roughly 84% of the codebase) with CUDA/HIP kernels for GPU providers, CMake as the primary build system, and per-language packaging (setuptools/wheel for Python via setup.py, NuGet for C#, npm for JS/TS, Maven-style build for Java, Cargo for Rust). Build scripts (build.sh/build.bat) orchestrate a large, configurable CMake build supporting dozens of hardware/OS/EP combinations from a single source tree. Code Quality - Testing is extensive and organized per surface: onnxruntime/test/ covers the core engine, with parallel test suites in csharp/test, java/testdata, objectivec/test, and winml/test; a dedicated tools/perftest directory covers performance regression testing. Given the C++ core’s scale (950+ contributors, ~15k commits), code quality is enforced through required CI across many hardware targets, CPPLINT.cfg/lintrunner configs, and a documented CODEOWNERS review structure rather than a single style guide. API Design - The public API is deliberately small and uniform across every language binding: construct a session from a model, gather input tensors, call run, and read output tensors — the same four-step shape whether calling from Python, C#, Java, or Rust. This consistency is the project’s main developer-experience achievement, since it lets the same mental model transfer across a dozen deployment targets even though the underlying hardware dispatch is highly complex.

Used by 15 apps in this directory

Python
100%
Apache 2.0

Agno

Devops · AI Development · Automation

42,074

Build, run, and manage agent platforms with a full production stack — SDK, runtime, and control plane included.

View details
93
Repo Health
87
Technical
66
Dependency
Built with
Python100%
Updated yesterday
JavaScript
95%
MIT

AnythingLLM

Developer Tools · Automation · AI Assistants

65,696

The all-in-one AI platform for private document chat, no-code agents, and local LLMs with zero setup friction.

View details
90
Repo Health
78
Technical
64
Dependency
Built with
JavaScript95%
Updated 3 days ago
TypeScript
49%
AGPL 3.0

Banana Slides

AI Design Tools · Productivity

15,554

AI-native PPT generator with Vibe editing, multi-LLM support, and fully editable PPTX export

View details
84
Repo Health
82
Technical
71
Dependency
Built with
TypeScript49%
Python46%
Updated yesterday
TypeScript
46%
AGPL 3.0

BrowserOS

Browser · AI Assistants

13,577

The open-source agentic Chromium browser with native AI agents, MCP server, and visual workflow automation — your data never leaves your machine.

View details
87
Repo Health
82
Technical
68
Dependency
Built with
TypeScript46%
Rust22%
Python18%
Updated yesterday
TypeScript
84%
Apache 2.0

Continue

Developer Tools · AI Development · AI Code Assistants

35,808

Open-source coding agent for VS Code, JetBrains, and CLI with support for 30+ LLM providers.

View details
81
Repo Health
88
Technical
62
Dependency
Built with
TypeScript84%
Updated yesterday
TypeScript
84%
Apache 2.0

Continue

Developer Tools · AI Development · AI Code Assistants

35,808

Open-source coding agent for VS Code, JetBrains, and CLI with support for 30+ LLM providers.

View details
81
Repo Health
88
Technical
62
Dependency
Built with
TypeScript84%
Updated yesterday
TypeScript
92%
Other

GitNexus

Developer Tools · AI Code Assistants

47,086

Index any codebase into an interactive knowledge graph and give your AI agents deep architectural context via MCP — with zero servers required.

View details
88
Repo Health
86
Technical
73
Dependency
Built with
TypeScript92%
Updated yesterday
Python
81%
Apache 2.0

headroom

AI Development · Developer Tools

69,144

Compress everything your AI agent reads — tool outputs, logs, RAG chunks, and files — before it reaches the LLM, achieving 60–95% fewer tokens with the same answers.

View details
84
Repo Health
86
Technical
72
Dependency
Built with
Python81%
Rust13%
Updated yesterday
Python
85%
Apache 2.0

knowhere

AI Development · Developer Tools

2,942

Transform messy, unstructured documents into persistent, navigable memory that AI agents can actually use.

View details
83
Repo Health
75
Technical
69
Dependency
Built with
Python85%
HTML15%
Updated yesterday

Join founders buildingwith open source

Opinionated takes, migration guides, cost-saving tips, and insights from the open source ecosystem.

Subscribe on Substack
Join 750+ subscribers

Search