Utils
fieldz_kb.biocypher.utils
BioCypher schema utilities for fieldz_kb.
Generates BioCypher schema YAML files from fieldz classes.
Functions:
| Name | Description |
|---|---|
make_biocypher_schema_file_from_classes |
Generate a BioCypher schema YAML file from a set of classes. |
make_biocypher_schema_string_from_classes |
Generate a BioCypher schema YAML string from a set of classes. |
make_biocypher_schema_file_from_classes
Generate a BioCypher schema YAML file from a set of classes.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
classes
|
set[type]
|
A set of classes to generate the schema for. |
required |
output_file_path
|
str
|
The path to write the YAML file to. |
required |
Source code in src/fieldz_kb/biocypher/utils.py
make_biocypher_schema_string_from_classes
Generate a BioCypher schema YAML string from a set of classes.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
classes
|
set[type]
|
A set of classes to generate the schema for. |
required |
Returns:
| Type | Description |
|---|---|
str
|
A YAML string containing the BioCypher schema. |