$npx skillfedfor your agent

PyJSG

Python JSON Schema Grammar interpreter

With conditionsPyPI Software DevelopmentReleased May 2026292.4K downloads / moCC0 1.0 UniversalPure Python

Decision gist · record as of 2026-08-14

pure-Python wheel — pyjsg-0.12.4-py3-none-any.whl
v0.12.4 · released 2026-05-01 · Python >=3.10 · 3 runtime deps: antlr4-python3-runtime, jsonasobj, requests

Yes, if you work with JSON Schema Grammar and need type-safe Python bindings. The package is actively maintained, has no known vulnerabilities, installs cleanly, and is permissively licensed. The main consideration is whether your project already uses JSG; if you're starting fresh, evaluate whether JSG's grammar syntax fits your schema needs better than alternatives.AI-flagged interpretation of the facts on this page — verify before relying

Before you install

  • Requires Python 3.10 or later; the package depends on internal features of the typing library which may require testing when upgrading Python versions.
  • Low install friction with a pure Python wheel distribution.
  • Maintenance status is active with a recent release.

License · maintenance · safety

CC0 1.0 Universal (permissive) — Licensed under CC0 1.0 Universal (public domain dedication), which is permissive and places no restrictions on use, modification, or distribution.

last release 2026-05-01 (105 days)

0 known vulnerabilities (OSV.dev, 2026-08-14) · 292,377 downloads/mo, #7,965 on PyPI

Verify before relying

pip install pyjsg

generate_parser input.jsg

from pyjsg.jsglib.jsg import loads

schema_json = '{"type": "Schema"}'
s = loads(schema_json)
print(s._as_json_dumps())
  • Current compatibility with Python 3.13 and 3.14 (listed as supported but package last released 2026-05-01)
  • Whether antlr4-python3-runtime introduces any platform-specific compilation requirements
  • Real-world validation performance and error message clarity for complex schemas
Same gist for agents: .md · .json

What it is and what it does

PyJSG is a code generator that reads JSON Schema Grammar (JSG) specifications and produces Python 3 classes representing the schema's structure. It bridges the gap between declarative schema definitions and typed Python objects, using the typing library to provide IDE support and type hints.

The generated classes inherit from JSG base types and include built-in validation, serialization to JSON, and attribute access control. You define a schema in JSG syntax, run the generate_parser command-line tool, and get back a Python module with classes ready to instantiate, populate, validate, and serialize. The package includes a validation library that checks whether Python objects conform to their schema definitions.

Use it for

  • Generate strongly-typed Python models from existing JSON Schema Grammar definitions for data interchange formats.
  • Build configuration file parsers that validate structure and types at runtime using generated schema classes.
  • Create domain-specific language interpreters where the grammar defines both syntax and Python object structure.
  • Validate JSON data against a schema before processing, catching structural errors early in a pipeline.
  • Serialize Python objects back to JSON while enforcing schema constraints and type safety.

Worth the install?

AI-flagged interpretation of the facts on this page. Verify before relying on it.

With conditions

Yes, if you work with JSON Schema Grammar and need type-safe Python bindings.

The package is actively maintained, has no known vulnerabilities, installs cleanly, and is permissively licensed. The main consideration is whether your project already uses JSG; if you're starting fresh, evaluate whether JSG's grammar syntax fits your schema needs better than alternatives.

Install

pyjsg on PyPI

Before you install

Low install friction with a pure Python wheel distribution. Maintenance status is active with a recent release. Three runtime dependencies (antlr4-python3-runtime, jsonasobj, requests) are standard libraries in the Python ecosystem.

Requires Python 3.10 or later; the package depends on internal features of the typing library which may require testing when upgrading Python versions.

License in practice

Licensed under CC0 1.0 Universal (public domain dedication), which is permissive and places no restrictions on use, modification, or distribution.

Quickstart

pip install pyjsg

generate_parser input.jsg

from pyjsg.jsglib.jsg import loads

schema_json = '{"type": "Schema"}'
s = loads(schema_json)
print(s._as_json_dumps())

Verify before relying

  • Current compatibility with Python 3.13 and 3.14 (listed as supported but package last released 2026-05-01)
  • Whether antlr4-python3-runtime introduces any platform-specific compilation requirements
  • Real-world validation performance and error message clarity for complex schemas

Package facts

LicenseCC0 1.0 Universal permissive
Python supportSupports the current Python release >=3.10
Install frictionLow. Pure-Python wheel
Runtime dependencies
3 packages
antlr4-python3-runtimejsonasobjrequests
MaintenanceActively maintained 105 days since the last release
First released
Downloads292,377 / month, #7,965 on PyPI 30-day window, as of 2026-08-14
Known vulnerabilitiesNone known OSV.dev, checked 2026-08-14
Classifiers
Development Status :: 4 - BetaEnvironment :: ConsoleIntended Audience :: DevelopersIntended Audience :: Science/ResearchLicense :: CC0 1.0 Universal (CC0 1.0) Public Domain DedicationProgramming Language :: Python :: 3 :: OnlyProgramming Language :: Python :: 3.10Programming Language :: Python :: 3.11Programming Language :: Python :: 3.12Programming Language :: Python :: 3.13Programming Language :: Python :: 3.14Topic :: Software DevelopmentTopic :: Software Development :: Code Generators

Evidence: pyjsg-0.12.4-py3-none-any.whl

Tags

Capabilities
json schema grammar pythoncode generator json schemajsg python bindingsjson to python classesschema validation pythontyped json objects pythonjsg parser generator
Topics
schema-validationcode-generationjson-schema
PyPI keywords
Code GeneratorJSGJavascriptPythonSchema

Let your AI agent find packages like this

Example. Real query, live index.

You found this page by searching. An agent finds it by wishing: SkillFed indexes 14,416 PyPI packages by what they can do, searchable in plain language.

wish › “json schema grammar python”

  • PyJSGGenerates Python 3 classes from JSON Schema Grammar (JSG)…
  • llguidanceEnforces structured output from large language models by computing…
  • tree-sitter-jsonProvides a JSON grammar parser for tree-sitter, enabling incremental…

Give your agent the search over MCP, or paste the wish link into any chat.

More Software Development packages

typing-extensions Worth it
PyPI · Software Development · released Jul 2026

Provides backported and experimental type hints for Python 3.9+, allowing use of newer typing features on older Python versions and enabling early experimentation with type system PEPs before they enter the standard library.

PSF-2.0pure Python · 3.9+
1.9Bdownloads / mo
numpy Worth it
PyPI · Software Development · released Aug 2026

NumPy provides an N-dimensional array object and a comprehensive suite of mathematical, linear algebra, Fourier transform, and random number functions for scientific computing in Python.

BSD-3-Clause AND 0BSD AND MIT AND Zlib AND CC0-1.0compiled wheel · 3.12+
1.1Bdownloads / mo
fastapi Worth it
PyPI · Software Development · released Jul 2026

FastAPI is a Python web framework for building REST APIs using type hints, with automatic request validation, serialization, and interactive API documentation.

MITpure Python · 3.10+
568.6Mdownloads / mo
annotated-doc With conditions
PyPI · Software Development · released Jul 2026

Provides a way to document function parameters, class attributes, return types, and variables inline using Python's `Annotated` type hint syntax instead of traditional docstrings.

MITpure Python · 3.9+
456.2Mdownloads / mo
typer Worth it
PyPI · Software Development · released Aug 2026

Typer builds command-line applications from Python functions using type hints, automatically generating help text, argument parsing, and shell completion.

Install it if you are building CLIs in Python.

MITpure Python · 3.10+
369.3Mdownloads / mo
distlib With conditions
PyPI · Software Development · released Jun 2026

Distlib provides low-level packaging utilities for building, distributing, and managing Python software—including metadata handling, version specifiers, wheel support, script installation, and dependency resolution.

permissive licensepure Python
323.3Mdownloads / mo

See also ShExJSG · PyShexC · jsonasobj · dataclasses-jsonschema · pyPEG2 · jsonasobj2 · marshmallow-jsonschema · PyShEx · tree-sitter-html · types-orjson