PRAGMAR
Python, Reference Attribute Grammar, Models At Runtime
PRAGMAR is an experimental tool for building grammar-powered applications. Its two main focuses are programming ergonomics when creating grammars and catering to code-generator applications by providing templating utilities.
What is it?: It
- leverages Reference Attribute Grammars (RAGs) and aspect oriented programming
- simplifies and enhances the ergonomics of RAG attribute definition in a pythonic way
- generates a default xml-parser and xml-schema for the grammar out of the box
- models user-grammars inside a runtime meta-grammar
- supports runtime modification and validation of the whole meta-grammar
- PLANNED: provides utility functions for easy use with templating engines like mustache
- PLANNED: provides a web-ui to visualize and play around with grammars at runtime
- PLANNED: provides a web-endpoint out of the box to integrate it as an api
ROADMAP
flowchart LR
Goal["`First Release`"]
MultiFileAspects["`Aspects in Multible Files`"]
MultiFileExample["`Create Multifile Example`"]
ImproveGen["`Improve Generation Workflow`"]
GenerateFields["`Generate Fields in classes.py`"]
OptionalFields["`Optional Fields in Grammar definition`"]
InhCheck["`Validate Inherited Attributes`"]
Checks["`Only Generate Grammar when Checks succeed: Add Error Codes`"]
RuntimeOnlyExample["`Create Runtime Only Example (Single File)`"]
ReadMe["`Create README with all example variants`"]
JastAddComparisonExample["`Create Example highlighting benefits compared to Jastadd`"]
BetterChildAccess["`Make the interface easier to get children of nodes`"]
MultiFileAspects --> ImproveGen --> MultiFileExample --> ReadMe --> Goal
RuntimeOnlyExample --> ReadMe
JastAddComparisonExample --> ReadMe
GenerateFields --> Goal
OptionalFields --> Goal
BetterChildAccess --> Goal
InhCheck --> Checks --> Goal
HardenedMode["`Hardened Mode that generates the whole application (the application itself)`"]
EBNFParser["`Allow parsing of Jastadd-EBNF to define Grammars`"]
XmlJson["`Allow parsing Xml and Json to create usage-Trees of a defined language`"]
RestApi["`Create Default Rest-Api to modify Trees at runtime using Rewrites`"]
Future["`Future`"]
HardenedMode:::future --> Future
EBNFParser:::future --> Future
XmlJson:::future --> Future
RestApi:::future --> Future:::future
Goal:::planned
MultiFileAspects:::done
MultiFileExample:::done
ImproveGen:::done
GenerateFields:::done
OptionalFields:::done
InhCheck:::planned
Checks:::planned
RuntimeOnlyExample:::done
ReadMe:::planned
JastAddComparisonExample:::planned
BetterChildAccess:::next
classDef planned fill:#555
classDef done fill:#040
classDef canceled fill:#700
classDef next fill:#880
classDef future fill:#000
Metadata
Release files for PRAGMAR 0.1.2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| pragmar-0.1.2.tar.gz | 414.1 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| pragmar-0.1.2-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 458.6 kB
Release files / pragmar-0.1.2.tar.gz
| Download URL | pragmar-0.1.2.tar.gz |
|---|---|
| Size | 414.1 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
6f44dfffc33455c0cbc5a05014a95259aa8a47e7e60ee05fc14d30ee15134b59
|
|
BLAKE2b-256 checksum How to use checksums |
41fc526352768a1b928608f509bd8bf889787980d75598bbf91446d1266ef2c4
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Oct 1, 2026.
Transparency logRelease files / pragmar-0.1.2-py3-none-any.whl
| Download URL | pragmar-0.1.2-py3-none-any.whl |
|---|---|
| Size | 44.6 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
d0413c75923252ca31a2ab15d3701db94e45829dc491b2c3d6a0b5a0afecb8cb
|
|
BLAKE2b-256 checksum How to use checksums |
3e6cbb6220f8a3dc13cdfe0e2c27e6ee6bb55cb0f50a3a67a0686a2bf0d0dd24
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Oct 1, 2026.
Transparency log