A data model and validation tool for PHIR (PECOS High-level Intermediate Representation).
Project description
PHIR: PECOS High-level Intermediate Representation
phir models the PHIR specification as a Pydantic model.
See our docs.
Included is the tool phir-cli that provides validation and pretty printing on the command line.
Prerequisites
Python >=3.10
Installation
Just issue pip install phir to obtain the latest stable release.
phir CLI
The package includes a CLI for directly validating PHIR JSON files using the command line.
❯ phir-cli -h
usage: phir-cli [-h] [-s] [-v] [jsonfile]
Validates and pretty prints valid PHIR
positional arguments:
jsonfile json file to validate against PHIR spec
options:
-h, --help show this help message and exit
-s, --schema dump JSON schema of the PHIR model and exit
-v, --version show program's version number and exit
Development
Clone the repository and run:
python -m venv .venv
source .venv/bin/activate
pip install -U pip setuptools
pip install -r requirements.txt
pre-commit install
Then, install the project using:
pip install -e .
See Makefile for other useful commands.
Testing
Issue pytest from the root directory.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file phir-0.3.3.tar.gz.
File metadata
- Download URL: phir-0.3.3.tar.gz
- Upload date:
- Size: 24.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/5.0.0 CPython/3.12.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
18159b1ac342d4af7e6cca7a3b949371b325a7f3c4f20ac1f5e3173a33a56033
|
|
| MD5 |
bbfd4bcbff182e1f32c7de9a44580792
|
|
| BLAKE2b-256 |
1e3489dc01d1e6dd8c7f56c17c4a8dd7e5afb60184057daf860dda995b951be0
|
File details
Details for the file phir-0.3.3-py3-none-any.whl.
File metadata
- Download URL: phir-0.3.3-py3-none-any.whl
- Upload date:
- Size: 12.4 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/5.0.0 CPython/3.12.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
af6d64088279fb22320815f4fa8e42880fcc32416bedbcd8a5adc6c0eee3e567
|
|
| MD5 |
13b8e72aff7dd3634b0b0633c6f5028b
|
|
| BLAKE2b-256 |
6a1ded9b8b43ee55c2fcb47dfc13415db1534d521a08b0ba30780d619c1b8523
|