graflo.rdf.utils¶
Shared helpers for GraFlo RDF serialization.
actor_step_class(step_type)
¶
Map actor step type to ontology class.
actor_step_type(step)
¶
Return normalized actor step type.
Source code in graflo/rdf/utils.py
add_enum_individual(graph, subject, predicate, value, mapping)
¶
Link subject to a named enumeration individual.
Source code in graflo/rdf/utils.py
add_literal(graph, subject, predicate, value)
¶
Add a literal triple when value is not None.
Source code in graflo/rdf/utils.py
add_rdf_list(graph, values)
¶
Build an RDF collection for string values.
Source code in graflo/rdf/utils.py
join_uri(base_uri, *parts)
¶
Join base URI with path segments.
json_literal(value)
¶
load_ontology_graph()
¶
ontology_path()
¶
parse_json_literal(value)
¶
reverse_enum(mapping, individual)
¶
Resolve named individual IRI back to enum string.
Source code in graflo/rdf/utils.py
slug_token(value)
¶
Normalize arbitrary text into a URI path segment.