skillfed

json2onnx

Converts a JSON file to an ONNX file.

json2onnx v2.0.3 82.9K downloads/30d#14,121 on PyPI21
Permissive license MIT License DORMANT released

What it is and what it does

json2onnx is a lightweight utility that transforms JSON representations into ONNX model files. It provides both a command-line interface and a Python API, accepting input as either a JSON file path or a dictionary, and returning an ONNX ModelProto object that can be saved to disk or used programmatically.

The package is designed for developers working with ONNX models who need to serialize or reconstruct models from JSON format. It has no runtime dependencies, making it straightforward to integrate. However, the project has been dormant for over a year, so users should verify compatibility with their current ONNX and Python versions before relying on it for production workflows.

Use it for:

  • Reconstruct ONNX models from JSON representations stored in databases or configuration files.
  • Convert JSON-based model definitions into standard ONNX format for inference engines.
  • Programmatically generate ONNX models by building JSON dictionaries and converting them.
  • Integrate JSON model specifications into automated machine learning pipelines.
  • Export model metadata or architecture from JSON to ONNX for compatibility with ONNX tooling.

Worth the install?

AI-flagged interpretation of the facts on this page — verify before relying

Converts JSON files to ONNX model format, accepting either a JSON file path or a dictionary and returning an ONNX ModelProto object.

Yes, if you need JSON-to-ONNX conversion and can verify compatibility with your ONNX version. The package has low install friction, no runtime dependencies, and a permissive MIT License. However, dormant maintenance (last update 1077 days ago) means you should test thoroughly before production use and be prepared to fork or find alternatives if issues arise.

Install

json2onnx on PyPI

pip

pip install json2onnx

uv

uv add json2onnx

poetry

poetry add json2onnx

Installing json2onnx

Before you install

Low install friction with no runtime dependencies. Maintenance is dormant—last release was 1077 days ago and the repository shows no recent activity, though it remains unarchived.

License in practice

MIT License permits free use, modification, and distribution with minimal restrictions, making it suitable for both open and closed-source projects.

Quickstart

pip install json2onnx

from json2onnx import convert

onnx_graph = convert(
  input_json_path="model.json",
  output_onnx_file_path="model.onnx"
)

Verify before relying

  • What JSON schema or structure is expected as input—whether it must conform to a specific ONNX JSON representation or a custom format.
  • Whether the package handles complex ONNX graphs or is limited to simpler model structures.
  • Current compatibility with recent ONNX versions, given the dormant maintenance status.

Package facts

License MIT License (permissive)
Python support supports the current Python release (>=3.6)
Install friction low — pure-Python wheel
Runtime dependencies none
Maintenance dormant — 1,077 days since the last release
Last repo commit
First released
Downloads 82,898/month — #14,121 on PyPI (30-day window, as of 2026-08-14)
Known vulnerabilities none known (OSV.dev, checked 2026-08-14)

Evidence: json2onnx-2.0.3-py3-none-any.whl

Tags

json to onnx conversionconvert json onnxjson onnx serializationonnx model from jsononnx graph generationmodel format conversionjson neural network
model-serializationonnx-tools

More Artificial Intelligence packages