Merging Symbols

class SymbolMergeHistory(**data)

Bases: BaseModel, Generic[S]

Merge history for a symbol.

Maintains a merge history to other Lines or Circles if they are (found out to be) equivalent

Example

a -> b -

c -> d -> e -> f -> g

d.merged_to = e representent(d) = g d.merged_from = {a, b, c, d} d.equivs = {a, b, c, d, e, f, g}

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

symbol: S
fellows: set[S]
representent: SymbolMergeHistory[S] | None
add_self_to_fellows()
Return type:

Self

model_config: ClassVar[ConfigDict] = {}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

representent_of(merge_history)
Return type:

SymbolMergeHistory

merge_symbols(symbol_history_to_merge, symbols_histories, all_symbols)

Merge all nodes.

Return type:

None