graflo.architecture.evolution.ops.vertices¶
Ops that add, remove, merge, or rename vertices and their properties.
Classes¶
AddVertexPropertiesOp
¶
Bases: ConfigBaseModel
Add vertex properties to existing logical vertex types.
An entry may be a bare name or a full :class:~graflo.architecture.schema.vertex.Field.
Bare names were the original shape and still mean what they meant -- an
untyped property -- but they cannot express a property that arrives with a
type and a grounding, which is what any op stream that adds a measured or
temporal property has to say in one replayable step.
Source code in graflo/architecture/evolution/ops/vertices.py
Attributes¶
additions = PydanticField(..., description='Per-vertex property additions: ``{vertex_name: [field_name | Field, ...]}``.', min_length=1)
class-attribute
instance-attribute
¶
op = 'add_vertex_properties'
class-attribute
instance-attribute
¶
Methods:¶
field_names(vertex)
¶
The names added to vertex, whichever shape they were written in.
Source code in graflo/architecture/evolution/ops/vertices.py
AddVerticesOp
¶
Bases: ConfigBaseModel
Introduce new logical vertex types.
The unary counterpart to what :class:MergeManifestsOp can only do binarily.
A replayable change set that cannot introduce a type could only ever describe a
shrinking graph, which is why this exists alongside remove_vertices.
Source code in graflo/architecture/evolution/ops/vertices.py
MergeVerticesOp
¶
Bases: ConfigBaseModel
Merge source vertices into a single logical name (schema, edges, ingestion).
Source code in graflo/architecture/evolution/ops/vertices.py
Attributes¶
allow_observation_fusion = PydanticField(default=False, validation_alias=AliasChoices('allow_observation_fusion', 'allow_row_fusion'), description='Accept resource pipelines whose sources land in one accumulator slot — the same level and the same ``role``, or both bare. Those steps then write to one slot, fusing into one node what a single source document emitted as two vertex observations. Same-level steps with distinct ``role``s never share a slot and need no acknowledgement. Rejected unless set. ``allow_row_fusion`` is accepted as a legacy alias.')
class-attribute
instance-attribute
¶
allow_self_relations = PydanticField(default=False, description='Accept edges whose endpoints both land on ``into``. A self-relation makes both endpoints share one accumulator slot, so assembly merges observations that were previously separate nodes. Rejected unless set.')
class-attribute
instance-attribute
¶
into = PydanticField(..., description='Resulting vertex type name. If it already exists, source vertices are merged into it. If it does not exist, a new vertex is built from all sources.')
class-attribute
instance-attribute
¶
op = 'merge_vertices'
class-attribute
instance-attribute
¶
sources = PydanticField(..., description='Vertex type names to merge away. Must not include ``into``. Each name must exist in the schema before the merge.', min_length=1)
class-attribute
instance-attribute
¶
RemoveVertexPropertiesOp
¶
Bases: ConfigBaseModel
Remove vertex properties and propagate pruning to ingestion/db profile references.
Source code in graflo/architecture/evolution/ops/vertices.py
RemoveVerticesOp
¶
Bases: ConfigBaseModel
Remove logical vertices and cascade: edges, ingestion resources, bindings.
Source code in graflo/architecture/evolution/ops/vertices.py
RenameVertexPropertiesOp
¶
Bases: ConfigBaseModel
Rename vertex properties (and identity references) and propagate to ingestion.
renames maps each vertex name to a per-vertex {old_field: new_field} map.
Schema-side: rewrites Field.name, vertex.identity, and any DB profile
structures that reference field names (vertex_indexes, edge_specs.indexes).
Ingestion-side: rewrites VertexActor.from so the doc still uses the OLD field
name (injecting {new_field: old_field} when missing), rewrites
TransformActor.rename values that target a renamed vertex field, and updates
Resource.extra_weights / edge.vertex_weights (:class:~graflo.architecture.graph_types.Weight
fields, map, and filter keys that address vertex observation columns).
Source code in graflo/architecture/evolution/ops/vertices.py
RenameVerticesOp
¶
Bases: ConfigBaseModel
Rename logical vertex names across schema, ingestion, and bindings.