Metadata-Version: 2.5
Name: betula-schema
Version: 0.6.0
Summary: Pydantic models and strict parsers for the betula bioinformatics JSON schemas
Project-URL: Homepage, https://holmrenser.github.io/betula/
Project-URL: Documentation, https://holmrenser.github.io/betula/getting-started/
Project-URL: Repository, https://github.com/holmrenser/betula
Project-URL: Changelog, https://github.com/holmrenser/betula/blob/main/CHANGELOG.md
Author: Rens Holmer
License-Expression: MIT
License-File: LICENSE
Keywords: bioinformatics,blast,gff3,json-schema,phylogenetics,pydantic,sequence-alignment
Classifier: Development Status :: 3 - Alpha
Classifier: Intended Audience :: Science/Research
Classifier: Programming Language :: Python :: 3
Classifier: Topic :: Scientific/Engineering :: Bio-Informatics
Classifier: Typing :: Typed
Requires-Python: >=3.11
Requires-Dist: pydantic>=2.6
Description-Content-Type: text/markdown

# betula-schema (Python)

Pydantic v2 models and strict parsers for the [betula](https://holmrenser.github.io/betula/)
JSON Schemas: sequences, alignments, phylogenetic trees, gene annotations, distance matrices,
and BLAST results.

```python
from betula_schema import Tree, parse_json

tree = parse_json(Tree, '{"name": "A", "length": 0.1, "children": []}')
```

Every schema title is a model in `betula_schema`. Use `parse` / `parse_json` rather than
`Model.model_validate*`: they validate in Pydantic's strict mode, which is what makes them reject
exactly what the schema rejects.

See [Getting started](https://holmrenser.github.io/betula/getting-started/) for the full API tour,
and the [schema pages](https://holmrenser.github.io/betula/schemas/) for each type. The models are
generated from the schemas; the version matches the schema `$id` versions.
