Skip to content

Interaction

The alice.network.interaction module defines the dataclasses that represent Hamiltonian interaction terms, and build_interaction, the TOML-driven dispatcher that orchestrates the full AutoMPO pipeline.

Dataclasses

Class Description
Interaction Base interaction (coupling + label)
Interaction1Site On-site term
Interaction2Site Two-site term

Builder

Function Description
build_interaction Build interaction list from TOML config

Pipeline Overview

config (TOML or dict)
    ▼ build_interaction()
    ├─ Stage 1: geometry_fn(geo_cfg)  →  Geometry
    ├─ Stage 2: intrcmap_fn(geo)      →  list[Interaction2Site]  (sites + labels, no tensors, cpl=0.0)
    ├─ Stage 3: model_fn(interactions, L, **model_cfg)
    │       → fills cpl + tensor fields in place
    └─ returns (interactions, spc, geo)

See Also